From 852ef0a69ef23cd90072ebf813ef292a583926e2 Mon Sep 17 00:00:00 2001 From: second_coming Date: Tue, 22 Mar 2016 14:14:10 +0000 Subject: [PATCH] Update startOccupation.sqf --- startOccupation.sqf | 59 +++++++++------------------------------------ 1 file changed, 11 insertions(+), 48 deletions(-) diff --git a/startOccupation.sqf b/startOccupation.sqf index 1ea42d7..af29d6f 100644 --- a/startOccupation.sqf +++ b/startOccupation.sqf @@ -1,82 +1,45 @@ -//////////////////////////////////////////////////////////////////////// -// -// Server Occupation script by second_coming -// -// Version 2.0 -// -// http://www.exilemod.com/profile/60-second_coming/ -// -// This script uses the fantastic DMS by Defent and eraser1 -// -// http://www.exilemod.com/topic/61-dms-defents-mission-system/ -// -//////////////////////////////////////////////////////////////////////// - diag_log format ["[OCCUPATION]:: Giving the server time to start before starting [OCCUPATION] (%1)",time]; uiSleep 30; diag_log format ["[OCCUPATION]:: Initialised at %1",time]; -// Shared Config for each occupation monitor -maxAIcount = 100; // the maximum amount of AI, if the AI count is above this then additional AI won't spawn -minFPS = 8; // any lower than minFPS on the server and additional AI won't spawn -scaleAI = 10; // any more than _scaleAI players on the server and _maxAIcount is reduced for each extra player -useWaypoints = true; // When spawning AI create waypoints to make them enter buildings (can affect performance when the AI is spawned and the waypoints are calculated) -debug = false; // set to true for debug log information and map markers -_occupyPlaces = true; // true if you want villages,towns,cities patrolled -_occupyMilitary = false; // true if you want military buildings patrolled (specify which types of building in occupationMilitary.sqf) -_occupyStatic = false; // true if you want to garrison AI in specific locations (not working yet) - -// Settings for roaming ground vehicle AI -_occupyVehicle = true; // true if you want to have roaming AI vehicles -VehicleClassToUse = ["Exile_Car_LandRover_Green","Exile_Car_UAZ_Open_Green","Exile_Car_Offroad_Armed_Guerilla01"]; // class name of the ground vehicle to use -liveVehicles = 0; // leave as zero -maxNumberofVehicles = 3; // Number of roaming vehicles required -publicVariable "liveVehicles"; - -_occupySky = true; // true if you want to have roaming AI helis -HeliClassToUse = ["Exile_Chopper_Huey_Armed_Green","Exile_Chopper_Hellcat_Green","Exile_Chopper_Mohawk_FIA"]; // class name of the air vehicle to use -liveHelis = 0; // leave as zero -maxNumberofHelis = 3; // Number of roaming vehicles required -publicVariable "liveHelis"; - -if (worldName == 'Namalsk') then { maxAIcount = 80; }; +if(debug) then { refreshTime = 60; }else{ refreshTime = 300; }; // Add selected occupation scripts to Exile Threading System -if(_occupySky) then +if(occupySky) then { uiSleep 30; // delay the start fnc_occupationSkyMonitor = compile preprocessFileLineNumbers "\x\addons\a3_exile_occupation\occupationSky.sqf"; - [300, fnc_occupationSkyMonitor, [], true] call ExileServer_system_thread_addTask; + [refreshTime, fnc_occupationSkyMonitor, [], true] call ExileServer_system_thread_addTask; }; -if(_occupyVehicle) then +if(occupyVehicle) then { uiSleep 30; // delay the start fnc_occupationVehicleMonitor = compile preprocessFileLineNumbers "\x\addons\a3_exile_occupation\occupationVehicle.sqf"; - [300, fnc_occupationVehicleMonitor, [], true] call ExileServer_system_thread_addTask; + [refreshTime, fnc_occupationVehicleMonitor, [], true] call ExileServer_system_thread_addTask; }; -if(_occupyStatic) then +if(occupyStatic) then { uiSleep 30; // delay the start fnc_occupationStaticMonitor = compile preprocessFileLineNumbers "\x\addons\a3_exile_occupation\occupationStatic.sqf"; - [300, fnc_occupationStaticMonitor, [], true] call ExileServer_system_thread_addTask; + [refreshTime, fnc_occupationStaticMonitor, [], true] call ExileServer_system_thread_addTask; }; -if(_occupyPlaces) then +if(occupyPlaces) then { uiSleep 30; // delay the start fnc_occupationMonitor = compile preprocessFileLineNumbers "\x\addons\a3_exile_occupation\occupation.sqf"; - [300, fnc_occupationMonitor, [], true] call ExileServer_system_thread_addTask; + [refreshTime, fnc_occupationMonitor, [], true] call ExileServer_system_thread_addTask; }; -if(_occupyMilitary) then +if(occupyMilitary) then { uiSleep 30; // delay the start fnc_occupationMilitaryMonitor = compile preprocessFileLineNumbers "\x\addons\a3_exile_occupation\occupationMilitary.sqf"; - [300, fnc_occupationMilitaryMonitor, [], true] call ExileServer_system_thread_addTask; + [refreshTime, fnc_occupationMilitaryMonitor, [], true] call ExileServer_system_thread_addTask; };