Page 1 of 1

Buy a Helmet v0.2

Posted: Mon Nov 22, 2021 6:19 pm
by greenie
Introduction
Do you ever want to buy just a helmet without kevlar vest? Now it is possible!
Sometimes it may be logically to buy only helmet in case you have enough armor.
All you need to do it is just bind a client console command "helmet" to a button.
Note: if you have no armor at all your helmet is useless (as CS standard behaviour).
Features
Plugin was successfully tested and comply all appropriate CS standards:
- helmet cost = kevlar vest and helmet cost - kevlar vest cost = $350 (may be changed)
- buy helmet sound the same as kevlar vest/(and helmet) buy sound (may be changed)
- displaying of armor/helmet HUD icon is correct at any time/state
- buy helmet process absolutely obey all CS buy standards:
- you must be alive
- you must be in buyzone
- obey buytime limit + CS standard center text message
- you can't buy a helmet if you already have one + CS standard text center message
- you must have enough money + CS standard text center message
Modules
fakemeta
Options
HELMET_COST - helmet cost (default: 350)
HELMET_BUY_SOUND - helmet buy sound filename (default: "items/ammopickup2.wav")
Commands
helmet - allows to a player buy a helmet
CVARs
I didn't include any cvars intentionally (in my opinion there are nothing needed to be changed).
I assume no one would ask for plugin on/off cvar (i think it must be always "on" like CS default).
Anyway you can pause/stop plugin if you wish (use amx_pausecfg console command for details).
Versions
0.2
cstrike module not required anymore
reorganized nearly from scratch
added AMD64 processor support
0.1
first release
Thanks
OneEyed - get armor type idea come from his "CS Armor Drop" plugin
Damaged Soul - his "Message Logging" plugin very useful

plugin
source