Initial Testing Commit

This commit is contained in:
eraser1 2016-03-01 00:34:55 -06:00
parent 11d0f608dd
commit d435e6cf1a
29 changed files with 334 additions and 342 deletions

View File

@ -1,4 +1,4 @@
/*%FSM<COMPILE "scriptedFSM.cfg, missions">*/
/*%FSM<COMPILE "C:\Program Files (x86)\Bohemia Interactive\Tools\FSM Editor Personal Edition\scriptedFSM.cfg, missions">*/
/*%FSM<HEAD>*/
/*
item0[] = {"",7,210,743.923157,366.553040,751.923157,374.553040,0.000000,""};
@ -16,9 +16,9 @@ item11[] = {"Mission_Cleanup",2,250,697.923035,248.598328,797.923035,298.598328,
item12[] = {"INITIALIZE",4,218,638.875183,-106.463760,728.875183,-56.463760,0.000000,"INITIALIZE"};
item13[] = {"PREPARE",2,250,763.528931,-107.864372,853.528931,-57.864372,0.000000,"PREPARE"};
item14[] = {"___min_loop",4,218,838.578918,171.729218,928.578918,221.729218,3.000000,"1 min loop"};
item15[] = {"Select_Mission",2,250,839.279602,248.118042,929.279663,298.118042,0.000000,"Select Mission"};
item15[] = {"Select_Mission",2,4346,839.279602,248.118042,929.279663,298.118042,0.000000,"Select Mission"};
item16[] = {"",7,210,880.582092,366.639160,888.582092,374.639160,0.000000,""};
item17[] = {"___min_loop__AI",4,4314,975.237671,175.934219,1065.237793,225.934219,0.000000,"1 min loop (AI)"};
item17[] = {"___min_loop__AI",4,218,975.237671,175.934219,1065.237793,225.934219,0.000000,"1 min loop (AI)"};
item18[] = {"Set_AI_Ownership",2,250,975.237732,250.921417,1065.237305,300.921417,0.000000,"Set AI Ownership"};
item19[] = {"",7,210,1016.540222,366.725281,1024.540283,374.725281,0.000000,""};
link0[] = {0,10};
@ -44,231 +44,221 @@ link19[] = {16,0};
link20[] = {17,18};
link21[] = {18,19};
link22[] = {19,16};
globals[] = {0.000000,0,0,0,0,640,480,2,454,6316128,1,432.812775,1219.813965,504.306030,-50.239235,799,563,1};
window[] = {0,-1,-1,-1,-1,1045,285,1579,311,1,817};
globals[] = {0.000000,0,0,0,0,640,480,2,454,6316128,1,432.812775,1219.813965,504.306030,-50.239235,799,589,1};
window[] = {0,-1,-1,-1,-1,834,100,1394,100,1,817};
*//*%FSM</HEAD>*/
class FSM
{
fsmName = "missions";
class States
fsmName = "missions";
class States
{
/*%FSM<STATE "INIT">*/
class INIT
{
name = "INIT";
init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "INITIALIZE">*/
class INITIALIZE
{
/*%FSM<STATE "INIT">*/
class INIT
{
name = "INIT";
itemno = 1;
init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "INITIALIZE">*/
class INITIALIZE
{
itemno = 12;
priority = 0.000000;
to="PREPARE";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"!isnil ""bis_fnc_init"""/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Waiting">*/
class Waiting
{
name = "Waiting";
itemno = 3;
init = /*%FSM<STATEINIT""">*/"// Waiting for next task to proceed with."/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "___min_loop">*/
class ___min_loop
{
itemno = 14;
priority = 3.000000;
to="Select_Mission";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _selectMission) > 60)" \n
""/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "___min_loop_1">*/
class ___min_loop_1
{
itemno = 8;
priority = 2.000000;
to="Mission_Cleanup";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _cleanupTime) > 300)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/"_missionsMonitor = time;"/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "__5_sec_loop_">*/
class __5_sec_loop_
{
itemno = 5;
priority = 1.000000;
to="Check_Mission_Running";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _missionsMonitor) > 15)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "___min_loop__AI">*/
class ___min_loop__AI
{
itemno = 17;
priority = 0.000000;
to="Set_AI_Ownership";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _aiLocality) > 60)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Check_Mission_Running">*/
class Check_Mission_Running
{
name = "Check_Mission_Running";
itemno = 6;
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_MissionsMonitor""]) call DMS_fnc_DebugLog;" \n
"" \n
"_missionsMonitor = diag_tickTime;" \n
"call DMS_fnc_MissionsMonitor;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
itemno = 2;
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Mission_Cleanup">*/
class Mission_Cleanup
{
name = "Mission_Cleanup";
itemno = 11;
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_CleanUpManager""]) call DMS_fnc_DebugLog;" \n
"" \n
"_cleanupTime = diag_tickTime;" \n
"call DMS_fnc_CleanUpManager;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
itemno = 2;
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "PREPARE">*/
class PREPARE
{
name = "PREPARE";
itemno = 13;
init = /*%FSM<STATEINIT""">*/"private [""_missionsMonitor"",""_cleanupTime"",""_selectMission""];" \n
"diag_log (""DMS :: Initializing FSM mission script"");" \n
"" \n
"_missionsMonitor = diag_tickTime;" \n
"_cleanupTime = diag_tickTime;" \n
"_selectMission = diag_tickTime;" \n
"_aiLocality = diag_tickTime;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
itemno = 2;
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Select_Mission">*/
class Select_Mission
{
name = "Select_Mission";
itemno = 15;
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_SelectMission""]) call DMS_fnc_DebugLog;" \n
"" \n
"_selectMission = diag_tickTime;" \n
"call DMS_fnc_SelectMission;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
itemno = 2;
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Set_AI_Ownership">*/
class Set_AI_Ownership
{
name = "Set_AI_Ownership";
itemno = 18;
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_AILocalityManager""]) call DMS_fnc_DebugLog;" \n
"" \n
"_aiLocality = diag_tickTime;" \n
"call DMS_fnc_AILocalityManager;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
itemno = 2;
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
priority = 0.000000;
to="PREPARE";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"!isnil ""bis_fnc_init"""/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
initState="INIT";
finalStates[] =
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Waiting">*/
class Waiting
{
name = "Waiting";
init = /*%FSM<STATEINIT""">*/"// Waiting for next task to proceed with."/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "___min_loop">*/
class ___min_loop
{
priority = 3.000000;
to="Select_Mission";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _selectMission) > 60)" \n
""/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "___min_loop_1">*/
class ___min_loop_1
{
priority = 2.000000;
to="Mission_Cleanup";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _cleanupTime) > 300)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/"_missionsMonitor = time;"/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "__5_sec_loop_">*/
class __5_sec_loop_
{
priority = 1.000000;
to="Check_Mission_Running";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _missionsMonitor) > 15)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
/*%FSM<LINK "___min_loop__AI">*/
class ___min_loop__AI
{
priority = 0.000000;
to="Set_AI_Ownership";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"((diag_tickTime - _aiLocality) > 60)"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Check_Mission_Running">*/
class Check_Mission_Running
{
name = "Check_Mission_Running";
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_MissionsMonitor""]) call DMS_fnc_DebugLog;" \n
"" \n
"_missionsMonitor = diag_tickTime;" \n
"call DMS_fnc_MissionsMonitor;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Mission_Cleanup">*/
class Mission_Cleanup
{
name = "Mission_Cleanup";
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_CleanUpManager""]) call DMS_fnc_DebugLog;" \n
"" \n
"_cleanupTime = diag_tickTime;" \n
"call DMS_fnc_CleanUpManager;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "PREPARE">*/
class PREPARE
{
name = "PREPARE";
init = /*%FSM<STATEINIT""">*/"private [""_missionsMonitor"",""_cleanupTime"",""_selectMission""];" \n
"diag_log (""DMS :: Initializing FSM mission script"");" \n
"" \n
"_missionsMonitor = diag_tickTime;" \n
"_cleanupTime = diag_tickTime;" \n
"_selectMission = diag_tickTime;" \n
"_aiLocality = diag_tickTime;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Select_Mission">*/
class Select_Mission
{
name = "Select_Mission";
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_SelectMission""]) call DMS_fnc_DebugLog;" \n
"" \n
"_selectMission = diag_tickTime;" \n
"if (DMS_SpawnMissions_Scheduled) then" \n
"{" \n
" [] spawn DMS_fnc_SelectMission;" \n
"}" \n
"else" \n
"{" \n
" call DMS_fnc_SelectMission;" \n
"};"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
/*%FSM<STATE "Set_AI_Ownership">*/
class Set_AI_Ownership
{
name = "Set_AI_Ownership";
init = /*%FSM<STATEINIT""">*/"//(format [""FSM CHECK :: calling DMS_fnc_AILocalityManager""]) call DMS_fnc_DebugLog;" \n
"" \n
"_aiLocality = diag_tickTime;" \n
"call DMS_fnc_AILocalityManager;"/*%FSM</STATEINIT""">*/;
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
class Links
{
/*%FSM<LINK "true">*/
class true
{
priority = 0.000000;
to="Waiting";
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
};
/*%FSM</LINK>*/
};
};
/*%FSM</STATE>*/
};
initState="INIT";
finalStates[] =
{
};
};
/*%FSM</COMPILE>*/

View File

@ -28,6 +28,8 @@ DMS_Enable_RankChange = false; // Whether or not to use Rank Changes.
DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
DMS_SpawnMissions_Scheduled = false; // Whether or not to spawn missions in a scheduled environment. Setting to true may help with lag when certain missions spawn.
/* Mission System Settings */
/*General settings for dynamic missions*/
DMS_DynamicMission = true; // Enable/disable dynamic mission system.
@ -266,17 +268,17 @@ DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
DMS_Bandit_Vehicle_MoneyGain = 100; // The amount of Poptabs gained for killing a bandit vehicle crew member
DMS_Bandit_Vehicle_RepGain = 25; // The amount of Respect gained for killing a bandit vehicle crew member
DMS_Bandit_Vehicle_RankGain = 50;
/* DonkeyPunchDMS Custom Settings for Hero AI*/
/* DonkeyPunchDMS Custom Settings for Hero AI*/
DMS_Hero_Soldier_MoneyGain = 100; // The amount of Poptabs gained for killing a hero soldier
DMS_Hero_Soldier_RepGain = 20; // The amount of Respect gained for killing a hero soldier
DMS_Hero_Soldier_RankGain = -30;
DMS_Hero_Soldier_RankGain = -30;
DMS_Hero_Static_MoneyGain = 120; // The amount of Poptabs gained for killing a hero static gunner
DMS_Hero_Static_RepGain = 30; // The amount of Respect gained for killing a hero static gunner
DMS_Hero_Static_RankGain = -60;
DMS_Hero_Vehicle_MoneyGain = 200; // The amount of Poptabs gained for killing a hero vehicle crew member
DMS_Hero_Vehicle_RepGain = 50; // The amount of Respect gained for killing a hero vehicle crew member
DMS_Hero_Vehicle_RankGain = -100;
/* DonkeyPunchDMS Custom Settings for Survivor AI*/
/* DonkeyPunchDMS Custom Settings for Survivor AI*/
DMS_Survivor_Soldier_MoneyGain = -100; // The amount of Poptabs gained for killing a Survivor soldier
DMS_Survivor_Soldier_RepGain = -100; // The amount of Respect gained for killing a Survivor soldier
DMS_Survivor_Soldier_RankGain = -250;
@ -286,7 +288,7 @@ DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
DMS_Survivor_Vehicle_MoneyGain = -500; // The amount of Poptabs gained for killing a Survivor vehicle crew member
DMS_Survivor_Vehicle_RepGain = -100; // The amount of Respect gained for killing a Survivor vehicle crew member
DMS_Survivor_Vehicle_RankGain = -600;
DMS_AIKill_DistanceBonusMinDistance = 100; // Minimum distance from the player to the AI to apply the distance bonus.
DMS_AIKill_DistanceBonusCoefficient = 0.05; // If the distance from the player to the killed unit is more than "DMS_AIKill_DistanceBonusMinDistance" meters then the player gets a respect bonus equivalent to the distance multiplied by this coefficient. For example, killing an AI from 400 meters will give 100 extra respect (when the coefficient is 0.25). Set to 0 to disable the bonus. This bonus will not be applied if there isn't a regular AI kill bonus.
@ -300,7 +302,7 @@ DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
DMS_Bandit_Vehicle_RoadkillMoney = -10; // The amount of Poptabs gained/lost for running over a bandit vehicle crew member
DMS_Bandit_Vehicle_RoadkillRep = -5; // The amount of Respect gained/lost for running over a bandit vehicle crew member
DMS_Bandit_Vehicle_RoadkillRank = 50;
/* DonkeyPunchDMS Custom RoadKill Settings for Hero AI*/
/* DonkeyPunchDMS Custom RoadKill Settings for Hero AI*/
DMS_Hero_Soldier_RoadkillMoney = 20; // The amount of Poptabs gained/lost for running over a hero soldier
DMS_Hero_Soldier_RoadkillRep = 10; // The amount of Respect gained/lost for running over a hero soldier
DMS_Hero_Soldier_RoadkillRank = -40;
@ -310,13 +312,13 @@ DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
DMS_Hero_Vehicle_RoadkillMoney = 20; // The amount of Poptabs gained/lost for running over a hero vehicle crew member
DMS_Hero_Vehicle_RoadkillRep = 10; // The amount of Respect gained/lost for running over a hero vehicle crew member
DMS_Hero_Vehicle_RoadkillRank = -100;
/* DonkeyPunchDMS Custom Roadkill Settings for Survivor AI*/
/* DonkeyPunchDMS Custom Roadkill Settings for Survivor AI*/
DMS_Survivor_Soldier_RoadkillMoney = -200; // The amount of Poptabs gained/lost for running over a Survivor soldier
DMS_Survivor_Soldier_RoadkillRep = -200; // The amount of Respect gained/lost for running over a Survivor soldier
DMS_Survivor_Soldier_RoadkillRank = -200;
DMS_Survivor_Soldier_RoadkillRank = -200;
DMS_Survivor_Static_RoadkillMoney = -200; // The amount of Poptabs gained/lost for running over a Survivor static gunner
DMS_Survivor_Static_RoadkillRep = -200; // The amount of Respect gained/lost for running over a Survivor static gunner
DMS_Survivor_Static_RoadkillRank = -200;
DMS_Survivor_Static_RoadkillRank = -200;
DMS_Survivor_Vehicle_RoadkillMoney = -500; // The amount of Poptabs gained/lost for running over a Survivor vehicle crew member
DMS_Survivor_Vehicle_RoadkillRep = -100; // The amount of Respect gained/lost for running over a Survivor vehicle crew member
DMS_Survivor_Vehicle_RoadkillRank = -100;
@ -325,7 +327,7 @@ DMS_Add_AIKill2DB = false; // Adds killstat for player in the database ;)
/* DonkeyPunchDMS Custom Side Factions */
DMS_heroSide = WEST; // The side (team) that AI Heros will spawn on
DMS_survivorSide = CIV; // The side (team) that AI Survivor will spawn on
DMS_clear_AI_body = false; // Clear AI body as soon as they die
DMS_clear_AI_body_chance = 50; // Percentage chance that AI bodies will be cleared when they die
DMS_ai_disable_ramming_damage = true; // Disables damage due to ramming into AI. !!!NOTE: THIS WILL NOT BE RELIABLE WITH "DMS_ai_offload_to_client"!!!

View File

@ -7,7 +7,7 @@ DMS_HC_Object = objNull;
DMS_CleanUpList = [];
DMS_Version = "February 19 2016";
DMS_Version = "March 1 2016 (T)";
//Load main config

View File

@ -65,7 +65,7 @@ _crate1 = ["Box_NATO_Wps_F",_pos] call DMS_fnc_SpawnCrate;
_rndDir = random 180;
_wreck = createVehicle ["Land_FuelStation_Build_F",[_pos,10+(random 5),_rndDir+90] call DMS_fnc_SelectOffsetPos,[], 0, "CAN_COLLIDE"];
_wreck = createVehicle ["Land_FuelStation_Build_F",_pos getPos [10+(random 5),_rndDir+90],[], 0, "CAN_COLLIDE"];
_vehClass1 = "Exile_Car_SUV_Red";
@ -90,12 +90,10 @@ if !(_extraParams isEqualTo []) then
};
};
};
_vehicle1 = [_vehClass1, [_pos,5+(random 3),_rndDir] call DMS_fnc_SelectOffsetPos] call DMS_fnc_SpawnNonPersistentVehicle;
//_vehicle1 setPosATL ([_pos,5+(random 3),_rndDir] call DMS_fnc_SelectOffsetPos);
_vehicle1 = [_vehClass1, _pos getPos [5+(random 3),_rndDir]] call DMS_fnc_SpawnNonPersistentVehicle;
_vehicle2 = [_vehClass2, [_pos,5+(random 3),_rndDir+180] call DMS_fnc_SelectOffsetPos] call DMS_fnc_SpawnNonPersistentVehicle;
//_vehicle2 setPosATL ([_pos,5+(random 3),_rndDir+180] call DMS_fnc_SelectOffsetPos);
_vehicle2 = [_vehClass2, _pos getPos [5+(random 3),_rndDir+180]] call DMS_fnc_SpawnNonPersistentVehicle;

View File

@ -105,7 +105,7 @@ _crate = [_crateClassname, _pos] call DMS_fnc_SpawnCrate;
_veh =
[
[
[_pos,100,random 360] call DMS_fnc_SelectOffsetPos,
_pos getPos [_pos,100,random 360],
_pos
],
_group,

View File

@ -117,12 +117,15 @@ try
throw format["_missionObjs |%1|",_missionObjs];
};
_mines = [];
if ((count _missionObjs)>3) then
{
_mines = _missionObjs param [3,[],[[]]];
};
_mines =
if ((count _missionObjs)>3) then
{
_missionObjs param [3,[],[[]]]
}
else
{
[]
};
// Don't spawn a minefield if there is one already defined in _missionObjs.
if (DMS_SpawnMinefieldForEveryMission && {_mines isEqualTo []}) then

View File

@ -15,7 +15,7 @@
_markerDot,
_markerCircle
]
*/
@ -87,7 +87,7 @@ if (_randomMarker) then
{
_dir = random 360;
_dis = DMS_MarkerPosRandomRadius call DMS_fnc_SelectRandomVal;
_npos = [_pos,_dis,_dir] call DMS_fnc_SelectOffsetPos;
_npos = _pos getPos [_dis,_dir];
_circle setMarkerPos _npos;
_dot setMarkerPos _npos;
@ -105,4 +105,4 @@ if (DMS_DEBUG) then
};
[_dot,_circle];
[_dot,_circle];

View File

@ -168,7 +168,7 @@ if ((_lootValues isEqualType []) && {!((_lootValues select 1) isEqualType {})})
// Add weapons + mags
for "_i" from 1 to _wepCount do
{
_weapon = _weps call BIS_fnc_selectRandom;
_weapon = selectRandom _weps;
_ammo = _weapon call DMS_fnc_selectMagazine;
if (_weapon isEqualType "") then
{
@ -188,7 +188,7 @@ if ((_lootValues isEqualType []) && {!((_lootValues select 1) isEqualType {})})
// Add items
for "_i" from 1 to _itemCount do
{
_item = _items call BIS_fnc_selectRandom;
_item = selectRandom _items;
if (_item isEqualType "") then
{
_item = [_item,1];
@ -203,7 +203,7 @@ if ((_lootValues isEqualType []) && {!((_lootValues select 1) isEqualType {})})
// Add backpacks
for "_i" from 1 to _backpackCount do
{
_backpack = _backpacks call BIS_fnc_selectRandom;
_backpack = selectRandom _backpacks;
if (_backpack isEqualType "") then
{
_backpack = [_backpack,1];
@ -285,7 +285,7 @@ if(DMS_RareLoot && {count DMS_RareLootList>0}) then
// (Maybe) Add rare loot
if(random 100 < _rareLootChance) then
{
_item = DMS_RareLootList call BIS_fnc_selectRandom;
_item = selectRandom DMS_RareLootList;
if (_item isEqualType "") then
{
_item = [_item,1];

View File

@ -38,13 +38,13 @@ switch (true) do
case ((_weaponName find "9 mm") > -1) : {_result = "muzzle_snds_L";};
case ((_weaponName find ".338") > -1) : {_result = ["muzzle_snds_338_black","muzzle_snds_338_green","muzzle_snds_338_sand"] call BIS_fnc_selectRandom;};
case ((_weaponName find ".338") > -1) : {_result = selectRandom ["muzzle_snds_338_black","muzzle_snds_338_green","muzzle_snds_338_sand"];};
case ((_weaponName find "9.3 mm") > -1) : {_result = ["muzzle_snds_93mmg","muzzle_snds_93mmg_tan"] call BIS_fnc_selectRandom;};
case ((_weaponName find "9.3 mm") > -1) : {_result = selectRandom ["muzzle_snds_93mmg","muzzle_snds_93mmg_tan"];};
};
// Zafir accepts no suppressors :(
if ((_weapon find "Zafir")>-1) then {_result = "";};
_result
_result

View File

@ -39,28 +39,15 @@ _units = [];
case "OBJECT":
{
if (!(isNull _parameter) && {alive _parameter}) then
{
[_parameter]
}
else
{
[
[_parameter],
[]
}
] select (alive _parameter);
};
case "GROUP":
{
if (!isNull _parameter) then
{
{
if (alive _x) then
{
_units pushBack _x;
};
} forEach (units _parameter);
};
[]
(units _parameter) select {alive _x};
};
default
@ -78,4 +65,4 @@ if (DMS_DEBUG) then
};
_units
_units

View File

@ -371,7 +371,7 @@ if (!_reinforcementsDepleted && {(diag_tickTime-_lastUpdated)>_updateDelay}) the
_veh =
[
[
if (_spawnLocations isEqualTo []) then {[_leaderPos,100+(random 200),random 360] call DMS_fnc_SelectOffsetPos} else {_spawnLocations call BIS_fnc_selectRandom},
if (_spawnLocations isEqualTo []) then {_leaderPos getPos [100+(random 200),random 360]} else {selectRandom _spawnLocations},
_leaderPos
],
_AIGroup,
@ -417,7 +417,7 @@ if (!_reinforcementsDepleted && {(diag_tickTime-_lastUpdated)>_updateDelay}) the
_vehicle =
[
[
if (_spawnLocations isEqualTo []) then {[_leaderPos,100+(random 200),random 360] call DMS_fnc_SelectOffsetPos} else {_spawnLocations call BIS_fnc_selectRandom},
if (_spawnLocations isEqualTo []) then {[_leaderPos,100+(random 200),random 360] call DMS_fnc_SelectOffsetPos} else {selectRandom _spawnLocations},
_leaderPos
],
_AIGroup,

View File

@ -43,12 +43,12 @@ if ((count _pos)<3) then
};
_objs = [];
_export = call compile preprocessFileLineNumbers (format ["\x\addons\DMS\objects\%1.sqf",_file]);
_objs = _export apply
{
// Create the object
_obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"];
@ -69,8 +69,8 @@ _export = call compile preprocessFileLineNumbers (format ["\x\addons\DMS\objects
_obj setPos _objPos;
};
_objs pushBack _obj;
} foreach _export;
_obj;
};
_objs
_objs

View File

@ -44,12 +44,12 @@ if ((count _missionPos)<3) then
};
_objs = [];
_export = call compile preprocessFileLineNumbers (format ["\x\addons\DMS\objects\static\%1.sqf",_file]);
_objs = _export apply
{
private ["_obj","_pos"];
_obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"];
@ -65,10 +65,10 @@ _export = call compile preprocessFileLineNumbers (format ["\x\addons\DMS\objects
_obj setPosATL _pos;
_obj setVectorDirAndUp (_x select 3);
};
_objs pushBack _obj;
} foreach _export;
_obj;
};
[_objs,_missionPos] call DMS_fnc_setRelPositions;
_objs
_objs

View File

@ -48,15 +48,14 @@ if ((isNil "_export") || {!(_export isEqualType [])}) exitWith
};
_objs = [];
_objs = _export apply
{
private ["_obj","_pos"];
_obj = createVehicle [_x select 0, [0,0,0], [], 0, "CAN_COLLIDE"];
_pos = _x select 1;
_obj enableSimulationGlobal false;
if (_x select 4) then
{
_obj setDir (_x select 2);
@ -68,8 +67,8 @@ _objs = [];
_obj setVectorDirAndUp (_x select 3);
};
_objs pushBack _obj;
} foreach _export;
_obj;
};
_objs
_objs

View File

@ -38,7 +38,7 @@ try
for "_i" from 0 to 359 step 45 do
{
if (surfaceIsWater ([_position,_radius,_i] call DMS_fnc_SelectOffsetPos)) then
if (surfaceIsWater (_position getPos [_radius,_i])) then
{
throw true;
};
@ -49,4 +49,4 @@ catch
_result = true;
};
_result
_result

View File

@ -85,7 +85,7 @@ else
private "_dir";
for "_dir" from 0 to 359 step 45 do
{
if (((surfaceNormal ([_pos,5,_dir] call DMS_fnc_SelectOffsetPos)) select 2)<_minSurfaceNormal) then
if (((surfaceNormal (_pos getPos [5,_dir])) select 2)<_minSurfaceNormal) then
{
throw ("a nearby steep location");
};

View File

@ -103,7 +103,7 @@ _grpUnits = (units _grp) - [_unit];
// Give the AI a new leader if the killed unit was the leader
if (!(_grpUnits isEqualTo []) && {(leader _grp) isEqualTo _unit}) then
{
_grp selectLeader (_grpUnits call BIS_fnc_selectRandom);
_grp selectLeader (selectRandom _grpUnits);
};
_av = _unit getVariable ["DMS_AssignedVeh",objNull];

View File

@ -26,7 +26,7 @@ if (diag_fps >= DMS_MinServerFPS && {(count allPlayers) >= DMS_MinPlayerCount})
if (DMS_DynamicMission && {_time - DMS_BMissionLastStart > DMS_BMissionDelay}) then
{
private "_mission";
_mission = DMS_BanditMissionTypesArray call BIS_fnc_selectRandom;
_mission = selectRandom DMS_BanditMissionTypesArray;
if (DMS_DEBUG) then
{
@ -57,7 +57,7 @@ if (diag_fps >= DMS_MinServerFPS && {(count allPlayers) >= DMS_MinPlayerCount})
};
};
_mission = _availableMissions call BIS_fnc_selectRandom;
_mission = selectRandom _availableMissions;
if (DMS_DEBUG) then
{

View File

@ -4,21 +4,23 @@
Usage:
[
_pos,
_distance,
_direction
_origin, // OBJECT, or POSITION (2D or 3D): Center from which the offset position will be calculated.
_distance, // SCALAR: Distance from the origin (meters)
_direction // SCALAR: Direction from the origin (degrees)
] call DMS_fnc_SelectOffsetPos;
Returns a new position offset from the provided position with the provided distance and direction. Position provided is at ground level in ATL
Returns a new position offset from the provided position with the provided distance and direction. Position provided is at ground level in AGL
This function has been deprecated by the new functionality of the "getPos" command (https://community.bistudio.com/wiki/getPos). This function has been updated for efficiency and compatibility.
*/
private ["_pos","_dis","_dir","_npos"];
private ["_origin","_dis","_dir","_npos"];
if !(params
[
["_pos","",[[]],[2,3]],
["_origin","",[objNull,[]],[2,3]],
["_dis",0,[0]],
["_dir",0,[0]]
])
@ -28,9 +30,12 @@ exitWith
[0,0,0]
};
if ((count _pos) isEqualTo 2) then
/*
if ((count _origin) isEqualTo 2) then
{
_pos set [2,0];
_origin set [2,0];
};
*/
_pos vectorAdd [sin(_dir)*_dis,cos(_dir)*_dis,0]
//_origin vectorAdd [sin(_dir)*_dis,cos(_dir)*_dis,0] <-- Old code
_origin getPos [_dis,_dir]

View File

@ -64,22 +64,22 @@ _difficulty =
{
case "random":
{
DMS_ai_skill_random call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_random;
};
case "randomdifficult":
{
DMS_ai_skill_randomDifficult call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomDifficult;
};
case "randomeasy":
{
DMS_ai_skill_randomEasy call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomEasy;
};
case "randomintermediate":
{
DMS_ai_skill_randomIntermediate call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomIntermediate;
};
default
@ -100,12 +100,12 @@ for "_i" from count (waypoints _group) to 1 step -1 do
// Add waypoints around the center position.
for "_i" from 0 to 359 step 45 do
{
_npos = [_pos,_radius,_i] call DMS_fnc_SelectOffsetPos;
_npos = _pos getPos [_radius,_i];
_wp = _group addWaypoint [_npos,5];
_wp setWaypointType "MOVE";
};
_wp = _group addWaypoint [[_pos,_radius,0] call DMS_fnc_SelectOffsetPos,0];
_wp = _group addWaypoint [_pos,0];
_wp setWaypointType "CYCLE";

View File

@ -95,7 +95,7 @@ if ((!isNil "_launcherType") || {DMS_ai_use_launchers && {DMS_ai_launchers_per_g
{
_unit = _units select _i;
_launcher = ((missionNamespace getVariable [format ["DMS_AI_wep_launchers_%1",_launcherType],["launch_NLAW_F"]]) call BIS_fnc_selectRandom);
_launcher = (selectRandom (missionNamespace getVariable [format ["DMS_AI_wep_launchers_%1",_launcherType],["launch_NLAW_F"]]));
removeBackpackGlobal _unit;
_unit addBackpack "B_Carryall_mcamo";
@ -104,7 +104,7 @@ if ((!isNil "_launcherType") || {DMS_ai_use_launchers && {DMS_ai_launchers_per_g
[_unit, _launcher, DMS_AI_launcher_ammo_count,_rocket] call BIS_fnc_addWeapon;
_unit setVariable ["DMS_AI_Launcher",_launcher];
if (DMS_DEBUG) then
{
(format["SpawnAIGroup :: Giving %1 a %2 launcher with %3 %4 rockets",_unit,_launcher,DMS_AI_launcher_ammo_count,_rocket]) call DMS_fnc_DebugLog;

View File

@ -1,7 +1,7 @@
/*
DMS_fnc_SpawnAIGroup_MultiPos
Created by eraser1
Spawns a group of AI with a given AI count at the provided list of location(s), with a given difficulty, class, and side.
@ -112,7 +112,7 @@ if ((!isNil "_launcherType") || {DMS_ai_use_launchers && {DMS_ai_launchers_per_g
{
_unit = _units select _i;
_launcher = ((missionNamespace getVariable [format ["DMS_AI_wep_launchers_%1",_launcherType],["launch_NLAW_F"]]) call BIS_fnc_selectRandom);
_launcher = (selectRandom (missionNamespace getVariable [format ["DMS_AI_wep_launchers_%1",_launcherType],["launch_NLAW_F"]]));
removeBackpackGlobal _unit;
_unit addBackpack "B_Carryall_mcamo";
@ -121,7 +121,7 @@ if ((!isNil "_launcherType") || {DMS_ai_use_launchers && {DMS_ai_launchers_per_g
[_unit, _launcher, DMS_AI_launcher_ammo_count,_rocket] call BIS_fnc_addWeapon;
_unit setVariable ["DMS_AI_Launcher",_launcher];
if (DMS_DEBUG) then
{
(format["SpawnAIGroup_MultiPos :: Giving %1 a %2 launcher with %3 %4 rockets",_unit,_launcher,DMS_AI_launcher_ammo_count,_rocket]) call DMS_fnc_DebugLog;
@ -141,4 +141,4 @@ _group setFormation "WEDGE";
diag_log format ["DMS_SpawnAIGroup_MultiPos :: Spawned %1 AI using positions parameter: %2.",_count,_positions];
_group
_group

View File

@ -65,22 +65,22 @@ _difficulty =
{
case "random":
{
DMS_ai_skill_random call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_random;
};
case "randomdifficult":
{
DMS_ai_skill_randomDifficult call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomDifficult;
};
case "randomeasy":
{
DMS_ai_skill_randomEasy call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomEasy;
};
case "randomintermediate":
{
DMS_ai_skill_randomIntermediate call BIS_fnc_selectRandom;
selectRandom DMS_ai_skill_randomIntermediate;
};
default
@ -131,7 +131,7 @@ else
{
if (_class in DMS_ai_SupportedRandomClasses) then
{
_class = (missionNamespace getVariable [format["DMS_%1_AI",_class], DMS_random_AI]) call BIS_fnc_selectRandom;
_class = selectRandom (missionNamespace getVariable [format["DMS_%1_AI",_class], DMS_random_AI]);
};
};
@ -165,10 +165,10 @@ if (!_useCustomGear) then
// Clothes
_unit addHeadgear ((missionNamespace getVariable [format ["DMS_%1_helmets",_class],DMS_assault_helmets]) call BIS_fnc_selectRandom);
_unit forceAddUniform ((missionNamespace getVariable [format ["DMS_%1_clothes",_class],DMS_assault_clothes]) call BIS_fnc_selectRandom);
_unit addVest ((missionNamespace getVariable [format ["DMS_%1_vests",_class],DMS_assault_vests]) call BIS_fnc_selectRandom);
_unit addBackpack ((missionNamespace getVariable [format ["DMS_%1_backpacks",_class],DMS_assault_backpacks]) call BIS_fnc_selectRandom);
_unit addHeadgear (selectRandom (missionNamespace getVariable [format ["DMS_%1_helmets",_class],DMS_assault_helmets]));
_unit forceAddUniform (selectRandom (missionNamespace getVariable [format ["DMS_%1_clothes",_class],DMS_assault_clothes]));
_unit addVest (selectRandom (missionNamespace getVariable [format ["DMS_%1_vests",_class],DMS_assault_vests]));
_unit addBackpack (selectRandom (missionNamespace getVariable [format ["DMS_%1_backpacks",_class],DMS_assault_backpacks]));
// Make AI effective at night
_nighttime = (sunOrMoon != 1);
@ -179,24 +179,24 @@ if (!_useCustomGear) then
if (!_unarmed) then
{
_weapon = (missionNamespace getVariable [format ["DMS_%1_weps",_class],DMS_assault_weps]) call BIS_fnc_selectRandom;
_weapon = selectRandom (missionNamespace getVariable [format ["DMS_%1_weps",_class],DMS_assault_weps]);
[_unit, _weapon, 6 + floor(random 3)] call BIS_fnc_addWeapon;
_unit selectWeapon _weapon;
if((random 100) <= (missionNamespace getVariable [format["DMS_%1_optic_chance",_class],0])) then
{
_unit addPrimaryWeaponItem ((missionNamespace getVariable [format ["DMS_%1_optics",_class],DMS_assault_optics]) call BIS_fnc_selectRandom);
_unit addPrimaryWeaponItem (selectRandom (missionNamespace getVariable [format ["DMS_%1_optics",_class],DMS_assault_optics]));
};
if (_nighttime && {(random 100) <= DMS_ai_nighttime_accessory_chance}) then
{
_unit addPrimaryWeaponItem (["acc_pointer_IR","acc_flashlight"] call BIS_fnc_selectRandom);
_unit addPrimaryWeaponItem (selectRandom ["acc_pointer_IR","acc_flashlight"]);
};
if((random 100) <= (missionNamespace getVariable [format["DMS_%1_bipod_chance",_class],0])) then
{
_unit addPrimaryWeaponItem (DMS_ai_BipodList call BIS_fnc_selectRandom);
_unit addPrimaryWeaponItem (selectRandom DMS_ai_BipodList);
};
if((random 100) <= (missionNamespace getVariable [format["DMS_%1_suppressor_chance",_class],0])) then
@ -222,7 +222,7 @@ if (!_useCustomGear) then
_pistols = missionNamespace getVariable [format ["DMS_%1_pistols",_class],[]];
if !(_pistols isEqualTo []) then
{
_pistol = _pistols call BIS_fnc_selectRandom;
_pistol = selectRandom _pistols;
[_unit, _pistol, 2 + floor(random 2)] call BIS_fnc_addWeapon;
};

View File

@ -52,9 +52,9 @@ _guns = [];
_MGClass = _MGClassInput;
if (_MGClass == "random") then
{
_MGClass = DMS_static_weapons call BIS_fnc_selectRandom;
_MGClass = selectRandom DMS_static_weapons;
};
_gun = createVehicle [_MGClass, [0,0,0], [], 0, "CAN_COLLIDE"];
_gun setDir (random 360);
_gun setPosATL _pos;
@ -66,7 +66,7 @@ _guns = [];
_guns pushBack _gun;
_unit = [_group,_pos,_class,_difficulty,_side,"Static"] call DMS_fnc_SpawnAISoldier;
_unit moveInGunner _gun;
reload _unit;
_unit setVariable ["DMS_AssignedVeh",_gun];
@ -83,4 +83,4 @@ if (DMS_DEBUG) then
(format ["SpawnAIStaticMG :: Created %1 static AI with parameters: %2",count _positions,_this]) call DMS_fnc_DebugLog;
};
_guns
_guns

View File

@ -55,7 +55,7 @@ if ((count _this)>5) then
if (_vehClass == "random") then
{
_vehClass = DMS_ArmedVehicles call BIS_fnc_selectRandom;
_vehClass = selectRandom DMS_ArmedVehicles;
};

View File

@ -21,7 +21,7 @@ _mission =
missionNamespace getVariable format
[
"DMS_Mission_%1",
_this param [0, DMS_BanditMissionTypesArray call BIS_fnc_selectRandom, [""]]
_this param [0,selectRandom DMS_BanditMissionTypesArray, [""]]
]
] param [0, "no",[{}]];

View File

@ -1,7 +1,7 @@
/*
DMS_fnc_SpawnMinefield
Created by eraser1
Usage:
[
_centerPos, // ARRAY: Position to spawn the minefield around
@ -66,7 +66,7 @@ if (DMS_SpawnMinesAroundMissions) then
{
private ["_minePos", "_mine"];
_minePos = [_centerPos,random _radius,random 360] call DMS_fnc_SelectOffsetPos;
_minePos = _centerPos getPos [random _radius,random 360];
_mine = createMine ["ATMine", [0,0,0], [], 0];
// Fixes players shooting the mine and causing premature 'splosions
@ -92,7 +92,7 @@ if (DMS_SpawnMinesAroundMissions) then
{
_sign = createVehicle ["Land_Sign_Mines_F", [0,0,0], [], 0, "CAN_COLLIDE"];
_sign setDir (180+_i);
_sign setPosATL ([_centerPos, _radius+2, _randDirOffset+_i] call DMS_fnc_SelectOffsetPos);
_sign setPosATL (_centerPos getPos [_radius+2, _randDirOffset+_i]);
_sign setVectorUp [0,0,1];
// _mines array is for only cleanup atm, so just add them to the list
@ -108,4 +108,4 @@ if (DMS_SpawnMinesAroundMissions) then
_mines
_mines

View File

@ -17,7 +17,7 @@
private ["_missionType", "_mission", "_parameters", "_return"];
_missionType = param [0, DMS_StaticMissionTypesArray call BIS_fnc_selectRandom, [""]];
_missionType = param [0, selectRandom DMS_StaticMissionTypesArray, [""]];
_mission =
[

View File

@ -117,6 +117,14 @@ ___
___
# Changelog:
### Test Branch:
#### March 1, 2016 (12:30 AM CST-America):
* Initial Test Branch commit
* **NEW CONFIG VALUE:** DMS_SpawnMissions_Scheduled
* Several optimizations (mostly due to the new scripting commands introduced in 1.56)
* You can now spawn missions in scheduled environment.
#### February 19, 2016 (5:45 PM CST-America):
* Fixed a minor typo with a variable (part of the new Humanity support by DonkeyPunch).