mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2026-02-04 15:22:53 +03:00
Move HeliCrash and CarePackage area variables to markers
This allows finer grained control of crashsite, carepackage and infected camp spawn positions and radii (further north, south, east, west, etc.). Also removed some hardcoded checks for Chernarus, since dayz_townGenerator should always be off on other maps for now. Someone may add town generator coordinates for other maps later. Related vanilla commits:b20b402bf07c8b69eb827dfd3ef9cf
This commit is contained in:
@@ -179,7 +179,7 @@ if (count _stats > 0) then {
|
||||
if (_randomSpot) then {
|
||||
private ["_counter","_position","_isNear","_isZero","_mkr"];
|
||||
if (!isDedicated) then {endLoadingScreen;};
|
||||
_IslandMap = if (toLower worldName in ["caribou","cmr_ovaron","dingor","fallujah","fapovo","fdf_isle1_a","isladuala","lingor","mbg_celle2","namalsk","napf","oring","panthera2","sara","sauerland","smd_sahrani_a2","tavi","trinity","utes"]) then {true} else {false};
|
||||
_IslandMap = if (toLower worldName in ["caribou","cmr_ovaron","dayznogova","dingor","dzhg","fallujah","fapovo","fdf_isle1_a","isladuala","lingor","mbg_celle2","namalsk","napf","oring","panthera2","sara","sauerland","smd_sahrani_a2","tasmania2010","tavi","trinity","utes"]) then {true} else {false};
|
||||
|
||||
//spawn into random
|
||||
_findSpot = true;
|
||||
|
||||
@@ -15,8 +15,8 @@ Author:
|
||||
//Number of care packages to spawn
|
||||
#define SPAWN_NUM 6
|
||||
|
||||
#define SEARCH_CENTER dayz_centerMarker
|
||||
#define SEARCH_RADIUS HeliCrashArea
|
||||
#define SEARCH_CENTER getMarkerPos "carepackages"
|
||||
#define SEARCH_RADIUS (getMarkerSize "carepackages") select 0
|
||||
#define SEARCH_DIST_MIN 30
|
||||
#define SEARCH_SLOPE_MAX 1000
|
||||
#define SEARCH_BLACKLIST [[[12923,3643],[14275,2601]]]
|
||||
|
||||
@@ -21,8 +21,8 @@ Author:
|
||||
#define SPAWN_CHANCE 0.75
|
||||
|
||||
//Parameters for finding a suitable position to spawn the crash site
|
||||
#define SEARCH_CENTER dayz_centerMarker
|
||||
#define SEARCH_RADIUS HeliCrashArea
|
||||
#define SEARCH_CENTER getMarkerPos "crashsites"
|
||||
#define SEARCH_RADIUS (getMarkerSize "crashsites") select 0
|
||||
#define SEARCH_DIST_MIN 20
|
||||
#define SEARCH_SLOPE_MAX 2
|
||||
#define SEARCH_BLACKLIST [[[2092,14167],[10558,12505]]]
|
||||
|
||||
@@ -29,8 +29,8 @@ Author:
|
||||
#define OBJECT_RADIUS_MIN 8
|
||||
#define OBJECT_RADIUS_MAX 13
|
||||
|
||||
#define SEARCH_CENTER dayz_centerMarker
|
||||
#define SEARCH_RADIUS HeliCrashArea
|
||||
#define SEARCH_CENTER getMarkerPos "center"
|
||||
#define SEARCH_RADIUS (getMarkerSize "center") select 0
|
||||
#define SEARCH_EXPRESSION "(5 * forest) + (4 * trees) + (3 * meadow) - (20 * houses) - (30 * sea)" //+ (3 * meadow) - (20 * houses) - (30 * sea)
|
||||
#define SEARCH_PRECISION 30
|
||||
#define SEARCH_ATTEMPTS 10
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
private ["_position","_veh","_istoomany","_spawnveh","_positions"];
|
||||
|
||||
_position = [dayz_centerMarker,0,(HeliCrashArea*0.75),10,0,2000,0] call BIS_fnc_findSafePos;
|
||||
_position = [getMarkerPos "center",0,(((getMarkerSize "center") select 1)*0.75),10,0,2000,0] call BIS_fnc_findSafePos;
|
||||
|
||||
if ((count _position) == 2) then {
|
||||
_positions = selectBestPlaces [_position, 500, "(1 + forest) * (1 + hills) * (1 - houses) * (1 - sea)", 10, 5];
|
||||
|
||||
@@ -34,11 +34,11 @@ if (count AllowedVehiclesList == 0) then {
|
||||
if (_isShip or _isAir) then {
|
||||
if (_isShip) then {
|
||||
// Spawn anywhere on coast on water
|
||||
_position = [dayz_centerMarker,0,DynamicVehicleArea,10,1,2000,1] call BIS_fnc_findSafePos;
|
||||
_position = [getMarkerPos "center",0,((getMarkerSize "center") select 1),10,1,2000,1] call BIS_fnc_findSafePos;
|
||||
//diag_log("DEBUG: spawning boat near coast " + str(_position));
|
||||
} else {
|
||||
// Spawn air anywhere that is flat
|
||||
_position = [dayz_centerMarker,0,DynamicVehicleArea,10,0,2000,0] call BIS_fnc_findSafePos;
|
||||
_position = [getMarkerPos "center",0,((getMarkerSize "center") select 1),10,0,2000,0] call BIS_fnc_findSafePos;
|
||||
//diag_log("DEBUG: spawning air anywhere flat " + str(_position));
|
||||
};
|
||||
} else {
|
||||
|
||||
@@ -16,7 +16,7 @@ while {_counter < _amount} do {
|
||||
//_radius = 0;
|
||||
_method = "CAN_COLLIDE";
|
||||
|
||||
_position = [dayz_centerMarker,1,6500,1] call fn_selectRandomLocation;
|
||||
_position = [getMarkerPos "center",1,6500,1] call fn_selectRandomLocation;
|
||||
|
||||
//Create Zed
|
||||
_agent = createAgent [_type, _position, [], 1, _method];
|
||||
|
||||
Reference in New Issue
Block a user