Jump to content

Search the Community

Showing results for tags 'loadout on humanity'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements
  • DayZ
    • Discussion
    • Public Servers
    • DayZ SA Resources
    • Q&A Section
  • ArmA 3
    • Epoch Survival
    • Community Projects
    • Q&A Section
    • Terrain Discussion
    • Resources
  • Arma 3 Resources
  • ArmA 2
    • General Discussion.
    • Q&A Section
    • Resources
    • Legacy Resources
    • A2: Community Projects
    • A2 Community Servers
  • Space Engineers
    • General Discussion.
    • Public Servers
  • Other Games
    • Discussion
  • Off Topic
    • Off Topic

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 1 result

  1. https://epochmod.com/forum/topic/43153-released-custom-spawn-loadout-dependend-on-humanity/#comment-285478 -- OLD THREAT -- SOLVED! Hello guys, I have a question about spawning my gear on login. I want my default gear dependend on the amount of humanity. i'm currently working in the file: z\dayz_server\compile\server_playerLogin.sqf But i cant get a reach on how to get that variable in the server. I dont know how to atleast. I've tried alot of variables like: player getVariable['humanity',0]; which gives me <NULL> and trying to debug _playerObj and_primary without luck.. server just crashes without any notification. Here was my line of code to debug that: diag_log format["object _playerObj: %1",_playerObj]; diag_log format["object _primary: %1",_primary]; does anyone know how to get that humanity variable ? i want to make a switch statement in the if statement here: if (!_isNew) then { //RETURNING CHARACTER _inventory = _primary select 4; _backpack = _primary select 5; _survival = _primary select 6; _CharacterCoins = _primary select 7; _model = _primary select 8; _group = _primary select 9; _playerCoins = _primary select 10; _BankCoins = _primary select 11; _hiveVer = _primary select 12; if !(_model in AllPlayers) then {_model = "Survivor2_DZ";}; } else { _isInfected = if (DZE_PlayerZed) then {_primary select 3} else {0}; _model = _primary select 4; _group = _primary select 5; _playerCoins = _primary select 6; _BankCoins = _primary select 7; _hiveVer = _primary select 8; if (isNil "_model") then { _model = "Survivor2_DZ"; } else { if (_model == "") then {_model = "Survivor2_DZ";}; }; //Record initial inventory only if not player zombie if (_isInfected != 1) then { _config = configFile >> "CfgSurvival" >> "Inventory" >> "Default"; _mags = getArray (_config >> "magazines"); _wpns = getArray (_config >> "weapons"); _bcpk = getText (_config >> "backpack"); // Switch statement right here if (!isNil "DefaultMagazines") then {_mags = DefaultMagazines;}; if (!isNil "DefaultWeapons") then {_wpns = DefaultWeapons;}; if (!isNil "DefaultBackpack") then {_bcpk = DefaultBackpack;}; //Wait for HIVE to be free _key = format["CHILD:203:%1:%2:%3:",_charID,[_wpns,_mags],[_bcpk,[],[]]]; _key call server_hiveWrite; }; Something like: if (!_isNew) then { //RETURNING CHARACTER _inventory = _primary select 4; _backpack = _primary select 5; _survival = _primary select 6; _CharacterCoins = _primary select 7; _model = _primary select 8; _group = _primary select 9; _playerCoins = _primary select 10; _BankCoins = _primary select 11; _hiveVer = _primary select 12; if !(_model in AllPlayers) then {_model = "Survivor2_DZ";}; } else { _isInfected = if (DZE_PlayerZed) then {_primary select 3} else {0}; _model = _primary select 4; _group = _primary select 5; _playerCoins = _primary select 6; _BankCoins = _primary select 7; _hiveVer = _primary select 8; if (isNil "_model") then { _model = "Survivor2_DZ"; } else { if (_model == "") then {_model = "Survivor2_DZ";}; }; //Record initial inventory only if not player zombie if (_isInfected != 1) then { _config = configFile >> "CfgSurvival" >> "Inventory" >> "Default"; _mags = getArray (_config >> "magazines"); _wpns = getArray (_config >> "weapons"); _bcpk = getText (_config >> "backpack"); // * CUSTOM LOADOUT SWITCHCASE! * switch (true) do { case(_humanity >= 5000): { DefaultMagazines = ["itemMap" //etc...]; }; }; if (!isNil "DefaultMagazines") then {_mags = DefaultMagazines;}; if (!isNil "DefaultWeapons") then {_wpns = DefaultWeapons;}; if (!isNil "DefaultBackpack") then {_bcpk = DefaultBackpack;}; //Wait for HIVE to be free _key = format["CHILD:203:%1:%2:%3:",_charID,[_wpns,_mags],[_bcpk,[],[]]]; _key call server_hiveWrite; }; };
×
×
  • Create New...