Anyone here know's how to setup zombies with a headshot only kill ?
Please if anyone has a clue about post or pm me ! :rolleyes:
cheers fuchs
open your compiles and search for local_zombieDamage
e.g.
//local_zombieDamage = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_damageHandlerZ.sqf"; //Generated by the client who created a zombie to track damage
local_zombieDamage = compile preprocessFileLineNumbers "AlpenFestung\walkingdead\fn_damageHandlerZ.sqf";//Generated by the client who created a zombie to track damage
fn_damageHandlerZ.sqf found in dayz_code
//[unit, selectionName, damage, source, projectile]//will only run when local to the created object//record any key hits to the required selectionprivate["_zed","_selection","_damage","_hitter","_projectile","_headShots","_damageOrg"];
_zed = _this select0;
_selection = _this select1;
_damage = _this select2;
_hitter = _this select3;
_projectile = _this select4;if(local _zed)then{if(_damage >1&& _projectile !="")then{//Record deliberate critical damagesswitch(_selection)do{case"head_hit":{if(!(_zed getVariable["hitRegistered",false]))then{
_headShots = _hitter getVariable["headShots",0];
_hitter setVariable["headShots",(_headShots +1),true];
_zed setVariable["hitRegistered",true];};};};if(_projectile isKindOf "Bolt")then{
_damageOrg = _hitter getVariable["firedDamage",0];//_unit getVariable["firedSelection",_selection];if(_damageOrg < _damage)then{
_hitter setVariable["firedHit",[_zed,_selection],true];
_hitter setVariable["firedDamage",_damage,true];};};};};if(_selection =="head_hit")then{
_damage
}else{0};
I wanna take it on a higher level:
So if you shoot on their body nothing happens ,shooting in the head their dead!
Question
Fuchs
Hey Guys and Girls !
Anyone here know's how to setup zombies with a headshot only kill ?
Please if anyone has a clue about post or pm me ! :rolleyes:
cheers fuchs
open your compiles and search for local_zombieDamage
e.g.
fn_damageHandlerZ.sqf found in dayz_code
I wanna take it on a higher level:
So if you shoot on their body nothing happens ,shooting in the head their dead!
Anyone knows a really good scripting tutorial?
Edited by FuchsLink to comment
Share on other sites
5 answers to this question
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now