View Single Post
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 10-24-2009 , 12:13   Re: Killing Particles v1.0
Reply With Quote #5

Quote:
Originally Posted by DarkSkif View Post
When I kill the enemy, server crashes ...
Try this.
PHP Code:
#include < amxmodx >
#include < hamsandwich >

new g_iMaxplayers;

public 
plugin_init( ) {
    
register_plugin"Killing Particles""1.0""metallicawOw" );
    
    
RegisterHamHam_Killed"player""FwdHamPlayerKilled");
    
    
g_iMaxplayers get_maxplayers( );
}

public 
FwdHamPlayerKilledidiAttackeriShouldGib ) {
    if( 
<= iAttacker <= g_iMaxplayers ) {
        new 
iOrigin];
        
get_user_originidiOrigin );
        
        
message_beginMSG_PVSSVC_TEMPENTITYiOrigin );
        
write_byteTE_IMPLOSION );
        
write_coordiOrigin] );
        
write_coordiOrigin] );
        
write_coordiOrigin] );
        
write_byte200 );
        
write_byte100 );
        
write_byte);
        
message_end( );
        
        
message_beginMSG_PVSSVC_TEMPENTITYiOrigin );
        
write_byteTE_PARTICLEBURST );
        
write_coordiOrigin] );
        
write_coordiOrigin] );
        
write_coordiOrigin] );
        
write_byte50 );
        
write_byte72 );
        
write_byte);
        
message_end( );
    }

__________________
xPaw is offline