Thread: [Subplugin Submission] [T] List of Modified + Requested Plugins
View Single Post
plazma
Senior Member
Join Date: Oct 2013
Old 02-20-2016 , 19:16   Re: [T] List of Modified + Requested Plugins
Reply With Quote #1103

Quote:
Originally Posted by plazma
I want to kill humans when touch it, not only last human, understand? no infection humans only kill.

thanks

PHP Code:
// Infection Bomb Explosion
infection_explode(ent)
{
    
// Round ended (bugfix)
    
if (g_endround) return;
    
    
// Get origin
    
static Float:originF[3]
    
pev(entpev_originoriginF)
    
    
// Make the explosion
    
create_blast(originF)
    
    
// Infection nade explode sound
    
static sound[64]
    
ArrayGetString(grenade_infectrandom_num(0ArraySize(grenade_infect) - 1), soundcharsmax(sound))
    
emit_sound(entCHAN_WEAPONsound1.0ATTN_NORM0PITCH_NORM)
    
    
// Get attacker
    
static attacker
    attacker 
pev(entpev_owner)
    
    
// Collisions
    
static victim
    victim 
= -1
    
    
while ((victim engfunc(EngFunc_FindEntityInSpherevictimoriginFNADE_EXPLOSION_RADIUS)) != 0)
    {
        
// Only effect alive non-spawnprotected humans
        
if (!is_user_valid_alive(victim) || g_zombie[victim] || g_nodamage[victim])
            continue;
        
        
// Last human is killed
        
if (fnGetHumans() == 1)
        {
            
ExecuteHamB(Ham_Killedvictimattacker0)
            continue;
        }
        
        
// Infected victim's sound
        
ArrayGetString(grenade_infect_playerrandom_num(0ArraySize(grenade_infect_player) - 1), soundcharsmax(sound))
        
emit_sound(victimCHAN_VOICEsound1.0ATTN_NORM0PITCH_NORM)
        
        
// Turn into zombie
        
zombieme(victimattacker0110)
    }
    
    
// Get rid of the grenade
    
engfunc(EngFunc_RemoveEntityent)

__________________
Free Palestine ♥
plazma is offline