diff --git a/Sources/epoch_server/init/server_init.sqf b/Sources/epoch_server/init/server_init.sqf index 56024cd1..4e5204ae 100644 --- a/Sources/epoch_server/init/server_init.sqf +++ b/Sources/epoch_server/init/server_init.sqf @@ -283,6 +283,20 @@ if !(_radioactiveLocations isEqualTo []) then { _markers = ["Radiation", _position] call EPOCH_server_createGlobalMarkerSet; }; }; + _customRadioactiveLocations = getArray(_epochConfig >> worldName >> "customRadioactiveLocations"); + if !(_customRadioactiveLocations isEqualTo []) then { + { + _x params [["_position",[0,0,0]],["_radius",0],["_className",""] ]; + if ((!(_position isEqualTo [0,0,0]) && !(_radius isEqualTo 0) && !(_className isEqualTo "")) && ((nearestObjects [_position, _blacklist, _distance]) isEqualTo [])) then{ + _object = (_x select 2) createVehicle _position; + _object setVariable ["EPOCH_Rads",[random 666,(_x select 1)],true]; + _markers = ["Radiation", _position] call EPOCH_server_createGlobalMarkerSet; + _object setVariable ["EPOCH_MarkerSet",_markers,true]; + }else{ + diag_log "EPOCHDebug:Check your custom radioactive locations for errors or blacklisted locations"; + }; + }forEach _customRadioactiveLocations; + }; }; missionNamespace setVariable ["EPOCH_radioactiveLocations", _radioactiveLocationsTmp, true]; diff --git a/Sources/epoch_server_settings/config.cpp b/Sources/epoch_server_settings/config.cpp index bfb0cc60..25ea8b79 100644 --- a/Sources/epoch_server_settings/config.cpp +++ b/Sources/epoch_server_settings/config.cpp @@ -66,6 +66,11 @@ class CfgEpoch // Block radioactive locations spawn radioactiveLocBLObjects[] = {"PlotPole_EPOCH"}; radioactiveLocBLDistance = 500; + customRadioactiveLocations[] = { // position , intensity , object to spawn radiated + // {{11650,11900,0}, 500, "Land_Device_assembled_F"}, + // {{0,0,0}, 0, ""} //any of these will throw an error in the rpt + // leave this empty to spawn 0 custom locations + }; traderBlds[] = {"House", "Building"}; traderHomes[] = {"House", "Building"}; traderUniforms[] = {"U_OG_leader", "U_C_Poloshirt_stripped", "U_C_Poloshirt_blue", "U_C_Poloshirt_burgundy", "U_C_Poloshirt_tricolour", "U_C_Poloshirt_salmon", "U_C_Poloshirt_redwhite", "U_C_Poor_1", "U_C_WorkerCoveralls", "U_C_Journalist", "U_C_Scientist", "U_OrestesBody"};