1.8.3 Humanity change not working?

Inkko

Valued Member!
I update my server the other day to 1.8.3 and Humanity changes seem to not function at all. Anyone else had this issue or is it just me? I'm about to just script in a while loop to fix it since its being a pain.
 
Well I tried completely default files as well and humanity does not work at all. It duplicates some action menus as well. I didn't run around while testing it for very long so I'm not sure if it occurs later or not but I made a script that changes you when you login. Also have an issue where lots of people are spawning in debug now... not liking 1.8.3 very much...
 
its unfortunate, i havent fooled with it much but it seems like a step backwards. they had pretty much conquered all the bugs and glitches and it was a pretty much error free. and it seems they have made a change in the file structure changing how entire systems are working such as the debris which i investagated last week.
i would would think staying with 1.8.2 would be wise until the next update. i think it was 1.7.7 that went this way, it was just a mess,and servers waited for the next update. now epoch seems to be the dominant mod already, so this may spell the end of dayz as it drives more servers away.
 
This update has been a nightmare lol. I swear it said reduced client lag or something like improved performance in the patch notes. Maybe I read that somewhere or maybe I'm just crazy. The only major things I've noted are humanity, extreme lag, and debug seems to be a popular spawn area once the server starts getting higher traffic.

I would have stayed with 1.8.2 but everyone likes playing the latest patch or just update without thinking. I just finished making a script for debug checking and humanity morph on spawning in... probably not the best way to do it but it should work for now since people seem to always complain about humanity not working or spawning in debug.

Code:
[] spawn {
    waituntil {alive player;!isNull (finddisplay 46);};
    debugloop =
    {
        // 20 sec loop to check for players in debug...
        _debuglp = 0;
        while {_debuglp < 20} do {
            _debug = getmarkerpos "respawn_west";
            _charPos = position player;
            _distance = _debug distance _charPos;
            // if in debug go to debugfix continue loop just incase?
            if (_distance < 3000) then {
                player call debugfix;
                sleep 5;
            };
            diag_log format['Debug Spawn Check: %1',_debuglp];
            _debuglp = _debuglp + 1;
            sleep 1;
        };
    };
    debugfix = {
        _debug = getmarkerpos "respawn_west";
        _charPos = position player;
        _distance = _debug distance _charPos;
        //_model = typeOf player;
        if (_distance < 3000) then {
            systemChat 'Debug: You are in debug. Fixing your position...';
            _mkr = getMarkerPos ("spawn" + str(floor(random 6)));
            _position = ([_mkr,0,1400,10,0,2,1] call BIS_fnc_findSafePos);
            sleep 1;
            if !((typeof(unitBackpack player)) in DayZ_Backpacks) then {  
                sleep 1;
                player addBackPack "DZ_Assault_Pack_EP1";
                {player addWeapon _x;} forEach ["ItemFlashlight","ItemCompass","ItemMap","ItemMachete","M9"];
                {player addMagazine _x;} forEach ["15Rnd_9x19_M9","15Rnd_9x19_M9","15Rnd_9x19_M9","ItemBandage","ItemBandage","ItemBandage","ItemBandage","ItemAntibiotic","ItemBloodbag","FoodSteakCooked","ItemPainkiller","ItemWaterbottle","PartGeneric"];
            };
            // not necessary with seperate humanity check now?
            /*if (_model in ["Survivor1_DZ","Survivor2_DZ","Bandit1_DZ","Survivor3_DZ","SurvivorW2_DZ","BanditW1_DZ"]) then {
                [player,0] call player_humanityChange;
            };*/
        player setPosATL [_position select 0,_position select 1,1500];[player,1500] spawn BIS_fnc_halo;
        systemChat 'Debug: New location found. Halo jumping into area... Dont forget to open your parachute!';
        };
    };
player call debugloop;
};
[] spawn {
    waituntil {alive player;!isNull (finddisplay 46);};
    // lets fix humanity...
    humanityfixloop = {
        _model = typeOf player;
        _humanity = player getvariable["humanity",0];
        // why the fuck is this not being sent from the server? PVCDZ_plr_Humanity
        // skip any models that aren't supported by humanity changes...
        if (_model in ["Survivor2_DZ","Bandit1_DZ","Survivor3_DZ","SurvivorW2_DZ","BanditW1_DZ"]) then {
            _isMen = _model == "Survivor2_DZ";
            _isMenH = _model == "Survivor3_DZ";
            _isMenB = _model == "Bandit1_DZ";
            _isWomen = _model == "SurvivorW2_DZ";
            _isWomenH = _model == "SurvivorW3_DZ"; //TODO
            _isWomenB = _model == "BanditW1_DZ";
            //bandit
            if (_humanity <= -2000) then {
                if (_isMen || _isMenH) then {
                    [dayz_playerUID,dayz_characterID,"Bandit1_DZ"] spawn player_humanityMorph;
                    sleep 5;
                };
                if (_isWomen || _isWomenH) then {
                    [dayz_playerUID,dayz_characterID,"BanditW1_DZ"] spawn player_humanityMorph;
                    sleep 5;
                };
            } else {
                //survivor
                if ((_humanity > -2000) && (_humanity <= 5000)) then {
                    if (_isMenH || _isMenB) then {
                        [dayz_playerUID,dayz_characterID,"Survivor2_DZ"] spawn player_humanityMorph;
                        sleep 5;
                    };
                    if (_isWomenH || _isWomenB) then {
                        [dayz_playerUID,dayz_characterID,"SurvivorW2_DZ"] spawn player_humanityMorph;
                        sleep 5;
                    };
                } else {
                    //hero
                    if (_humanity > 5000) then {
                        if (_isMen || _isMenB) then {
                            [dayz_playerUID,dayz_characterID,"Survivor3_DZ"] spawn player_humanityMorph;
                            sleep 5;
                        };
                        if (_isWomenB) then {
                            [dayz_playerUID,dayz_characterID,"SurvivorW2_DZ"] spawn player_humanityMorph;
                            sleep 5;
                        };
                    };
                };
            };
        };
    sleep 5;
    // this is the only wait so that the script stops here each time before continueing to check before repeating on change
    waituntil {(_humanity != (player getVariable["humanity",0]));};
    player call humanityfixloop;
    };
// initilize fix
player call humanityfixloop;
};

** Edit:
Maybe it was just me but humanity resulted in PC crashes occasionally...
 
Last edited:
This humanity problem, could it be whats also causing people to randomly spawn in debug with a blank screen/losing all their gear?

I'm -21k humanity and i spawn as a survivor. takes about 5 min and i'll randomly switch over to a bandit skin.


Is there a way to just disable the bandit skin change? like set the humanity required to like -5000000 ?
 
I forget which file its in but there used to be a part right after you logged in where it would check your humanity and assign the survivor, hero or bandit skin. simply change the part that assigns the bandit skin.
its in dayz_code .. either player_humanitychange or player_humanitymorph
 
Code:
    _isMen =        _model == "Survivor2_DZ";
    _isMenH =        _model == "Survivor3_DZ";
    _isMenB =        _model == "Bandit1_DZ";
    _isWomen =        _model == "SurvivorW2_DZ";
    _isWomenH =        _model == "SurvivorW3_DZ"; //TODO
    _isWomenB =        _model == "BanditW1_DZ";
playerhumanitychange ... set what skins you want them to be automatically assigned
 
I'm thinking about just removing humanity changes since it seems to just be creating lots of issues.... I think i'll just make skin parcels that you have multiple options to chose what to wear instead since humanity is a big issue at the moment...
 
What i'm looking for is where the humanity number is defined for bandit/survivor/hero, etc.

just change the bandit number to something that is impossible to reach ,and it'll take care of some of the problem with delay in the skins changing/bandit taking affect type stuff.
 
I gave you the file, I would just set the skin for bandit the same as survivor then it doesnt matter what the number is.
But all you had to do was open that file and look right below the part I posted.
// Bandit
if (_humanity <= -2000) then {

Actually I dont know what those defines for skins are used for because in the set bandit code you specify the skin there rather than using the defined values.... but yeah, I would just use the survivor skin for the bandit ..
cAmWP1K.png
 
I gave you the file, I would just set the skin for bandit the same as survivor then it doesnt matter what the number is.
But all you had to do was open that file and look right below the part I posted.
// Bandit
if (_humanity <= -2000) then {

Actually I dont know what those defines for skins are used for because in the set bandit code you specify the skin there rather than using the defined values.... but yeah, I would just use the survivor skin for the bandit ..
cAmWP1K.png
The defines that are highlighted are for the humanity changes to make sure you're in a skin that can change into the humanity morph; if you have -4k humanity and your skin is hero or survivor you change to bandit vs if your skin is bandit it does nothing or if your skin is something other then those. I would just do what someone else said and just set the required humanity extremely high so that humanity morphs just never happen.

if (_humanity > -5000000 && _humanity < 5000000) then {... ect
 
Well I kinda just removed humanity morph and made it kinda like epoch where you have to get a skin to change into what you want... you can read the spoilers if you're interested and what not in what i did.
okay what I've done now is in player_wearclothes.sqf I changed this portion:
Code:
if (_item == "Skin_Survivor2_DZ") then {
    if (_isBandit) then {
        _model = "Bandit1_DZ";
    };
    if (_isHero) then {
        _model = "Survivor3_DZ";
    };
};
to this:
Code:
if (_item == "Skin_Survivor2_DZ") then {
    if (_isBandit) then {
        _model = "Survivor2_DZ";
    };
    if (_isHero) then {
        _model = "Survivor2_DZ";
    };
};
In player_humanitychange.sqf I completely deleted from _model = typeOf player; all the way to the bottom leaving the last closing bracket which leaves just that beginning portion of code.

I then am using Extra_RC.hpp to add additional options to various parcels with humanity requirements on certain ones.

Example:
extra_rc
Code:
class ExtraRc {
    class Skin_Camo1_DZ {  
        class skin1 {
            text = "Hero Camo";
            script =  "['camoh','Skin_Camo1_DZ','FR_GL'] execVM 'custom\skins.sqf';";
        };
        class skin2 {
            text = "Bandit Camo";
            script =  "['camob','Skin_Camo1_DZ','GUE_Soldier_CO'] execVM 'custom\skins.sqf';";
        };
    };
    class Skin_Sniper1_DZ {
        class skin3 {
            text = "Hero Ghillie";
            script =  "['sniperh','Skin_Sniper1_DZ','GUE_Soldier_Sniper'] execVM 'custom\skins.sqf';";
        };
        class skin4 {
            text = "Bandit Ghillie";
            script =  "['sniperb','Skin_Sniper1_DZ','Ins_Soldier_Sniper'] execVM 'custom\skins.sqf';";
        };
    };
    class Skin_Soldier1_DZ {
        class skin5 {
            text = "Hero Soldier";
            script =  "['soldierh','Skin_Soldier1_DZ','GUE_Commander'] execVM 'custom\skins.sqf';";
        };
        class ski6 {
            text = "Bandit Soldier";
            script =  "['soldierb','Skin_Soldier1_DZ','TK_Soldier_EP1'] execVM 'custom\skins.sqf';";
        };
    };
    class Skin_Survivor2_DZ {
        class skin7 {
            text = "Wear Taki Civ";
            script = "['normal','Skin_Survivor2_DZ','TK_GUE_Soldier_Sniper_EP1'] execVM 'custom\skins.sqf';";
        };
        class skin8 {
            text = "Wear Bodyguard";
            script = "['normal','Skin_Survivor2_DZ','Soldier_Bodyguard_M4_PMC'] execVM 'custom\skins.sqf';";
        };
        class skin9 {
            text = "Wear Bodyguard 2";
            script = "['normal','Skin_Survivor2_DZ','Soldier_Bodyguard_AA12_PMC'] execVM 'custom\skins.sqf';";
        };
        class skin10 {
            text = "Wear Hero";
            script = "['normal','Skin_Survivor2_DZ','Survivor3_DZ'] execVM 'custom\skins.sqf';";
        };
        class skin11 {
            text = "Wear Bandit";
            script = "['normal','Skin_Survivor2_DZ','Bandit1_DZ'] execVM 'custom\skins.sqf';";
        };
        class skin12 {
            text = "Wear Bandit Female";
            script = "['normal','Skin_Survivor2_DZ','BanditW1_DZ'] execVM 'custom\skins.sqf';";
        };
        class skin13 {
            text = "Wear Female Clothing";
            script = "['normal','Skin_Survivor2_DZ','SurvivorW2_DZ'] execVM 'custom\skins.sqf';";
        };
   };
};
skins.sqf
Code:
private ["_skin","_removeSkin","_choice"];
if (isnil "LastSkinChange") then {
LastSkinChange = nil;
};
_skin = _this select 0;
_removeSkin = _this select 1;
_choice = _this select 2;
_humanity = player getVariable["humanity",0];
_model = typeOf player;
_AddSkin = "Skin_Survivor2_DZ"; // default
_SkinLastUsedTime = 30; // Amount of time in seconds before player can use lockpick again after a succesful use
// ---------------------- config end ---------------------

if (isnil "LastSkinChange") then {
_SkinChangeTime = 0;
} else {
_SkinChangeTime = time - LastSkinChange; // Variable used for easy reference in determining the self bloodbag cooldown
};
_lockpickUsageTime = time;
_timeout = player getVariable["combattimeout", 0];
_inCombat = if (_timeout >= diag_tickTime) then { true } else { false };

if(_SkinChangeTime < _SkinLastUsedTime) exitWith { // If cooldown is not done then exit script
    cutText [format["You may not change skins so soon please wait %1 more seconds!",round((_SkinChangeTime - _SkinLastUsedTime)*-1)], "PLAIN DOWN"]; //display text at bottom center of screen when players cooldown is not done
};

if (_inCombat) then { // Check if in combat
    cutText [format["You are in Combat and cannot continue your action!"], "PLAIN DOWN"]; //display text at bottom center of screen when in combat
} else {
// added model check to give correct parcels when changing between skins
if(_model in ["Sniper1_DZ","GUE_Soldier_Sniper","Ins_Soldier_Sniper"]) then{
    _AddSkin = "Skin_Sniper1_DZ";
};
if(_model in ["Camo1_DZ","GUE_Soldier_CO","FR_GL"]) then{
    _AddSkin = "Skin_Camo1_DZ";
};
if(_model in ["Soldier1_DZ","GUE_Commander","TK_Soldier_EP1"]) then{
    _AddSkin = "Skin_Soldier1_DZ";
};
if (_skin == "camoh") then {
    if(_humanity >= 5000) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to gain %2 more.",_humanity,(5000 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "camob") then {
    if(_humanity <= -2500) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to lose %2 .",_humanity,(-2500 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "soldierh") then {
    if(_humanity >= 5000) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to gain %2 more.",_humanity,(5000 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "soldierb") then {
    if(_humanity <= -2500) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to lose %2 .",_humanity,(-2500 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "sniperh") then {
    if(_humanity >= 5000) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to gain %2 more.",_humanity,(5000 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "sniperb") then {
    if(_humanity <= -2500) then{
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to lose %2 .",_humanity,(-2500 - _humanity)], "PLAIN DOWN"];
    };
};

if (_skin == "normal") then {
    if (_choice in ["Survivor3_DZ","SurvivorW3_DZ"]) then {
    if(_humanity >= 5000) then {
    player removeMagazine _removeSkin;
    player addMagazine _AddSkin;
    uisleep 0.5;
    [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
    player removeWeapon "ItemRadio";
    } else {
    closeDialog 0;
    cutText [format["You do not have the required humanity. Your humanity is %1, you need to gain %2 more.",_humanity,(5000 - _humanity)], "PLAIN DOWN"];
    };
    } else {
        if (_choice in ["SurvivorW2_DZ","Bandit1_DZ"]) then {
        if(_humanity <= -2500) then {
        player removeMagazine _removeSkin;
        player addMagazine _AddSkin;
        uisleep 0.5;
        [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
        player removeWeapon "ItemRadio";
        } else {
        closeDialog 0;
        cutText [format["You do not have the required humanity. Your humanity is %1, you need to lose %2 .",_humanity,(-2500 - _humanity)], "PLAIN DOWN"];
        };
        } else {
            player removeMagazine _removeSkin;
            player addMagazine _AddSkin;
            uisleep 0.5;
            [dayz_playerUID,dayz_characterID,_choice] spawn player_humanityMorph;
            player removeWeapon "ItemRadio";
        };
    };
};
};
 
Back
Top