Only need the PBO for this right?

This commit is contained in:
Ghostrider [GRG] 2023-09-27 23:12:13 -04:00
parent 6c359de5cd
commit 23d33c2df7
61 changed files with 0 additions and 1878 deletions

View File

@ -1 +0,0 @@
addons\3DENplugin

View File

@ -1,6 +0,0 @@
_object setVariable["gmsGarrisonColor",_colorOn];
if (_colorOn) then {
{_object setObjectTexture [_x,gms3DENlootVehicleTexture]} forEach (count (getObjectTextures _object));
};

View File

@ -1,4 +0,0 @@
private _m= format["About called at %1",diag_tickTime];
systemChat _m;
diag_log _m;

View File

@ -1,40 +0,0 @@
/*
Returns the builing containing an object or objNull
By Ghostrider-GRG-
Copyright 2020
*/
params["_u",["_category","House"]];
diag_log format["_fn_buildingContainer: typeOf _u = %1", typeOf _u];
private _pos = getPosASL _u;
private _building = objNull;
// lineIntersectsSurfaces [begPosASL, endPosASL, ignoreObj1, ignoreObj2, sortMode, maxResults, LOD1, LOD2, returnUnique]
/*
Wiki page: https://community.bistudio.com/wiki/lineIntersectsSurfaces
Return Value
Array of intersections in format [[intersectPosASL, surfaceNormal, intersectObj, parentObject, selectionNames, pathToBisurf], ...] where:
intersectPosASL: PositionASL - the actual position where line intersects surface
surfaceNormal: Vector - a normal to the intersected surface
intersectObject: Object - the object the surface belongs to (could be proxy object) - objNull if terrain
parentObject: Object - the object proxy object belongs to (not always the same as intersect object) - objNull if terrain
Arma 3 logo black.png
2.10
selectionNames: Array of Strings - Names of the intersected selections (bones). Returns [] if there is no intersection with a selection.
Arma 3 logo black.png
2.10
pathToBisurf: String - path to intersected surface properties (.bisurf) file. Returns "" if surface has no special properties. Terrain surface properties begin with #, and the surface properties are defined in CfgSurfaces. For example, if it returns #GdtVRsurface01, properties are defined in: configFile >> "CfgSurfaces" >> "GdtVRsurface01"
*/
private _surfacesAbove = lineInterSectsSurfaces [_pos, [_pos select 0, _pos select 1, (_pos select 2) + 100],_u,_u,true,10,"VIEW","FIRE",true];
private _surfacesBelow = lineIntersectsSurfaces [_pos, [_pos select 0, _pos select 1, (_pos select 2) - 100],_u,_u,true,10,"VIEW","FIRE",true];
diag_log format["fn_buildingContainer: _surfacesAbove = %1", _surfacesAbove];
diag_log format["fn_buildingContainer: _surfacesBelow = %1", _surfacesBelow];
private _buildingAbove = if !(_surfacesAbove isEqualTo []) then {_surfacesAbove select 0 select 2} else {objNull};
private _buildingBelow = if !(_surfacesBelow isEqualTo []) then {_surfacesBelow select 0 select 2} else {objNull};
diag_log format["fn_buildingContainer: _buildingAbove = %1",_buildingAbove];
diag_log format["fn_buildingContainer: _buildingBelow = %1",_buildingBelow];
if (!(isNull _buildingAbove) && _buildingAbove isKindOf "Building") then {_building = _buildingAbove} else {if (!(isNull _buildingBelow) && _buildingBelow isKindOf "Building") then {_building = _buildingBelow}};
diag_log format["fn_buldingContainer: _building = %1",_building];
_building

View File

@ -1,87 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params[
"_building", // An object to be evaluated as a possible location of a garrison
"_turrets", // A list of turrets known to be inside something
"_groups"]; // A list of groups that are known to be inside something
diag_log format["configureGarrisonATL Line 10: _this = %1",_this];
diag_log format["configureGarrisonATL Line 11: _building = %1",_building];
diag_log format["configureGarrisonATL Line 12: _center = %1",_center];
diag_log format["configureGarrisonATL Line 13: _turrets = %1",_turrets];
diag_log format["configureGarrisonATL Line 14: count _groups = %1 | _groups = %2",count _groups, _groups];
private _pos = _building get3DENAttribute "position";
private _count = 0;
private _staticsText = [];
private _unitsText = [];
private _buildingGarrisonATL = [];
private _configuredStatics = [];
private _configuredUnits = [];
private _lineBreak = toString [10];
for "_i" from 1 to (count _turrets) do
{
if (_turrets isEqualTo []) exitWith {};
private _tur = _turrets deleteAt 0;
//_configuredStatics pushBackUnique _tur;
private _pos = getPosATL _tur;
private _dir = getDir _tur;
private _center = getPosATL _container;
private _offset = _center vectorDiff _pos;
diag_log format["fn_configureGarisonATL Line 39: getPosATL _tur = %1 | getPosATL _container = %2",_pos,_center];
_staticsText pushBack [format['%1',typeOf _tur],_offset,_dir];
diag_log format["fn_configureGarisonATL Line 41: updated _staticsText to %1",_staticsText];
};
_staticsText joinString _lineBreak;
for "_i" from 1 to (count _groups) do
{
if (_groups isEqualTo []) exitWith {};
private _grp = _groups deleteAt 0;
private _inside = false;
// assume there is a group of 1 and that the leader of the group is in the position to be guarded
private _unit = leader _group;
//_configuredUnits pushBackUnique _unit;
private _pos = getPosATL _unit;
private _center = getPosATL _container;
private _offset = _pos vectorDiff _center;
private _dir = getDir _unit;
_unitsText pushBack [_offset,_dir];
diag_log format["configureGarrisonATL Line 50: added unit %1 to garison for building %2",_unit,_container];
diag_log format["configureGarrisonATL Line 53: updated _unitsText to %1",_unitsText];
};
_unitsText joinString _lineBreak;
if !((_staticsText isEqualTo []) && (_unitsText isEqualTo [])) then
{
private _allowDamage = (_building get3DENAttribute "allowDamage") select 0;
private _enableSimulation = (_building get3DENAttribute "enableSimulation") select 0;
diag_log format["configureGarrisonATL: _building %1 | damage %2 | simulation %3",_allowDamage,_enableSimulation];
_buildingGarrisonATL = [
format["%1",
typeOf _building],
(getPosATL _building) vectorDiff _center,
getDir _building,
_allowDamage,
_enableSimulation,
_staticsText,
_unitsText
];
};
private "_return";
if (_buildingGarrisonATL isEqualTo []) then
{
_return = [];
} else {
_return = [_buildingGarrisonATL,_configuredStatics,_configuredUnits];
};
_return

View File

@ -1,13 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_message"];
// As found in fn_3DENExportTerrainBuilder.sqf
//private _message = ["this is ","an array"];
private _lineBreak = toString [10];
uiNameSpace setVariable ["Display3DENCopy_data", ["missionName.sqf", _message joinString _lineBreak]];
(findDisplay 313) createdisplay "Display3DENCopy";

View File

@ -1,30 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_state"];
all3DENEntities params ["_objects"];
_objects = _objects select {_x getVariable["garrisoned",false]};
missionNameSpace setVariable["blck_displayGarrisonMarkerOn",_state];
{
if (_state) then // if the request was to show the markers then ....
{
private _marker = _x getVariable["marker",""];
diag_log format["_x = %1 | _marker = %2",_x,_marker];
if (_marker isEqualto "") then
{
[_x] call gms3DEN_fnc_createGarrisonMarker;
[_x] call gms3DEN_fnc_setEventHandlers;
};
} else {
blck_displayGarrisonMarkerOn = false;
if !(_x getVariable["marker",""] isEqualTo "") then
{
[_x] call gms3DEN_fnc_removeMarker;
};
};
} forEach _objects;

View File

@ -1,27 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_state"];
all3DENEntities params ["_objects"];
_objects = _objects select {_x getVariable ["lootVehicle",false]};
missionNamespace setVariable["blck_displayLootMarkerOn",_state];
{
if (_state) then // if the request was to show the markers then ....
{
if (_x getVariable["marker",""] isEqualto "") then
{
[_x] call gms3DEN_fnc_createLootMarker;
[_x] call gms3DEN_fnc_setEventHandlers;
};
} else {
if !(_x getVariable["marker",""] isEqualTo "") then
{
[_x] call gms3DEN_fnc_removeMarker;
};
};
} forEach _objects;

View File

@ -1,10 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_end"];
missionNamespace setVariable["blck_endMessage",_end];
systemChat format["End Message set to %1",_end];

View File

@ -1,417 +0,0 @@
/*
GMS 3DEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
private _m = "Staring exportDynamic.sqf";
systemChat _m;
diag_log _m;
Mission_CENTER = [0,0,0];
GMS_objectAtMissionCenter = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "objectAtMissionCenter");
if (isNil "GMS_minAI") then {GMS_minAI = getNumber(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "minAI")};
if (isNil "GMS_maxAI") then {GMS_maxAI = getNumber(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "maxAI")};
/*
Set Default Values Where not Defined using Menu Commands
*/
if (isNil "GMS_missionLocations") then
{
GMS_missionLocations = "random";
};
if (isNil "GMS_difficulty") then
{
GMS_difficulty = "Red";
} else {
if (GMS_difficulty in [1,2,3,4]) then
{
GMS_difficulty = ["Blue","Red","Green","Orange"] select GMS_difficulty;
};
if (GMS_difficulty isEqualTo "") then {
GMS_difficulty isEqualTo "Red";
};
};
if (isNil "GMS_dynamicStartMessage") then
{
GMS_dynamicStartMessage = "TODO: Change approiately";
};
if (isNil "GMS_dynamicEndMessage") then
{
GMS_dynamicEndMessage = "TODO: Change Appropriately";
};
if (isNil "GMS_dynamicCrateLoot") then
{
GMS_dynamicCrateLoot = format["_crateLoot = blck_BoxLoot_%1;",GMS_difficulty];
};
if (isNil "GMS_dynamicCrateLootCounts") then {
GMS_dynamicCrateLootCounts = format["_lootCounts = bGMS_lootCounts%1;",GMS_difficulty];
};
if (isNil "GMS_dynamicmarkerMissionNamet") then
{
GMS_dynamicmarkerMissionName = "TODO: Update appropriately";
};
if (isNil "GMS_spawnCratesTiming") then
{
GMS_spawnCratesTiming = "atMissionStartGround";
};
if (isNil "GMS_loadCratesTiming") then
{
GMS_loadCratesTiming = "atMissionStart";
};
if (isNil "GMS_missionEndCondition") then
{
GMS_missionEndCondition = "allUnitsKilled";
};
if (isNil "gms_chancemissionspawned") then
{
gms_chancemissionspawned = 1.0;
};
switch (GMS_missionEndCondition) do
{
case "GMS_playerNear": {GMS_missionEndCondition = playerNear};
case "GMS_allUnitsKilled": {GMS_missionEndCondition = allUnitsKilled};
case "GMS_allKilledOrPlayerNear": {GMS_missionEndCondition = allKilledOrPlayerNear};
case "GMS_assetSecured": {GMS_missionEndCondition = assetSecured};
};
/*
Look for an object defined in Cfggms3DEN \ configs \ that marks the center of the mission
and set the coords of the center if such an object is found
*/
all3DENEntities params ["_objects","_groups","_triggers","_systems","_waypoints","_markers","_layers","_comments"];
// Relax what is an object at mission center somehow?
// Maybe using inheritsFrom?
diag_log format["exportDynamic line 90: GMS_objectAtMissionCenter = %1",GMS_objectAtMissionCenter];
private _centerMarkerObject = objNull;
{
diag_log format["exportDynamic: evaluating objects for one that is to set mission center where the object is of typeOf %1", typeOf _x];
if ((typeOf _x) isEqualTo GMS_objectAtMissionCenter) exitwith
{
_centerMarkerObject = _x;
diag_log format["exportDynamic Line 97: _x = %1 | _centerMarkerObject = %2", _x, _centerMarkerObject];
};
} forEach _objects;
diag_log format["Line 100: _centerMarkerObject = %1 | GMS_objectAtMissionCenter = %2",_centerMarkerObject, GMS_objectAtMissionCenter];
if !(isNull _centerMarkerObject) then
{
private _objPos = (_centerMarkerObject get3DENAttribute "position") select 0;
private _objType = typeOf _centerMarkerObject;
Mission_CENTER = _objPos;
diag_log format["CENTER defined by object %1 typeOf %2 located at %3",_centerMarkerObject,_objType,_objPos];
} else {
diag_log format["<WARNING> No object marking the center of the mission was found: using an object defined in 'objectAtMissionCenter' is recommended",getText(configFile >> "CfgVehicles" >> objectAtMissionCenter >> "displayName")];
diag_log format["Place such an object or a marker to ensure the mission is accurately stored and spawned"];
};
private["_m1","_markerPos","_markerType","_markerShape","_markerColor","_markerText","_markerBrush","_markerSize","_markerAlpha","_markerLabel"];
/*
pull info on the first marker found
If Mission_CENTER was not set above then try to set it based on the first marker identified.
*/
private _markerLabel = "";
private _centerSet = false;
if !(_markers isEqualTo []) then
{
private _m1 = _markers select 0;
_markerPosition = (_m1 get3DENAttribute "Position") select 0; // Returns expected value
_markerText = (_m1 get3DENAttribute "Text") select 0; // Returns expected value
_markerColor = (_m1 get3DENAttribute "baseColor") select 0; //Returns Null
_markerShape = ((_m1 get3DENAttribute "markerType") select 0); // Returns [-1] if not a rectangular or elipsoid marker]
_markerAlpha = _m1 get3DENAttribute "alpha";
_markerType = (_m1 get3DENAttribute "itemClass") select 0; // Returns "" if not an icon type marker
_markerBrush = (_m1 get3DENAttribute "brush") select 0;
_markerSize = (_m1 get3DENAttribute "size2") select 0;
_markerRotation = (_m1 get3DENAttribute "rotation") select 0;
diag_log format["Line 140: _markerShape = %1 | _markerType = %2 _m1 get3DENAttribute markerType = %3",_markerShape,_markerType, _m1 get3DENAttribute "markerType"];
switch (_markerShape) do
{
case -1: {};
case 0:{_markerType = "RECTANGLE"};
case 1: {_markerType = "ELLIPSE"};
};
/*
use the coordinates of that marker as mission center of no object demarkating the center is found
*/
if (Mission_CENTER isEqualTo [0,0,0]) then {
Mission_CENTER = _markerPosition;
diag_log format["Position of marker %1 used for position of CENTER = %2",_m,Mission_CENTER];
};
if (count _markers > 1) then
{
diag_log format["<WARNING> More than one marker was found; only the first marker was processed"];
};
};
if (Mission_CENTER isEqualTo [0,0,0]) then {
Mission_CENTER = position (_objects select 0);
diag_log format["<WARNING> Mission Center set to the position of the first object"];
};
if (_markers isEqualTo []) then
{
_markerPosition = Mission_CENTER;
_markerText = "";
_markerColor = "";
_markerShape = "ELLIPSE";
_markerAlpha = 1.0;
_markerType = _markerShape;
_markerBrush = "GRID";
_markerSize = [150,150];
_markerRotation = 0;
};
private _markerMissionName = "TODO: Set this to an appropriate name";
private _m = format["Line 152: Mission_CENTER = %1",Mission_CENTER];
private _props = _objects select {!(_x isKindOf "ReammoBox_F") && (_x isKindOf "FloatingStructure_F" || _x isKindOf "Items_base_F" || _x isKindOf "Thing" || _x isKindOf "Static")};
GMS_staticWeapons = [];
GMS_objectsToSpawn = [];
GMS_missionSimpleObjects = [];
GMS_garrisonedBuildings = [];
GMS_unitsATL = [];
GMS_scubaGroups = [];
GMS_infantryGroups = [];
GMS_missionPatrolVehicles = [];
GMS_lootVehicles = [];
GMS_subPatrols = [];
GMS_ugvs = [];
GMS_uavs = [];
/* Turrets First */
private _allTurrets = _objects select {_x isKindOf "StaticWeapon"};
{
GMS_staticWeapons pushBack format[" %1, %2, %3, %4",typeOf _x, (getPosATL _x) vectorDiff Mission_CENTER, getDir _x, GMS_difficulty];
} forEach _allTurrets;
private _vehicles = _objects select {_x isKindOf "Car" || _x isKindOf "Tank" || _x isKindOf "Ship"};
{
private _obj = _x;
private _vehicleClass = getText(configFile >> "CfgVehicles" >> typeOf _obj >> "vehicleclass");
private _isLoot = _obj getVariable["gmsIsLootVehicle",false];
if (_isLoot) then
{
GMS_lootVehicles pushBack format[' ["%1",%2,%3,%4,%5]',typeOf _obj,(getPosATL _obj) vectorDiff CENTER, '_crateLoot','_lootCounts',getDir _obj];
} else {
if (_obj isKindOf "SDV_01_base_F") then {
GMS_subPatrols pushBack format[' ["%1",%2,%3]',typeOf _x,(getPosATL _x) vectorDiff Mission_CENTER,getDir _x];
} else {
if (_vehicleClass isEqualTo "Autonomous") then
{
GMS_ugvs pushBack format[' ["%1",%2,%3]',typeOf _x,(getPosATL _x) vectorDiff Mission_CENTER,getDir _x];
} else {
GMS_missionPatrolVehicles pushBack format[' ["%1",%2,%3]',typeOf _obj,(getPosATL _obj) vectorDiff Mission_CENTER,getDir _obj];
};
};
};
} forEach _vehicles;
private _aircraft = _objects select {_x isKindOf "Air"};
// Run through objects and format any for output
GMS_airPatrols = [];
{
//_objects = _objects deleteAt (_objects find _x);
private _obj = _x;
private _vehicleClass = getText(configFile >> "CfgVehicles" >> typeOf _obj >> "vehicleclass");
if (_vehicleClass isEqualTo "Autonomous") then {
GMS_uavs pushBack format[' ["%1",%2,%3]',typeOf _obj,(getPosATL _obj) vectorDiff Mission_CENTER,getDir _obj];
} else {
GMS_airPatrols pushBack format[' ["%1",%2,%3]',typeOf _obj,(getPosATL _obj) vectorDiff Mission_CENTER,getDir _obj];
};
} forEach _aircraft;
private _lootBoxes = _objects select {_x isKindOf "ReammoBox_F"};
// Run through objects and put any Ammo Crates in a separate array
GMS_lootContainers = [];
{
//_objects = _objects deleteAt (_objects find _x);
private _obj = _x;
GMS_lootContainers pushBack format[' ["%1",%2,%3,%4,%5]',typeOf _obj,(getPosATL _obj) vectorDiff Mission_CENTER, '_crateLoot','_lootCounts',getDir _obj];
} forEach _lootBoxes;
private _props = _objects select {(_x isKindOf "FloatingStructure_F" || _x isKindOf "Items_base_F" || _x isKindOf "Thing" || _x isKindOf "Static")};
{
private _obj = _x;
if (_obj get3DENAttribute "objectIsSimple" select 0) then {
diag_log format["Line 209: adding simpleObject displayName %1",getText(configFile >> "CfgVehicles" >> typeOf _obj >> "displayName")];
GMS_missionSimpleObjects pushBack format[' ["%1",%2,%3]',
(_obj get3DENAttribute "ItemClass") select 0,
((_obj get3DENAttribute "position") select 0) vectorDiff Mission_CENTER,
((_obj get3DENAttribute "rotation") select 0) select 2
];
} else {
private _allowDamage = (_obj get3DENAttribute "allowDamage") select 0;
private _enableSimulation = (_obj get3DENAttribute "enableSimulation") select 0;
GMS_objectsToSpawn pushBack format[' ["%1",%2,%3,[%4,%5]]',
typeOf _obj,
(getPosATL _obj) vectorDiff Mission_CENTER,
getDir _obj,
_allowDamage,
_enableSimulation
];
};
} forEach _props;
private _men = [];
private _menInside = [];
{
private _group = _x;
private _units = units _group;
{
private _unit = _x;
private _onFoot = if (vehicle _unit isEqualTo _unit) then {true} else {false};
private _isGarrisoned = _unit call gms3DEN_fnc_isInside;
private _isSurfaceWater = surfaceIsWater (getPosATL _unit);
if (_onFoot) then
{
if (_isGarrisoned) then
{
GMS_unitsATL pushBack format[' [%1,%2,%3,"%4"]',(getPosATL _unit) vectorDiff Mission_CENTER, getDir _unit, GMS_difficulty];
} else {
if (_isSurfaceWater) then {
GMS_scubaGroups pushBack format[' [%1,%2,%3,"%4"]',(getPosATL _unit) vectorDiff Mission_CENTER,GMS_minAI,GMS_maxAI,GMS_difficulty];
} else {
GMS_infantryGroups pushBack format[' [%1,%2,%3,"%4"]',(getPosATL _unit) vectorDiff Mission_CENTER,GMS_minAI,GMS_maxAI,GMS_difficulty];
};
};
};
} forEach _units;
} forEach _groups;
private _lines = [];
private _lineBreak = toString [10];
_lines pushBack "/*";
_lines pushBack format[" %1 Mission Generated",GMS_missionSpawnMode];
_lines pushBack " Using 3DEN Plugin for GMS by Ghostrider";
_lines pushBack format[" %1",['dynamic'] call gms3DEN_fnc_versionInfo];
_lines pushBack " By Ghostrider-GRG-";
_lines pushBack "*/";
_lines pushBack "";
GMS_defaultMissionLocations = [];
if (GMS_missionSpawnMode isEqualTo "Static") then {GMS_defaultMissionLocations = Mission_CENTER};
_lines pushBack '#include "\GMS\Compiles\Init\GMS_defines.hpp"';
_lines pushBack '#include "\GMS\Missions\GMS_privateVars.sqf" ';
_lines pushBack "";
_lines pushBack format['_difficulty = "%1";',GMS_difficulty];
_lines pushBack format["_chanceMissionSpawned = %1;",GMS_chanceMissionSpawned];
_lines pushBack format["_defaultMissionLocations = %1;",GMS_defaultMissionLocations];
_lines pushBack "_maxMissionRespawns = -1;";
_lines pushBack format['_startMsg = "%1";',GMS_dynamicStartMessage];
_lines pushBack format['_endMsg = "%1";',GMS_dynamicEndMessage];
_lines pushBack format['_markerLabel = "%1";',_markerLabel];
_lines pushBack format['_markerColor = "%1";',_markerColor];
_lines pushBack format['_markerText = "%1";',_markerText];
_lines pushBack format['_markerMissionName = "%1";',_markerMissionName];
_lines pushBack format['_crateLoot = GMS_BoxLoot_%1;',GMS_difficulty];
_lines pushBack format['_lootCounts = GMS_lootCounts%1;',GMS_difficulty];
_lines pushBack "";
_lines pushBack "/*";
_lines pushBack " Depricated Variable Included for Backwards Compatibility with Existing Missions";
_lines pushBack "*/";
_lines pushBack "_garrisonedBuilding_ATLsystem = [";
_lines pushBack "";
_lines pushBack "];";
_lines pushBack "/*";
_lines pushBack " Depricated Variable Included for Backwards Compatibility with Existing Missions";
_lines pushBack "*/";
_lines pushBack "_garrisonedBuildings_BuildingPosnSystem = [";
_lines pushBack "";
_lines pushBack "];";
_lines pushBack "_missionLandscape = [";
_lines pushback (GMS_objectsToSpawn joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_simpleObjects = [";
_lines pushback (GMS_missionSimpleObjects joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionLootVehicles = [";
_lines pushBack (GMS_lootVehicles joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionPatrolVehicles = [";
_lines pushback (GMS_missionPatrolVehicles joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionUGVs = [";
_lines pushBack (GMS_ugvs joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "_submarinePatrolParameters = [";
_lines pushback (GMS_subPatrols joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_airPatrols = [";
_lines pushback (GMS_airPatrols joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionUAVs = [";
_lines pushBack (GMS_uavs joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "_missionEmplacedWeapons = [";
_lines pushback (GMS_staticWeapons joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionGroups = [";
_lines pushback (GMS_infantryGroups joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionGarrisonedGroups = [";
_lines pushBack (GMS_unitsATL joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_scubaGroupParameters = [";
_lines pushback (GMS_scubaGroups joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "_missionLootBoxes = [";
_lines pushback (GMS_lootContainers joinString (format [",%1", _lineBreak]));
_lines pushBack "];";
_lines pushBack "";
_lines pushBack "/*";
_lines pushBack " Use the parameters below to customize your mission - see the template or GMS_configs.sqf for details about each them";
_lines pushBack "*/";
_lines pushBack format["_chanceHeliPatrol = GMS_chanceHeliPatrol%1;",GMS_difficulty];
_lines pushBack format["_noChoppers = GMS_noPatrolHelis%1;",GMS_difficulty];
_lines pushBack format["_missionHelis = GMS_patrolHelis%1;",GMS_difficulty];
_lines pushBack format["_chancePara = GMS_chancePara%1;",GMS_difficulty];
_lines pushBack format["_noPara = GMS_noPara%1;",GMS_difficulty];
_lines pushBack format["_paraTriggerDistance = 400;"];
_lines pushBack format["_paraSkill = '%1';",0.7];
_lines pushBack format["_chanceLoot = 0.0;"];
_lines pushBack format["_paraLoot = GMS_BoxLoot_%1;",GMS_difficulty];
_lines pushBack format["_paraLootCounts = GMS_lootCounts%1;",GMS_difficulty];
_lines pushBack format['_missionLandscapeMode = "precise";'];
_lines pushBack "_useMines = GMS_useMines;";
_lines pushBack "_uniforms = GMS_SkinList;";
_lines pushBack "_headgear = GMS_headgear;";
_lines pushBack "_vests = GMS_vests;";
_lines pushBack "_backpacks = GMS_backpacks;";
_lines pushBack "_sideArms = GMS_Pistols;";
_lines pushBack format['_spawnCratesTiming = "%1;"',GMS_spawnCratesTiming];
_lines pushBack format['_loadCratesTiming = "%1;"',GMS_loadCratesTiming];
_lines pushBack format['_endCondition = %1;', GMS_missionEndCondition];
_lines pushBack format["_minNoAI = GMS_MinAI_%1;",GMS_difficulty];
_lines pushBack format["_maxNoAI = GMS_MaxAI_%1;",GMS_difficulty];
_lines pushBack format["_noAIGroups = GMS_AIGrps_%1;",GMS_difficulty];
_lines pushBack format["_noVehiclePatrols = GMS_SpawnVeh_%1;",GMS_difficulty];
_lines pushBack format["_noEmplacedWeapons = GMS_SpawnEmplaced_%1;",GMS_difficulty];
_lines pushBack "_submarinePatrols = 0;";
_lines pushBack "_scubaPatrols = 0;";
_lines pushBack "";
_lines pushBack '#include "\GMS\Compiles\Missions\GMS_fnc_missionSpawner.sqf";';
uiNameSpace setVariable ["Display3DENCopy_data", ["dynamicMission.sqf", _lines joinString _lineBreak]];
(findDisplay 313) createdisplay "Display3DENCopy";
_m = "Exported Mission copied to clipboard";
systemChat _m;
diag_log _m;

View File

@ -1,3 +0,0 @@
params["_entity","_value","_property"];
diag_log format["garrisonApplyChanges: _entity %1 | _value %2 | _property %3",_entity,_value,_property];

View File

@ -1,31 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
private _objects = get3DENSelected "object" select {(typeOf _x) isKindOf "Car" || (typeOf _x) isKindOf "Ship" || (typeOf _x) isKindOf "ThingX"};
private "_message";
if (_objects isEqualTo []) then
{
_message = "No Cars/Ships/ThingX Selected";
} else {
if (count _objects == 1) then
{
if ((_objects select 0) getVariable["lootvehicle",false]) then
{
_message = format["Vehicle %1 IS a Loot Vehicle",typeOf (_objects select 0)];
} else {
_message = format["Vehicle %1 is NOT a Loot Vehicle",typeOf (_objects select 0)];
};
} else {
_message = format["% Vehicles Selected. Select a single vehicle then try again",count _objects];
};
};
systemChat _message;
diag_log _message;
[_message,"Status"] call BIS_fnc_3DENShowMessage;

View File

@ -1,11 +0,0 @@
private _objects = get3DENSelected "object" select {((typeOf _x) isKindOf "House") && [_x] call BIS_fnc_isBuildingEnterable};
private _lines = [];
private _lineBreak = toString [10];
{
_message pushBack format["Garrison Flag for Building type %1 at %2 = %3",typeOf _x,getPosATL _x,_x getVariable["garrisoned",false]];
} forEach _objects;
uiNameSpace setVariable ["Display3DENCopy_data", ["garrisonedBuildings.sqf", _lines joinString _lineBreak]];
(findDisplay 313) createdisplay "Display3DENCopy";

View File

@ -1,11 +0,0 @@
private _objects = get3DENSelected "object" select {(typeOf _x) isKindOf "Car"};
private _lines = [];
private _lineBreak = toString [10];
{
_message pushBack format["Loot Vehicle Flag for Vehicle type %1 at %2 = %3",typeOf _x,getPosATL _x,_x getVariable["garrisoned",false]];
} forEach _objects;
uiNameSpace setVariable ["Display3DENCopy_data", ["lootVehicles.sqf", _lines joinString _lineBreak]];
(findDisplay 313) createdisplay "Display3DENCopy";

View File

@ -1,9 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
private _m = format["Help called at %1",diag_tickTime];
systemChat _m;
diag_log _m;

View File

@ -1,5 +0,0 @@
diag_log format["fn_initialize loaded at %1",diag_tickTime];
call gms3DEN_fnc_initializeAttributes;
diag_log call gms3DEN_fnc_versioninfo;

View File

@ -1,28 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
diag_log format["Initializing GMS_RC 3DEN Plugin %1",call gms3DEN_fnc_versionInfo];
GMS_difficulty = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "defaultMissionDifficulty");
diag_log format["configs returned defaultMissionDifficulty = %1",GMS_difficulty];
GMS_chanceMissionSpawned = 1.0;
diag_log format["GMS_chanceMissionSpawned set to default setting of 100%"];
GMS_lootcrateSpawnTiming = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "defaultLootcrateSpawnTiming");
diag_log format["configs returned defaultLootcrateSpawnTiming = %1",GMS_lootcrateSpawnTiming];
GMS_lootcrateLoadTiming = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "defaultLootcrateLoadTiming");
diag_log format["configs returned defaultLootcrateLoadTiming = %1",GMS_lootcrateLoadTiming];
GMS_missionEndState = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "defaultMissionEndState");
diag_log format["configs returned defaultMissionEndState = %1",GMS_missionEndState];
GMS_startMessage = "TODO: Add a start message";
GMS_endMessage = "TODO: Add an end message";
GMS_missionLocations = "random";
gms3DENGarrisonTexture = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "colorGarrisonObject");
diag_log format["configs returned %1 as the color for garrisoned objects",gms3DENGarrisonTexture];
gms3DENlootVehicleTexture = getText(configFile >> "CfgGMS3DEN" >> "CfgDefaults" >> "colorLootObject");
diag_log format["configs returned %1 as the color for loot objects such as vehicles",gms3DENlootVehicleTexture];
gms3DEN_useGarrisonATL = false;
diag_log format["gms3DEN_useGarrisonATL set to default value of %1",gms3DEN_useGarrisonATL];
GMS_missionSpawnMode = "Dynamic";
diag_log format["Mission Attributes Initialized for GMS at time %1",diag_tickTime];

View File

@ -1,6 +0,0 @@
params["_unit"];
private _vehicle = vehicle _unit;
private _isInVehicle = if (_unit isEqualTo _vehicle) then {true} else {false};
_isInVehicle

View File

@ -1,17 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
private _group = _this select 0;
private _units = units _group;
private _isInfantry = true;
{
private _isInside = [_u] call gms3DEN_fnc_isInside;
_isInfantry = if ((_u isKindOf "Man") && (vehicle _u) isEqualTo _u && !(_isInside)) then {true} else {false};
if !(_isInfantry) exitWith {};
} forEach _units;
_isInfantry

View File

@ -1,14 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
private _u = _this select 0;
private _isInside = [_u] call gms3DEN_fnc_isInside;
private _isInVehicle = [_u] call gms3DEN_fnc_isInVehicle;
private _isInfantry = if (_isInside || _isInVehicle) then {false} else {true};
_isInfantry

View File

@ -1,18 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_u"];
private _pos = getPosASL _u;
private _above = AGLToASL [_pos select 0, _pos select 1, (_pos select 2) + 100];
private _below = AGLtoASL [_pos select 0, _pos select 1, (_pos select 2) - 10];
private _objAbove = lineIntersects [_pos, _above, _u,_u];
private _objBelow = lineIntersects [_pos, _below, _u,_u];
private _isInside = if (_objAbove || _objBelow) then {true} else {false};
_isInside

View File

@ -1,4 +0,0 @@
params["_control","_value","_config"];
diag_log format["_onAttributeLoadGarrisons: _control = %1 | _value = %2 | _config %3",_control,_value,_config];

View File

@ -1,4 +0,0 @@
params["_control","_value"];
diag_log format["_onAttributeLoadGarrisonsColor: _control = %1 | _value = %2",_control,_value];

View File

@ -1,4 +0,0 @@
params["_cbChecked"];
diag_log format["_onLoadAttributeLoadLootVeh: _cbChecked = %1 ",_cbChecked];

View File

@ -1,4 +0,0 @@
params["_control","_value"];
diag_log format["_onLoadAttributeLoadLootVehColor: _control = %1 | _value = %2",_control,_value];

View File

@ -1,10 +0,0 @@
params["_control"];
private _isGarrison;
private _selectedObjects = get3DENSelected "object";
diag_log format["onAttributeSaveGarrison: _isGarrison %1 | _selectedObjects %2",_control,_selectedObjects];
if (count _selecteObjects == 1) then {
private _object = _selectedObjects select 0;
//private _isGarrison = _object getVariable["gmsIsGarrison",false];
//_object setVariable["gmsIsGarrison",_isGarrison];
};

View File

@ -1,15 +0,0 @@
params["_control"];
private _isColorOn = ctrlChecked _control;
private _selectedObjects = get3DENSelected "object";
diag_log format["onAttributeSaveGarrisonColor: _control %1 | _isGarrison %2 | _selectedObjects %3",_control,_isColorOn,_selectedObjects];
if (count _selecteObjects == 1) then {
private _object = _selectedObjects select 0;
private _isGarrison = _object getVariable["gmsIsGarrison",false];
_object setVariable["gmsGarrisonColor",_isColorOn];
if (_isColor && _isGarrison) then {
{_object setObjectTexture [_x,gms3DENGarrisonTexture]} forEach (count (getObjectTextures _object));
} else {
{_object setObjectTexture [_x,""]} forEach (count (getObjectTextures _object));
};
};

View File

@ -1,4 +0,0 @@
params["_cbChecked"];
diag_log format["_onLoadAttributeLoadLootVeh: _cbChecked = %1 ",_cbChecked];

View File

@ -1,13 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object"];
if !(_object getVariable["marker",""] isEqualTo "") then
{
private _marker = _object getVariable["marker",""];
private _markerPos = getPosATL _object;
_marker setPosATL[_markerPos select 0, _markerPos select 1, (_markerPos select 2) + sizeOf _object];
};

View File

@ -1,33 +0,0 @@
/*
params ["_displayOrControl", ["_config", configNull]];
The order of initialisation is as follows:
Topmost config class (control class)
Last config class
Display
This means that during the onLoad event of the upper controls the lower controls do not exist!
*/
params ["_displayOrControl", ["_config", configNull]];
private _selectedObjects = get3DENSelected "object";
diag_log format["onLoadGarrison: _selectedObjects = %1",_selectedObjects];
diag_log format["onLoadGarrison: _displayControl = %1 | _config = %2",_displayOrControl,_config];
private "_isGarrison";
if (count _selectedObjects == 1) then {
private _object = (_selectedObjects select 0);
_isGarrison = _object getVariable["gmsIsGarrison",true];
_displayOrControl cbSetChecked _isGarrison;
diag_log format["_isGarrisson = %1 | _obj = %2",_isGarrison,_object];
} else {
_displayOrControl cbSetChecked false;
["You can configure Garrison Status for only ONE vehicle at a time","ERROR"] call BIS_fnc_3DENShowMessage;
};

View File

@ -1,16 +0,0 @@
params ["_displayOrControl", ["_config", configNull]];
private _selectedObjects = get3DENSelected "object";
diag_log format["onLoadGarrisonColor: _selectedObjects = %1",_selectedObjects];
private "_colorOn";
if (count _selectedObjects == 1) then {
private _object = (_selectedObjects select 0);
_colorOn = _object getVariable["gmsGarrisonColor",false];
_displayOrControl cbSetChecked _colorOn;
diag_log format["_colorOn = %1 | _obj = %2",_colorOn,_object];
} else {
_displayOrControl cbSetChecked false;
["You can configure Garrison Status for only ONE vehicle at a time","ERROR"] call BIS_fnc_3DENShowMessage;
};

View File

@ -1,8 +0,0 @@
params ["_displayOrControl", ["_config", configNull]];
private _selectedObjects = get3DENSelected "object";
if !(count _objects > 1) then {
["You can configure Loot Vehicle Status for only ONE vehicle at a time","ERROR"] call BIS_fnc_3DENShowMessage;
};

View File

@ -1,8 +0,0 @@
params ["_displayOrControl", ["_config", configNull]];
private _selectedObjects = get3DENSelected "object";
if !(count _objects > 1) then {
["You can configure Loot Vehicle Status for only ONE vehicle at a time","ERROR"] call BIS_fnc_3DENShowMessage;
};

View File

@ -1,28 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object"];
switch (true) do
{
case ((typeOf _object) isKindOf "ThingX" && blck_displayLootMarkerOn): {
if !(_object getVariable["lootVehicle",""] isEqualTo "") then
{
[_object] call gms3DEN_fnc_createLootMarker;
[_object] call gms3DEN_fnc_setEventHandlers;
};
};
case ((typeOf _object) isKindOf "House" && blck_displayGarrisonMarkerOn): {
if !(_object getVariable["garrisoned",""] isEqualTo "") then
{
[_object] call gms3DEN_fnc_createGarrisonMarker;
[_object] call gms3DEN_fnc_setEventHandlers;
};
};
};

View File

@ -1,12 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object"];
if !(_object getvariable["marker",""] isEqualTo "") then
{
[_object] call gms3DEN_fnc_removeMarker;
_object setVariable ["marker",nil];
};

View File

@ -1,18 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object"];
private _marker = _object getVariable["marker",""];
if !(_marker isEqualTo "") then
{
private _id = get3DENEntityID _marker;
delete3DENEntities [_id];
_object setVariable["marker",nil];
};
true

View File

@ -1,12 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
params["_mode"];
missionNameSpace setVariable["GMS_missionEndCondition",_mode];
private _m = format["Mission End State updated to %1",GMS_missionEndCondition];
systemChat _m;
diag_log _m;

View File

@ -1,13 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
params["_difficulty"];
GMS_difficulty = _difficulty;
private _m = format["Mission Difficulty updated to %1",GMS_difficulty];
systemChat _m;
diag_log _m;

View File

@ -1,14 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object"];
_object removeAllEventHandlers "UnregisteredFromWorld3DEN";
_object removeAllEventHandlers "RegisteredToWorld3DEN";
_object removeAllEventHandlers "Dragged3DEN";
_object addEventHandler ["Dragged3DEN",{_this call gms3DEN_fnc_onDrag;}];
_object addEventHandler ["UnregisteredFromWorld3DEN",{_this call gms3DEN_fnc_onUnregister;}];
_object addEventHandler ["RegisteredToWorld3DEN", {_this call gms3DEN_fnc_onRegistered;}];

View File

@ -1,11 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_object","_state"];
_object setVariable["Garrisoned",_state];
[format["Object Garrison State set to %1",_state], 0] call BIS_fnc_3DENNotification;

View File

@ -1,12 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
params["_timing"];
missionNamespace setVariable["GMS_loadCratesTiming", _timing];
private _m = format["Mission Load Crates Timing set to %1",GMS_loadCratesTiming];
systemChat _m;
diag_log _m;

View File

@ -1,15 +0,0 @@
params["_checked"];
private _selectedObjects = get3DENSelected "object";
diag_log format["onAttributeSaveLootVehColor: _control %1 | _isGarrison %2 | _selectedObjects %3",_control,_isColorOn,_selectedObjects];
if (count _selecteObjects == 1) then {
private _object = _selectedObjects select 0;
private _isLootVeh = _object getVariable["gmsIsLootVehicle",false];
_object setVariable["gmsLootVehicleColor",_isColorOn];
if (_checked && _isLootVeh) then {
{_object setObjectTexture [_x,gms3DENlootVehicleTexture]} forEach (count (getObjectTextures _object));
} else {
{_object setObjectTexture [_x,""]} forEach (count (getObjectTextures _object));
};
};

View File

@ -1,50 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
sets a flag stored through setVariable for each selected object that meets the filter criteria
only objects of type "Car"or "ThingX" are allowed.
*/
params["_state"];
private _markerStateON = missionNameSpace getVariable["blck_displayLootMarkerOn",false];
[false] call gms3DEN_fnc_displayLootMarkers;
private "_message";
private _objects = get3DENSelected "object" select {(typeOf _x) isKindOf "Car" || (typeOf _x) isKindOf "Ship"}; //
if (_objects isEqualTo []) exitWith
{
_message = "Select one or more vehicles or items of type ThingX to configure";
systemChat _message;
};
{
if ((typeOf _x) isKindOf "Car" || (typeOf _x) isKindOf "Ship") then
{
_x setVariable["lootvehicle",_state];
if (blck_displayLootMarkerOn && _state) then
{
[_x] call gms3DEN_fnc_createLootMarker;
[_x] call gms3DEN_fnc_setEventHandlers;
} else {
if !(_state) then
{
[_x] call gms3DEN_fnc_removeLootMarker;
};
};
_message = format["Vehicle type %1 set to Loot Vehicle = %1",typeOf _x,_state];
systemChat _message;
diag_log _message;
} else {
_message = format["Object with type %1 ignored:: only objects of type Car can be used as loot vehicles",typeOf _x];
diag_log _message;
systemChat _message;
};
} forEach _objects;
if (_markerStateON) then
{
[true] call gms3DEN_fnc_displayLootMarkers;
};
_m = format["Loot Vehicle State of %1 objects updated to %2",count _objects,_state];
systemChat _m;
diag_log _m;

View File

@ -1,18 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
sets a variable that specifies the maximum number of AI that will be spawned for each infantry group.
this variable is read when the mission is exported and saved in the configuration for each mission Infantry Group.
*/
params["_maxAI"];
if (_maxAI < GMS_minAI) exitWith {
private _m = format["Invalid selection - MinAI set to %1. Max AI must be greater than or equal to min AI",GMS_minAI];
systemChat _m;
diag_log _m;
[_m, "ERROR"] call BIS_fnc_3DENShowMessage;
};
GMS_maxAI = _maxAI;
diag_log format["_setMaxAI: GMS_maxAI set to %1",GMS_maxAI];

View File

@ -1,18 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
sets a variable that specifies the minimum number of AI that will be spawned for each infantry group.
this variable is read when the mission is exported and saved in the configuration for each missionInfantryGroup.
*/
params["_minAI"];
if (_minAI > GMS_maxAI) exitWith {
private _m = format["Invalid selection - MaxAI set to %1. Min AI must be less than or equal to max AI",GMS_maxAI];
systemChat _m;
diag_log _m;
[_m, "ERROR"] call BIS_fnc_3DENShowMessage;
};
GMS_minAI = _minAI;
diag_log format["_setMinAI: GMS_minAI set to %1",GMS_minAI];

View File

@ -1,11 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
sets a variable that specifies the chance that a mission will be spawned.
this variable is read when the mission is exported and saved in _chanceMissionSpawned.
*/
params["_chance"];
GMS_chanceMissionSpawned = _chance;
diag_log format["_setSpawnChance: GMS_chanceMissionSpawned set to %1",GMS_chanceMissionSpawned];

View File

@ -1,16 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
params["_mode"];
switch (_mode) do
{
GMS_missionLocations = "random";
GMS_missionLocations= "fixed";
};
private _m = format["Mission Locations updated to %1",_mode];
systemChat _m;
diag_log _m;

View File

@ -1,12 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
#include "gms3DEN_defines.hpp"
params["_timing"];
GMS_spawnCratesTiming = _timing;
private _m= format["Loot Chest Spawn Timing updated to %1",GMS_spawnCratesTiming];
systemChat _m;
diag_log _m;

View File

@ -1,10 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params["_start"];
missionNamespace setVariable["blck_startMessage",_start];
systemChat format["Start Message set to %1",_start];

View File

@ -1 +0,0 @@
diag_log format["executing test.sqf at %1",diag_tickTime];

View File

@ -1,9 +0,0 @@
params["_mode"];
GMS_missionSpawnMode = _mode;
_m = format["_toggleStaticSpawns: _mode = %1",_mode];
diag_log _m;
systemChat _m;
_m = format["_toggleStaticSpawns: GMS_missionSpawnMode = %1",GMS_missionSpawnMode];
diag_log _m;
systemChat _m;

View File

@ -1,19 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Copyright 2020
*/
params[["_mode",""]];
private _header = format
["GMS 3DEN Plugin Version %1 : Build %2 : Build Date %3",
getNumber(configFile >> "CfgGMS3DENVersion" >> "version"),
getNumber(configFile >> "CfgGMS3DENVersion" >> "build"),
getText(configFile >> "CfgGMS3DENVersion" >> "date"),
_mode
];
_header

View File

@ -1,15 +0,0 @@
#define GMS_blue 1
#define GMS_red 2
#define GMS_green 3
#define GMS_orange 4
// Defines for mission characteristics
#define playerNear 0
#define allUnitsKilled 1
#define allKilledOrPlayerNear 2
#define assetSecured 3
#define atMissionSpawnGround 0
#define atMissionSpawnAir 1
#define atMissionEndGround 2
#define atMissionEndAir 3

View File

@ -1,8 +0,0 @@
Long-term TODO:

View File

@ -1,19 +0,0 @@
/*
GMS 3EDEN Editor Plugin
by Ghostrider-GRG-
Parts of config.cpp were derived from the Exile_3EDEN editor plugin
* and is licensed as follows:
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
* To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
*/
#include "Core\gms3DEN_defines.hpp"
#include "gmsCfgPatches.h"
#include "gmsCfgFunctions.h"
#include "gmsCfg3DENVersion.h"
#include "gmsCfg3DENsettings.h"
#include "gmsCfg3DEN.h"
#include "gmsCfg3DENDisplay.h"

View File

@ -1,119 +0,0 @@
/*
*/
class cfg3DEN
{
class EventHandlers
{
class gms3DEN
{
OnMissionLoad = "diag_log format['Mission loaded at %1',diag_tickTime]; call gms3DEN_fnc_initialize";
OnMissionNew = "diag_log format['New Mission Created at %1',diag_tickTime]; call gms3DEN_fnc_initialize";
//onHistoryChange = "call gms3DEN_fnc_updateObjects";
};
};
class Attributes
{
class Default;
class Title: Default
{
class Controls
{
class Title;
};
};
class CheckBox;
class gms3DENCheckboxLootVehControl: CheckBox
{
/*
Use on: Display, Control
Fired on: Fires when UI container is created, but no action is taken. The onLoad event for display fires after the onLoad events for all controls it contains are fired.
Returns: Display or control, for controls it also returns the control's config (since
Arma 3 logo black.png
1.56
).
params ["_displayOrControl", ["_config", configNull]];
*/
onload = "\
params ['_displayOrControl', ['_config', configNull]];\
diag_log format['_displayControl = %1 | _config = %2',_displayControl,_config];\
[] call gms3DEN_fnc_onLoadLootVeh;\
";
//onUnload = "diag_log 'onUnload for loot veh'";
AttributeLoad = "\
_checked = switch (true) do {\
case (_value isequaltype 0): {([false,true] select (_value max 0 min 1))};\
case (_value isequaltype ''): {([false,true] select ((parsenumber _value) max 0 min 1))};\
default {_value};\
};\
(_this controlsGroupCtrl 100) cbsetchecked _checked;\
diag_log format['onAttributeLoad:lootVehControl: _checked = %1',_checked];\
";
AttributeSave = "\
cbchecked (_this controlsGroupCtrl 100);\
diag_log format['onattributesave:lootVehControl: _checked = %1',cbchecked (_this controlsGroupCtrl 100)];\
";
};
class gms3DENCLootVehicleColorControl: CheckBox
{
onload = "\
params ['_displayOrControl', ['_config', configNull]];\
diag_log format['_displayControl = %1 | _config = %2',_displayControl,_config];\
[] call gms3DEN_fnc_onLoadLootVehColor;\
";
//onUnload = "diag_log 'onUnload for loot veh'";
AttributeLoad = "\
_checked = switch (true) do {\
case (_value isequaltype 0): {([false,true] select (_value max 0 min 1))};\
case (_value isequaltype ''): {([false,true] select ((parsenumber _value) max 0 min 1))};\
default {_value};\
};\
(_this controlsGroupCtrl 100) cbsetchecked _checked;\
diag_log format['onAttributeLoad:lootVehControlColor: _checked = %1',_checked];\
";
AttributeSave = "\
cbchecked (_this controlsGroupCtrl 100);\
diag_log format['onattributesave:lootVehColorControl: _checked = %1',cbchecked (_this controlsGroupCtrl 100)];\
[cbchecked (_this controlsGroupCtrl 100)] call gms3DEN_fnc_setLootVehColor;\
";
};
};
class Object
{
class AttributeCategories
{
class gms3DENlootVehicles
{
displayName = "Loot Vehicle";
collapsed = 1;
class Attributes
{
class lootVehicleAttribute
{
displayName = "Loot Vehicle";
tooltip = "Set box to checked for loot vehicles";
property = "gmsIsLootVehicle";
control = "gms3DENCheckboxLootVehControl";
condition = "objectVehicle ";
expression = "_this setVariable ['%s',_value];";
defaultValue = "false";
};
class lootVehicleColorAttribute
{
displayName = "Color On";
tooltip = "Check box to color this loot vehicle";
property = "gmsLootVehicleColor";
control = "gms3DENCLootVehicleColorControl";
condition = "objectVehicle ";
expression = "_this setVariable ['%s',_value];";
defaultValue = "false";
};
};
};
};
};
};

View File

@ -1,410 +0,0 @@
/*
Setup classes that add toolbar menus and define them and the code that is executed by them.
Copyright 2023 by Ghostrider[GRG]
*/
class ctrlMenuStrip;
class display3DEN
{
class Controls
{
class MenuStrip: ctrlMenuStrip
{
class Items
{
// Additions to the menu strip to export missions and seek help
// ************************************************************
items[] += {"GMS_configure","GMS_export","GMS_support"};
/*
All menus for configuring a GMS mission are defined here
*/
class GMS_configure {
text = "GMS Settings";
toolTip = "Adjust Settings";
items[] = {
"GMS_missions",
"GMS_units"
//"GMS_plugin"
};
};
class GMS_missions
{
text = "Mission Settings";
tooltip = "Adjust Mission Settings";
items[] = {
"GMS_static",
"GMS_missionSpawnChance",
"GMS_difficulty",
"GMS_MissionCompletionMode",
"GMS_crateSpawn",
"GMS_lootSpawn"
};
};
class GMS_missionSpawnChance
{
text = "Spawn Chance";
toolTip = "Set the chance the mission will spawn";
items[] = {
"GMS_spawnTwenty",
"GMS_spawnFourty",
"GMS_spawnSixty",
"GMS_spawnEighty",
"GMS_spawnHundred"
};
};
class GMS_spawnTwenty
{
text = "Spawn chance 20%";
action = "[0.20] call gms3DEN_fnc_setSpawnChance;";
};
class GMS_spawnFourty
{
text = "Spawn chance 40%";
action = "[0.40] call gms3DEN_fnc_setSpawnChance;";
};
class GMS_spawnSixty
{
text = "Spawn chance 60%";
action = "[0.60] call gms3DEN_fnc_setSpawnChance;";
};
class GMS_spawnEighty
{
text = "Spawn chance 80%";
action = "[0.80] call gms3DEN_fnc_setSpawnChance;";
};
class GMS_spawnHundred
{
text = "Spawn chance 100%";
action = "[1.00] call gms3DEN_fnc_setSpawnChance;";
};
class GMS_difficulty {
text = "Difficulty";
toolTip = "Set Mission Difficulty";
items[] = {
"GMS_difficultyBlue",
"GMS_difficultyRed",
"GMS_difficultyGreen",
"GMS_difficultyOrange"
};
};
class GMS_difficultyBlue
{
text = "Set Mission Difficutly to EASY (Blue)";
action = "['Blue'] call gms3DEN_fnc_setDifficulty;";
value = GMS_blue;
};
class GMS_difficultyRed
{
text = "Set Mission Difficulty to MEDIUM (Red)";
action = "['Red'] call gms3DEN_fnc_setDifficulty;";
value = GMS_red;
};
class GMS_difficultyGreen
{
text = "Set Mission Difficult To HARD (Green)";
action = "['Green'] call gms3DEN_fnc_setDifficulty;";
value = GMS_green;
};
class GMS_difficultyOrange
{
text = "Set Mission Difficulty to Very HARD (Orange)";
action = "['Orange'] call gms3DEN_fnc_setDifficulty;";
value = GMS_orange;
};
class GMS_MissionCompletionMode
{
text = "Set the Criterial for Mission Completion";
items[] = {
"GMS_playerNear",
"GMS_allUnitsKilled",
"GMS_allKilledOrPlayerNear",
"GMS_assetSecured"
};
};
class GMS_allUnitsKilled
{
text = "All AI Dead";
toolTip = "Mission is complete only when All AI are Dead";
action = "['allUnitsKilled'] call gms3DEN_fnc_setCompletionMode;";
value = allUnitsKilled;
};
class GMS_playerNear
{
text = "Player near mission center";
toolTip = "MIssion is Complete when a player reaches the mission center";
action = "['playerNear'] call gms3DEN_fnc_setCompletionMode;";
value = playerNear;
};
class GMS_allKilledOrPlayerNear
{
text = "Units Dead / Player @ Center";
toolTip = "Mission is Complete when all units are dead or a player reaches mission center";
action = "['allKilledOrPlayerNear'] call gms3DEN_fnc_setCompletionMode;";
value = allKilledOrPlayerNear;
};
class GMS_assetSecured
{
text = "Asset Secured";
toolTip = "Mission is Complete when the asset is secured";
action = "[assetSecured] call gms3DEN_fnc_setCompletionMode;";
value = allKilledOrPlayerNear;
};
class GMS_crateSpawn {
text = "Set When Crates Spawn";
toolTip = "Set when crates are spawned";
items[] = {
"GMS_atMissionSpawnGround",
"GMS_atMissionSpawnAir",
"GMS_atMissionEndGround",
"GMS_atMissionEndAir"
};
};
class GMS_atMissionSpawnGround
{
text = "At Spawn Ground";
toolTip = "Crates are spawned on the ground at mission startup";
action = "['atMissionSpawnGround'] call gms3DEN_fnc_spawnCratesTiming;";
};
class GMS_atMissionSpawnAir
{
text = "At Spawn Air";
toolTip = "Crates are spawned in the air at mission startup";
action = "['atMissionSpawnAir'] call gms3DEN_fnc_spawnCratesTiming;";
};
class GMS_atMissionEndGround
{
text = "At End Ground";
toolTip = "Crates are spawned on the ground at mission completion";
action = "['atMissionEndGround'] call gms3DEN_fnc_spawnCratesTiming;";
};
class GMS_atMissionEndAir
{
text = "At End Air";
toodTip = "Crates are spawned in the air at mission completion";
action = "['atMissionEndAir'] call gms3DEN_fnc_spawnCratesTiming;";
};
class GMS_lootSpawn {
text = "Set timing for loading crates";
items[] = {
"GMS_atMissionSpawn",
"GMS_atMissionCompletion"
};
};
class GMS_atMissionSpawn
{
text = "At Spawn";
toolTip = "Load crates when the mission spawns";
action = "['atMissionSpawn'] call gms3DEN_fnc_setLoadCratesTiming";
};
class GMS_atMissionCompletion
{
text = "At Completion";
toolTip = "Load crates when the mission is complete";
action = "['atMissionCompletion'] call gms3DEN_fnc_setLoadCratesTiming";
};
class GMS_static {
text = "Set if Mission is Static/Dynamic";
toolTip = "Toggle between static and random mission locations";
items[] = {
"GMS_setToDynamic",
"GMS_setToStatic"
};
};
class GMS_setToDynamic {
text = "Dynamic (Default)";
toolType = "Set mission to be spawned at random location";
action = "['Dynamic'] call gms3DEN_fnc_toggleStaticSpawns";
};
class GMS_setToStatic {
text = "Static";
toolTip = "Set mission to respawn at the same location each time";
action = "['Static'] call gms3DEN_fnc_toggleStaticSpawns";
};
class GMS_plugin
{
text = "Pluggin Settings";
items[] = {
"GMS_garrisonATL"
};
};
class GMS_units
{
text = "Adjust AI Settings"
items[] = {
"GMS_maxAI",
"GMS_minAI"
};
};
class GMS_maxAI
{
text = "Max AI per Infantry Group";
tooltip = "set the maximum AI per Infantry Group";
items[] = {
"GMS_maxThree",
"GMS_maxFour",
"GMS_maxFive",
"GMS_maxSix",
"GMS_maxEight",
"GMS_maxNine"
};
};
class GMS_maxThree
{
text = "set max AI = 3";
action = "[3] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxFour
{
text = "set max AI = 4";
action = "[4] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxFive
{
text = "set max AI = 5";
action = "[5] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxSix
{
text = "set max AI = 6";
action = "[6] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxSeven
{
text = "set max AI = 7";
action = "[7] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxEight
{
text = "set max AI = 8";
action = "[8] call gms3DEN_fnc_setMaxAI";
};
class GMS_maxNine
{
text = "set max AI = 9";
action = "[9] call gms3DEN_fnc_setMaxAI";
};
class GMS_minAI
{
text = "Min AI per Infantry Group";
tooltip = "Set the minimum AI per infantry group";
items[] = {
"GMS_minOne",
"GMS_minTwo",
"GMS_minThree",
"GMS_minFour",
"GMS_minFive",
"GMS_minSix"
};
};
class GMS_minOne
{
text = "set min AI = 1";
action = "[1] call gms3DEN_fnc_setMinAI";
};
class GMS_minTwo
{
text = "set min AI = 2";
action = "[2] call gms3DEN_fnc_setMinAI";
};
class GMS_minThree
{
text = "set min AI = 3";
action = "[3] call gms3DEN_fnc_setMinAI";
};
class GMS_minFour
{
text = "set min AI = 4";
action = "[4] call gms3DEN_fnc_setMinAI";
};
class GMS_minFive
{
text = "set min AI = 5";
action = "[5] call gms3DEN_fnc_setMinAI";
};
class GMS_minSix
{
text = "set min AI = 6";
action = "[6] call gms3DEN_fnc_setMinAI";
};
class GMS_garrisonATL
{
text = "Garrison-ATL Mode";
items[] = {
"GMS_garrisonATLoff",
"GMS_garrisonATLon",
"GMS_aboutGarrisonATL"
};
};
class GMS_garrisonATLoff
{
text = "Off (default)";
action = "[false] call gms3DEN_fnc_setGarrisonATL";
};
class GMS_garrisonATLon
{
text = "On";
action = "[true] call gms3DEN_fnc_setGarrisonATL";
};
class GMS_aboutGarrisonATL
{
text = "Help";
action = "call gms3DEN_fnc_garissonATLhelp";
};
/***************************************
The menu for exporting missions is defined here
***************************************/
class GMS_export {
items[]= {
"GMS_exportDynamic"
};
text = "Export Mission";
toolTip = "Export GMS Missions";
};
class GMS_exportDynamic {
text = "Export Mission";
//toolTip = "Export Dynamic Mission";
action = "call gms3DEN_fnc_exportDynamic";
picture = "\a3\3DEN\Data\Displays\Display3DEN\ToolBar\save_ca.paa";
};
/***************************************
menus for those seeking support are here
***************************************/
class GMS_support {
items[] = {
"GMS_help",
"GMS_about"
};
text = "Plugin Support";
};
class GMS_help {
text = "Help";
action = "call gms3DEN_fnc_Help";
};
class GMS_about {
text = "3EDEN Plugin Version 1.0 for GMS by Ghostrider-GRG-";
action = "call blck3EDEN_fnc_about";
};
};
};
};
};

View File

@ -1,8 +0,0 @@
class CfgGMS3DENVersion
{
version = 1.2;
build = 17;
date = "09/26/23";
};

View File

@ -1,25 +0,0 @@
class CfgGMS3DEN
{
class CfgDefaults
{
objectAtMissionCenter = "RoadCone_L_F";
minAI = 3;
maxAI = 6;
defaultMissionDifficulty = "Blue";
defaultLootcrateSpawnTiming = "atMissionSpawnGround";
defaultLootcrateLoadTiming = "atMissionSpawn";
defaultMissionEndState = "allKilledOrPlayerNear";
// colors used to highlight garrison objects and loot objects
colorGarrisonObject = "#(argb,8,8,3)color(0,1,0,1)"; // Lime
colorLootObject = "#(argb,8,8,3)color(1,0,1,1)"; // Fucshia
};
/****************************************
DO NOT TOUCH ANYTHING BELOW THIS LINE
*****************************************/
};

View File

@ -1,52 +0,0 @@
class CfgFunctions
{
class gms3DEN
{
class Core
{
file = "3DEN_plugin\Core";
class about {};
class buildingContainer {};
class configureGarrisonATL {};
class display {};
class displayGarrisonMarkers {};
class displayLootMarkers {};
class exportDynamic {};
class garrisonApplyChanges {};
class initialize {};
class initializeAttributes {};
class isInfantryUnit {};
class isInVehicle {};
class isInside {};
class onAttributeLoadGarrison {};
class onAttributeLoadGarrisonColor {};
class onAttributeLoadLootVeh {};
class onAttributeLoadLootVehColor {};
class onAttributeSaveGarrison {};
class onAttributeSaveGarrisonColor {};
class onAttributeSaveLootVeh {};
class onDrag {};
class onLoadGarrison {};
class onLoadGarrisonColor {};
class onLoadLootVeh {};
class onLoadLootVehColor {};
class onRegistered {};
class onUnregister {};
class removeMarker {};
class setDifficulty {};
class setCompletionMode {}
class setGarrison {};
class setLoadCratesTiming {};
class setLootVehColor {};
class setMaxAI {};
class setMinAI {};
class setSpawnChance {};
class setSpawnLocations {};
class spawnCratesTiming {};
class toggleStaticSpawns {};
class versionInfo {};
};
};
};

View File

@ -1,12 +0,0 @@
class CfgPatches
{
class GMS_3DEN
{
requiredVersion = 0.1;
requiredAddons[] = {3DEN};
units[] = {};
weapons[] = {};
magazines[] = {};
ammo[] = {};
};
};