All pastes #333250 Raw Edit

Unnamed

public text v1 · immutable
#333250 ·published 2007-01-30 20:10 UTC
rendered paste body
case EV_OBITUARY:
			// Don't count kills in warmup.
			if (eth.cgs_gamestate != GS_PLAYING)
				break;
			// For now this way, report if it doesen't work on some mods
			int target, attacker;
			if (eth.mod->type == MOD_ETPRO) {
				target = es->time;
				attacker = es->time2;
			} else {
				target = es->otherEntityNum == es->otherEntityNum2;
				attacker = es->otherEntityNum2;
			}
			// If we do a selfkill or someone kills us, reset killing spree
			        if (target == eth.cg_clientNum && attacker == eth.cg_clientNum) {
                                
				if( attacker > MAX_CLIENTS )
					strncpy( eth.KillerName, "world" ,sizeof(eth.KillerName) );
				else
					strncpy( eth.KillerName, eth.clientInfo[attacker].name,sizeof(eth.KillerName) );
				
                                if (seth.value[VAR_KILLSPAM] && attacker != target)
                                        deathSpam();       
                                if (seth.value[VAR_KILLSPAM] && attacker == target)
                                        selfKillSpam();   		
				eth.killCountNoDeath = 0;
				eth.killSpreeCount = 0;
				eth.reviveSpree = 0;
				break;