Skip to content

Commit

Permalink
Preload findEmptyPosition (#1059)
Browse files Browse the repository at this point in the history
  • Loading branch information
Vdauphin authored Mar 14, 2021
1 parent e03dc3b commit 3ebf56f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions =BTC=co@30_Hearts_and_Minds.Altis/core/fnc/city/create.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ if (btc_p_sea) then {
_city setVariable ["hasbeach", ((selectBestPlaces [_position, 0.8 * _radius, "sea", 10, 1]) select 0 select 1) isEqualTo 1];
};

_position findEmptyPositionReady [0, _radius];

btc_city_all set [_id, _city];
[_position, _radius, _city, _has_en, _name, _type, _id] call btc_fnc_city_trigger_player_side;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ if (btc_debug) then {deleteMarker format ["loc_%1", _id];};
deleteVehicle (_city getVariable ["trigger_player_side", objNull]);

[_pos, btc_hideouts_radius, _city, _city getVariable "occupied", _city getVariable "name", _city getVariable "type", _city getVariable "id"] call btc_fnc_city_trigger_player_side;
_pos findEmptyPositionReady [0, _city getVariable ["radius", 100]];

private _hideout = [_pos] call btc_fnc_mil_create_hideout_composition;
clearWeaponCargoGlobal _hideout;
Expand Down

0 comments on commit 3ebf56f

Please sign in to comment.