This code will allow players to throw nades/rpg/melee head shot/body shots and damage the zombie.
Everything here is server-sided open WarZ_Server.sln
sobj_Zombie.cpp (Search for)
(optional) if you guys want zombie body shots to inflict damage add this under the code aboveCode:bool obj_Zombie::ApplyDamage(GameObject* fromObj, float damage, int bodyPart, STORE_CATEGORIES damageSource) { if(ZombieState == EZombieStates::ZState_Dead) return false; float dmg = damage;
(optional) if you guys want to enable melee headshots/Grenades/RPGCode://If shots/dmg were body shots if(bodyPart!=1) //we want to half the damage value dmg = (dmg/2);
sobj_Zombie.cpp (Search for)
Replace that code above with or comment them out.Code:// only hitting head will lower zombie's health // this is the worst code preventing everything remove it if(bodyPart !=1) { dmg = 0; } //find and remove this code also if(damageSource != storecat_MELEE && bodyPart == 1) // everything except for melee: one shot in head = kill { dmg = 1000; }
Code:// everything headshot is death if(bodyPart == 1) dmg = 1000;


Reply With Quote![[Release] Enable Zombie Grenade/RPG/Melee Headshot/Bodyshots Damage](http://ragezone.com/hyper728.png)

