Skip to content

Commit

Permalink
default location map to hashmap
Browse files Browse the repository at this point in the history
  • Loading branch information
theace0296 committed Jan 22, 2023
1 parent fcab46d commit e6daa42
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions RandFramework/Server/mission/fn_startInfMission.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,10 @@ private _buildings = nil;
if (isNil "TRGM_VAR_allLocationPositions") then {
private _worldName = worldName;
TRGM_VAR_allLocationPositionsMap = profileNamespace getVariable "TRGM_VAR_allLocationPositionsMap";
TRGM_VAR_allLocationPositions = [nil, TRGM_VAR_allLocationPositionsMap get _worldName] select (!(isNil "TRGM_VAR_allLocationPositionsMap"));
if !(TRGM_VAR_allLocationPositionsMap isEqualType createHashMap) then {
TRGM_VAR_allLocationPositionsMap = createHashMap;
};
TRGM_VAR_allLocationPositions = TRGM_VAR_allLocationPositionsMap get _worldName;
private _LocationVersion = profileNamespace getVariable ["TRGM_VAR_LocationVersion", 0];

TRGM_VAR_bRecalculateLocationData = [false, true] select ((["RecalculateLocationData", 0] call BIS_fnc_getParamValue) isEqualTo 1);
Expand All @@ -143,7 +146,6 @@ if (isNil "TRGM_VAR_allLocationPositions") then {
};

if (isNil "TRGM_VAR_allLocationPositions" || TRGM_VAR_bRecalculateLocationData) then {
TRGM_VAR_allLocationPositionsMap = ([createHashMap, TRGM_VAR_allLocationPositionsMap] select (TRGM_VAR_allLocationPositionsMap isEqualType createHashMap));
TRGM_VAR_allLocationTypes = [];
"TRGM_VAR_allLocationTypes pushBack configName _x" configClasses (configFile >> "CfgLocationTypes");
private _allLocations = nearestLocations [(getMarkerPos "mrkHQ"), TRGM_VAR_allLocationTypes, worldSize];
Expand Down

0 comments on commit e6daa42

Please sign in to comment.