hello everybody
when the hunter want to kill the zombie(s) with the bazooka, the bazooka can kill the hunter too.
i would like to know if it is possible to protect the hunter who use the bazooka ?
hello everybody
when the hunter want to kill the zombie(s) with the bazooka, the bazooka can kill the hunter too.
i would like to know if it is possible to protect the hunter who use the bazooka ?
yes, it is!
set logfile 2
I have added in my mod an if with a return when the hunter is moving to a other team. (And i also check if he killed or damaged a other player.)
Edit: see the damage/killed callback.
Edit 2: Can you make proper thread title next time? Instead of just 'bazooka' use a title like 'How to prevent hunter from killing other hunters with bazooka?'.
Edit 3: @ORDI I assume you have friendly fire off, right?
ORDI (24th April 2015)
yep it is off
i mean when the hunter kill the zombies with the bazooka, it can kill himself also
Last edited by ORDI; 24th April 2015 at 18:05.
ok, topic solved, thx for help
Constant reminder: post solution, if found by yourself
timescale 0.01
PHP Code:
Callback_PlayerDamage(eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, psOffsetTime)
{
if(self.sessionteam == "spectator")
return;
if (isdefined(eAttacker) && isdefined(self) && eAttacker == self && sWeapon == "rpg_mp")// the bazooka
return;
anyway only the hunters can have this bazooka. and yes is that what i wanted