Thread: Death Sounds
View Single Post
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 03-23-2011 , 08:08   Re: Death Sounds
Reply With Quote #15

You should not register the event if no sounds were found from the parsing.

Also, I would suggest to format directly the sound with spk or mp3 play at parsing time before saving in the array, so you can use directly something like that :

Code:
public EventDeathMsg() {     client_cmd( read_data( 2 ), "%a", ArrayGetStringHandle( g_aSounds, g_iTotalSounds == 1 ? 0 : random( g_iTotalSounds ) ) ); }
__________________
Arkshine is offline