[L4D/2] Play sound on Survivor death
I'm looking to run a plugin that will send a sound to all active players when a survivor dies. If anyone could either make one or explain how one would go about coding one, it'd be most appreciated! :D
|
Re: [L4D/2] Play sound on Survivor death
create a plugin..
in OnPluginStart() make a hook for player_death in "player_death" get the id of the client who dies and check to make sure it is a player (1 <= client <= MaxClients) then check that it is a survivor (GetClientTeam(client) == 2) if you get errors about the client, also check before the team: IsClientInGame(client) if so EmitSound(...) you will most likely have to precache the soundfile in OnMapStart() |
Re: [L4D/2] Play sound on Survivor death
Uhm, being a little more specific, read this :P...
PHP Code:
|
Re: [L4D/2] Play sound on Survivor death
In case anyone did not notice, this is the plugins ideas/requests section, not the scripting
|
Re: [L4D/2] Play sound on Survivor death
Quote:
Quote:
|
Re: [L4D/2] Play sound on Survivor death
Thanks for taking the time guys! Huge help! :D
I'm simply triggering player death music for all survivors in campaign mode =] |
| All times are GMT -4. The time now is 03:42. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.