TF2 Giving weapons to another class
Is it possible to give one class another weapon? for example, giving the scout a rocket launcher or something.
If so, would someone please give me an example of how to do it, you dont have to build a plugin just to show, just a small example ? Sorry if its a noob question, but thanks. |
Re: TF2 Giving weapons to another class
No.
|
Re: TF2 Giving weapons to another class
|
Re: TF2 Giving weapons to another class
Quote:
|
Re: TF2 Giving weapons to another class
Err, that's just the skin. They have the weapons that belong to their class, but not the skin that belongs to their class, because they haven't properly respawned.
|
Re: TF2 Giving weapons to another class
2 Attachment(s)
Here's what I wrote up a few days ago. It gives a good example of how to do it properly, but there are still a few bugs with the weapon scripts that need to be worked out before it will work 100%.
Things to note: Weapons that you equip inherit the values of the original weapon that was in that slot. Say you're a scout and you give yourself a rocketlauncher. The rocketlauncher would have 6 shots per clip, and 32 extra rockets because of the scattergun. Also, if you look at the plugin, I made a trie for every weapon. I use that trie to determine the slot each weapon or item is located in. I do this because if you don't strip that slot and then equip the weapon, the client will have use the "use" command (ex. "use tf_weapon_rocketlauncher") to pull the weapon out. That's about all I have to say right now. I'm going to head out for the rest of the day. If I think of something else while I was out, I'll try posting it later. |
Re: TF2 Giving weapons to another class
Hm, I tried to give my Pyro a bat, and the server crashed. :(
/givenameditem [UE]Curlefry tf_weapon_bat |
Re: TF2 Giving weapons to another class
Thanks for posting it !
I really appreciate it. Quote:
Ah not a problem, I could just change their ammo clip/size after i give them the weapon, right? Then again they could just refill it back up from the cabinet.. Edit: So far every weapon i've tried giving has crashed the server haha |
Re: TF2 Giving weapons to another class
The offsets might have changed since I last tested it. I'll check that out later tonight.
|
Re: TF2 Giving weapons to another class
bl4nk: other solution is to bug pred about those windows signatures for playerclasses ctx files ;]
|
All times are GMT -4. The time now is 05:30. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.