Realistic Study Body Function - Somebody Needs To Start This :)

I don't have the time yet to actually look into this, but one can use this script as a bases to create a better death message. http://www.armaholic.com/page.php?id=14220&highlight=SPY

Use the series of checks to check what the player died from and combine it with what you guys have here. Would be a big undertaking to get everything to work right. But it would be an awesome feature. I'll probably mess with it on my free time. :)
 
i followed the tutorial, but no additional information occurs on the "study body" function :(
on top of this the study body function is displayed alle the time while mouse wheel scrolling...

and why it is so important to put that code
Code:
//Player only
if (!isDedicated) then {
    fnc_usec_selfActions =    compile preprocessFileLineNumbers "fn_selfActions.sqf";
    player_death =        compile preprocessFileLineNumbers "player_death.sqf";
};
after
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf;

shouldn't it be inserted to

Code:
if (!isDedicated) then {

at the nearly end of the init, looking like this?

Code:
if (isServer) then {
//===================piXel 15-02-2013===========
    dogOwner = [];
//=========================end==================   
    _serverMonitor =    [] execVM "\z\addons\dayz_code\system\server_monitor.sqf";
};
gc_veh_flip_script_script_action_manager = execVM "Scripts\gc_veh_flip\action_manager.sqf";
 
if (!isDedicated) then {
    fnc_usec_selfActions =    compile preprocessFileLineNumbers "dayz_code\compile\fn_selfActions.sqf";
    player_death =        compile preprocessFileLineNumbers "dayz_code\compile\player_death.sqf";
    //Refuel Script
    [] execVM "Scripts\kh_actions.sqf";
    [] execVM "Scripts\change_streetlights.sqf";
    //Conduct map operations
    0 fadeSound 0;
    waitUntil {!isNil "dayz_loadScreenMsg"};
    dayz_loadScreenMsg = (localize "STR_AUTHENTICATING");
    //Run the player monitor
//Run the player monito

Regards
 
I can only seem to get player bodies appearing as "The body is still warm." using this. Animal bodies show no temp, as per;
Code:
if (_deathTime < 0) then {
    _temp = "";

Here's my study_body.sqf

Code:
private ["_body", "_name", "_kills", "_killsH", "_killsB", "_humanity","_temp","_diff","_dateNow","_deathTime","_body","_name","_method","_methodStr","_killerName","_weapon","_distance"];
 
_body =    _this select 3;
_name =    _body getVariable["bodyName","unknown"];
_method =    _body getVariable["deathType","unknown"];
_deathTime =    _body getVariable["deathTime",-1];
_methodStr = localize format ["str_death_%1",_method];
_killerName = _body getVariable["AttackedByName", "nil"];
_weapon = _body getVariable["AttackedByWeapon", "nil"];
_distance = _body getVariable["AttackedFromDistance", "nil"];
_kills = _body getVariable ["zombieKills",0];
_killsH = _body getVariable ["humanKills",0];
_killsB = _body getVariable ["banditKills",0];
_humanity = _body getVariable ["humanity",0];
 
//diag_log ("STUDY: deathtime " +str(_deathTime));
if (_deathTime < 0) then {
    _temp = "";
} else {
    _dateNow = (DateToNumber date);
    _diff = (_dateNow - _deathTime) * 525948;
    _temp = "The body is freezing.";
 
    if ( _diff < 30 ) then {
        _temp = "The body is cold.";
    };
 
    if ( _diff < 15 ) then {
        _temp = "The body is slightly warm.";
    };
 
    if ( _diff < 5 ) then {
        _temp = "The body is still warm.";
    };
};
 
cutText [format["Their name was %1. %2",_name,_temp], "PLAIN DOWN"];
sleep 5;
 
cutText [format["It appears there is a journal on the body..."], "PLAIN DOWN"];
sleep 5;
 
cutText [format["Zombie Kills: %1, Murders: %2, Bandit Kills: %3, Humanity: %4.",_kills,_killsH,_killsB,_humanity], "PLAIN DOWN"];
sleep 5;


Edit;

Ok, so it does seem to show the other levels, but it changes very slowly. I'm just going to change the limits for each and see how that affects it.
 
Back
Top