more privates, cleanup and fixes.

This commit is contained in:
vbawol 2017-05-02 07:35:38 -05:00
parent f101f66281
commit 52db132ca9
8 changed files with 24 additions and 13 deletions

View File

@ -50,5 +50,5 @@ switch _trgtType do {
}; };
default {diag_log format["Epoch: ADMIN: Marker delete failed at %1 called by %2.", _mPos, _trgt];}; default {diag_log format["Epoch: ADMIN: Marker delete failed at %1 called by %2.", _mrkrName, _trgtObj];};
}; };

View File

@ -10,7 +10,7 @@
Arma Public License Share Alike (APL-SA) - https://www.bistudio.com/community/licenses/arma-public-license-share-alike Arma Public License Share Alike (APL-SA) - https://www.bistudio.com/community/licenses/arma-public-license-share-alike
Github: Github:
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server/init/server_init.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server/init/server_variables.sqf
*/ */
EPOCH_BuildingSlots = []; EPOCH_BuildingSlots = [];
EPOCH_TraderSlots = []; EPOCH_TraderSlots = [];
@ -26,7 +26,7 @@ EPOCH_staticNPCTraderPos = [];
EPOCH_traderStoredVehicles = []; EPOCH_traderStoredVehicles = [];
EPOCH_traderStoredVehiclesCnt = []; EPOCH_traderStoredVehiclesCnt = [];
_configArray = [ private _configArray = [
["serverRestart", false], ["serverRestart", false],
["forceRestartTime", 14400], ["forceRestartTime", 14400],
["StorageSlotsLimit",1500], ["StorageSlotsLimit",1500],
@ -83,8 +83,8 @@ EPOCH_fnc_returnConfigEntry = {
// Cast default vars to global vars // Cast default vars to global vars
// Note: TODO not all of these should be cast to a global var to save memory. If used only once use config lookup. // Note: TODO not all of these should be cast to a global var to save memory. If used only once use config lookup.
_serverSettingsConfig = configFile >> "CfgEpochServer"; private _serverSettingsConfig = configFile >> "CfgEpochServer";
{ {
_varData = [_serverSettingsConfig,_x select 0,_x select 1] call EPOCH_fnc_returnConfigEntry; private _varData = [_serverSettingsConfig,_x select 0,_x select 1] call EPOCH_fnc_returnConfigEntry;
missionNamespace setVariable[format["EPOCH_%1", _x select 0], _varData]; missionNamespace setVariable[format["EPOCH_%1", _x select 0], _varData];
}forEach _configArray; }forEach _configArray;

View File

@ -6,6 +6,9 @@
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/AirDrop.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/AirDrop.sqf
*/ */
// 50% chance every 45 minutes by default // 50% chance every 45 minutes by default
//[[[cog import generate_private_arrays ]]]
private ["_chance","_player","_players"];
//[[[end]]]
_chance = 50; _chance = 50;
if (random 100 < _chance) then { if (random 100 < _chance) then {

View File

@ -5,7 +5,9 @@
Improvements and or bugfixes and other contributions are welcome via the github: Improvements and or bugfixes and other contributions are welcome via the github:
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/CarnivalSpawner.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/CarnivalSpawner.sqf
*/ */
private ["_item","_marker","_ferrisPosition"]; //[[[cog import generate_private_arrays ]]]
private ["_ferrisPosition","_item","_marker"];
//[[[end]]]
_ferrisPosition = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 4000, 0] call BIS_fnc_findSafePos; _ferrisPosition = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 4000, 0] call BIS_fnc_findSafePos;
if ((count _ferrisPosition) == 2) then{ if ((count _ferrisPosition) == 2) then{
_item = createVehicle["ferrisWheel_EPOCH", _ferrisPosition, [], 0.0, "CAN_COLLIDE"]; _item = createVehicle["ferrisWheel_EPOCH", _ferrisPosition, [], 0.0, "CAN_COLLIDE"];

View File

@ -5,7 +5,9 @@
Improvements and or bugfixes and other contributions are welcome via the github: Improvements and or bugfixes and other contributions are welcome via the github:
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/ContainterSpawner.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/ContainterSpawner.sqf
*/ */
private ["_marker","_item","_cargoPosition"]; //[[[cog import generate_private_arrays ]]]
private ["_cargoPosition","_item","_marker"];
//[[[end]]]
_cargoPosition = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 4000, 1] call BIS_fnc_findSafePos; _cargoPosition = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 4000, 1] call BIS_fnc_findSafePos;
if ((count _cargoPosition) == 2) then{ if ((count _cargoPosition) == 2) then{
_item = createVehicle["Cargo_Container", _cargoPosition, [], 0.0, "CAN_COLLIDE"]; _item = createVehicle["Cargo_Container", _cargoPosition, [], 0.0, "CAN_COLLIDE"];

View File

@ -5,7 +5,9 @@
Improvements and or bugfixes and other contributions are welcome via the github: Improvements and or bugfixes and other contributions are welcome via the github:
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/Earthquake.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/Earthquake.sqf
*/ */
private ["_marker","_minerals","_randomIndex","_item","_playersNearEpicenter","_position","_chance"]; //[[[cog import generate_private_arrays ]]]
private ["_chance","_item","_marker","_minerals","_playersNearEpicenter","_position"];
//[[[end]]]
_position = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 1000, 0] call BIS_fnc_findSafePos; _position = [epoch_centerMarkerPosition, 0, EPOCH_dynamicVehicleArea, 10, 0, 1000, 0] call BIS_fnc_findSafePos;
if ((count _position) == 2) then{ if ((count _position) == 2) then{
_playersNearEpicenter = _position nearEntities[["Epoch_Male_F", "Epoch_Female_F"], 1000]; _playersNearEpicenter = _position nearEntities[["Epoch_Male_F", "Epoch_Female_F"], 1000];

View File

@ -10,5 +10,5 @@ _messages = [
*/ */
// Restart time // Restart time
_restartIn = round((EPOCH_forceRestartTime-diag_tickTime)/60); private _restartIn = round((EPOCH_forceRestartTime-diag_tickTime)/60);
["message", format["Welcome to Epoch Mod, server wlll restart in %1 minutes",_restartIn]] call EPOCH_serverCommand; ["message", format["Welcome to Epoch Mod, server wlll restart in %1 minutes",_restartIn]] call EPOCH_serverCommand;

View File

@ -14,7 +14,9 @@
Improvements and or bugfixes and other contributions are welcome via the github: Improvements and or bugfixes and other contributions are welcome via the github:
https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/PlantSpawner.sqf https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_server_settings/EpochEvents/PlantSpawner.sqf
*/ */
private ["_debug","_jammers","_restricted","_playersNearby","_plant","_position","_plantCount","_scatter","_marker","_nearbyLocations","_plants","_timeStamp","_decayTime","_showPlantMarkers"]; //[[[cog import generate_private_arrays ]]]
private ["_debug","_decayTime","_jammers","_marker","_nearbyLocations","_plant","_plantCount","_plants","_playersNearby","_position","_restricted","_scatter","_selectedLocation","_showPlantMarkers","_timeStamp"];
//[[[end]]]
// SET THIS TO TRUE TO GET MESSAGES IN LOG. // SET THIS TO TRUE TO GET MESSAGES IN LOG.
_debug = true; _debug = true;