 |
|
Veteran Member
|

04-21-2012
, 07:04
Re: [SC] Detect when monster_* is killed
|
#3
|
Quote:
Originally Posted by Devil259
What's the entity name (not classname) ?
If, for example, the name is "info_target", you've to do that :
Code:
RegisterHam( Ham_Killed, "info_target", "Monster_Killed", 1 );
public Monster_Killed( monster, killer )
{
new szClassname[ 32 ];
pev( monster, pev_classname, szClassname, 31 );
if( equal( szClassname, "monster_", 8 ) && is_user_alive( killer ) )
{
client_print( killer, print_chat, "monster killed!" );
}
}
|
monster_* is the entity.
|
|
|
|