Fixed attacker not getting credit for delayed infection.
This commit is contained in:
		@@ -449,12 +449,15 @@ public Action:ImmunityDelayTimerHandler(Handle:timer, any:client)
 | 
				
			|||||||
    // Check if time is up.
 | 
					    // Check if time is up.
 | 
				
			||||||
    if (PlayerImmunityDuration[client] <= 0)
 | 
					    if (PlayerImmunityDuration[client] <= 0)
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
 | 
					        // Get attacker before cleaning up.
 | 
				
			||||||
 | 
					        new attacker = PlayerImmunityAttacker[client];
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
        // Time is up. Reset data.
 | 
					        // Time is up. Reset data.
 | 
				
			||||||
        PlayerImmunityDuration[client] = 0;
 | 
					        PlayerImmunityDuration[client] = 0;
 | 
				
			||||||
        ImmunityAbortHandler(client);
 | 
					        ImmunityAbortHandler(client);
 | 
				
			||||||
        
 | 
					        
 | 
				
			||||||
        // Infect client.
 | 
					        // Infect client. Give credit to the stored attacker.
 | 
				
			||||||
        InfectHumanToZombie(client, PlayerImmunityAttacker[client]);
 | 
					        InfectHumanToZombie(client, attacker);
 | 
				
			||||||
        
 | 
					        
 | 
				
			||||||
        return Plugin_Stop;
 | 
					        return Plugin_Stop;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user