Hey all,
Was looking into how to setup a database for my mission when I noticed that the inbuilt ALiVE saving can do custom variables .
So i gave it a try but for some reason I can't get it to 'stick', attempting to create persistent 'factions' for my players, so when they join a faction via dialog, it gives them a loadout but then also ["Player_Rank", "Airman Basic"] call ALiVE_fnc_setData;
["Player_Faction", "United States Airforce"] call ALiVE_fnc_setData;
.
When a player dies, I want them to respawn at a faction specific place, so I have this in place;
onPlayerRespawn.sqf
getFaction = ["Player_Faction"] call ALiVE_fnc_getData; getRank = ["Player_Rank"] call ALiVE_fnc_getData; if (getFaction == "United States Air Force") then { Player setPos (getMarkerPos "AviationSpawn"); comment "Remove existing items"; removeAllWeapons player; removeAllItems player; removeAllAssignedItems player; removeUniform player; removeVest player; removeBackpack player; removeHeadgear player; removeGoggles player; comment "Add containers"; player forceAddUniform "rhs_uniform_cu_ucp"; player addHeadgear "rhsusf_patrolcap_ucp"; comment "Add weapons"; comment "Add items"; player linkItem "ItemMap"; player linkItem "ItemCompass"; player linkItem "ItemWatch"; };
Am I using this wrong or is there something else at fault here perhaps?
Thanks in advance (again)!