mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 04:02:37 +03:00
Update damage handler and improve study body
Vanilla development commits applied:3db0fe8e7a73a63898f108e18d5b52126da2dcd3d5fa323865d37526fcc65fcca134f0c9c1fc934d
This commit is contained in:
@@ -1,17 +1,22 @@
|
||||
private["_body","_name","_method","_methodStr"];
|
||||
private["_body","_name","_method","_methodStr","_message"];
|
||||
|
||||
_body = _this select 3;
|
||||
_name = _body getVariable["bodyName","unknown"];
|
||||
_method = _body getVariable["deathType","unknown"];
|
||||
_methodStr = localize format ["str_death_%1",_method];
|
||||
_killingBlow = _body getVariable "KillingBlow";
|
||||
_killingBlow = _body getVariable ["KillingBlow",objNull];
|
||||
|
||||
format[localize "str_player_studybody",_name,_methodStr] call dayz_rollingMessages;
|
||||
// "His/Her name was %1, it appears he/she died from %2"
|
||||
_message = if (_body isKindOf "SurvivorW2_DZ") then {"str_player_studybody_female"} else {"str_player_studybody"};
|
||||
|
||||
if (typeName _killingBlow == "OBJECT") then {
|
||||
_ConfirmedHumanKills = _killingBlow getVariable ["ConfirmedHumanKills",0];
|
||||
_killingBlow setVariable ["ConfirmedHumanKills",(_ConfirmedHumanKills + 1),true];
|
||||
} else {
|
||||
_ConfirmedBanditKills = _killingBlow getVariable ["ConfirmedBanditKills",0];
|
||||
_killingBlow setVariable ["ConfirmedBanditKills",(_ConfirmedBanditKills + 1),true];
|
||||
format[localize _message,_name,_methodStr] call dayz_rollingMessages;
|
||||
|
||||
if (!(isNull _killingBlow) AND {(isPlayer _killingBlow)}) then {
|
||||
if (typeName _killingBlow == "OBJECT") then {
|
||||
_ConfirmedHumanKills = _killingBlow getVariable ["ConfirmedHumanKills",0];
|
||||
_killingBlow setVariable ["ConfirmedHumanKills",(_ConfirmedHumanKills + 1),true];
|
||||
} else {
|
||||
_ConfirmedBanditKills = _killingBlow getVariable ["ConfirmedBanditKills",0];
|
||||
_killingBlow setVariable ["ConfirmedBanditKills",(_ConfirmedBanditKills + 1),true];
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user