View Single Post
Mr_panica
Senior Member
Join Date: Jan 2017
Location: Russia, Saint-Petersburg
Old 01-08-2022 , 02:17   Re: [TF2] New Give Weapons And Hats Plugin
Reply With Quote #5

Quote:
Originally Posted by PC Gamer View Post
I'll take a stab at it...

This is called 'Gimme'. It's a TF2 plugin allows you to equip any class appropriate weapon or item. Emphasis is on class appropriate. In other words, the item must be normally usable by your class in order for you to equip it. For example, if you want to equip a rocketlauncher you must be a soldier. This was done intentionally to prevent weirdness in game with missing models and animations. The item you receive is lost when you die, touch a locker, or change class.

Dependencies:
[TF2] Econ Data by the talented nosoop : Link: https://forums.alliedmods.net/showthread.php?t=315011
TF2Attributes, by either nosoop or FlaminSarge : Link: https://github.com/nosoop/tf2attributes

Link to item index numbers wiki: https://wiki.alliedmods.net/Team_For...nition_Indexes

Commands:
To give yourself an item: !gimme <item index>
To give target player an item: !giveitem <target> <item index>
To get a link to url for item index wiki: !index

Examples:
Give yourself a knife (will only work for Spy): !gimme 4
Give yourself Max's Severed Head: !gimme 162
Give player named Bob the Rocket Launcher (assuming Bob is a soldier): !giveitem bob 18
Give all Bots the B.M.O.C. hat (santa hat): !giveitem @bots 666

I'll post this in the plugins section after testing it for a while on my server. So far everything seems to be working as intended, including Spy weapons.

Note: This is my first attempt to write anything using TF2 Econ Data so feel free to suggest improvements as I am a hobbyist plugin writer trying to get better at coding.

Edit: experimental plugin removed since release version 1.0 was published. Link: https://forums.alliedmods.net/showthread.php?t=335644
Oh, that's great, thank you!
__________________
Sorry for my English.
Mr_panica is offline