Jump to content

FMission


Recommended Posts

Hi Guys running this mission system and missions spawn ok but some AI seem to get deleted as missions starts: see RPT below.

15:15:04 "RUNNING EVENT: FMission_Launcher3 on [2014,4,29,19,15]"
15:15:04 "FMission Launcher 3: Checking Spawn Chance"
15:15:04 "FMission Launcher 3: Spawn Chance Succeeded with 0.746937 it needed to be lower than 0.8"
15:15:05 "FMission Launcher 3: Selecting script and launching"
15:15:05 "FMission Launcher 3: Launching Mission: \z\addons\dayz_server\addons\Fmission\Missions\M3\FMission_M3_Wells Fargo.sqf"
15:15:05 "MISSION 3: WellsFargo - Script Started"
15:15:05 "MISSION 3: WellsFargo - Checking MissionSpawnChance"
15:15:06 "MISSION 3: WellsFargo - Mission SpawnChance Success"
15:15:06 "MISSION 3: WellsFargo - Mission Script Started"
15:15:06 "FMarker 3: Loading Script"
15:15:07 "EPOCH SERVERTRADE: Player: Legoklaus (235849478) sold a M14_EP1 in/at Unknown Trader City for 1x ItemGoldBar10oz"
15:15:08 "MISSION 3: WellsFargo - Loading -=FAI Units=- Started"
15:15:09 "FAI Unit 1.1: -=Noob=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:09 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Elite=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Noob=- Medic Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FLoot: Extra Loot Chance Failed"
15:15:10 "FAI Unit 1.1: -=Elite=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:10 "FAI Unit 1.1: AI Units Deleted"
15:15:11 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"
15:15:11 "FAI Unit 1.1: AI Units Deleted"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FAI Unit 1.1: AI Units Deleted"
15:15:11 "FAI Unit 1.1: AI Units Deleted"
15:15:11 "FLoot: Extra Loot Chance Success"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Success"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:11 "FLoot: Extra Loot Chance Failed"
15:15:22 "MISSION 3: WellsFargo - Loading -=FAI=- Completed"
15:15:24 "MISSION 3: WellsFargo - Waiting..."
15:15:24 "FLoot: Extra Loot Chance Failed"
15:15:24 "FLoot: Extra Loot Chance Failed"
15:15:25 "FAI Heli 1.0: -=UH1H_DZ=- Spawned @ Location: [11897.9,15416.5] | Patrol Radius: 250m"
15:15:25 "FAI Vehicle 1.0: AI Heli Deleted"
15:15:26 Server: Object 2:11480 not found (message 221)
15:15:26 "FAI Vehicle 1.0: -=GAZ_Vodnik_DZ=- Spawned @ Location: [11895.7,15386.7] | Patrol Radius: 100m"
15:15:26 "FAI Vehicle 1.0: AI Vehicle Deleted"

 

 

 

This happens on a few of these missions any idea whats happening as the mission on ends up having 1-3 AI left to kill, Also the extra Loot never spawns it always says Extra loot chance failed is there a way to up the chances ?

Thanks

MegaZ

Link to comment
Share on other sites

Hi Guys running this mission system and missions spawn ok but some AI seem to get deleted as missions starts: see RPT below.

15:15:04 "RUNNING EVENT: FMission_Launcher3 on [2014,4,29,19,15]"

15:15:04 "FMission Launcher 3: Checking Spawn Chance"

15:15:04 "FMission Launcher 3: Spawn Chance Succeeded with 0.746937 it needed to be lower than 0.8"

15:15:05 "FMission Launcher 3: Selecting script and launching"

15:15:05 "FMission Launcher 3: Launching Mission: \z\addons\dayz_server\addons\Fmission\Missions\M3\FMission_M3_Wells Fargo.sqf"

15:15:05 "MISSION 3: WellsFargo - Script Started"

15:15:05 "MISSION 3: WellsFargo - Checking MissionSpawnChance"

15:15:06 "MISSION 3: WellsFargo - Mission SpawnChance Success"

15:15:06 "MISSION 3: WellsFargo - Mission Script Started"

15:15:06 "FMarker 3: Loading Script"

15:15:07 "EPOCH SERVERTRADE: Player: Legoklaus (235849478) sold a M14_EP1 in/at Unknown Trader City for 1x ItemGoldBar10oz"

15:15:08 "MISSION 3: WellsFargo - Loading -=FAI Units=- Started"

15:15:09 "FAI Unit 1.1: -=Noob=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:09 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Elite=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Noob=- Medic Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FLoot: Extra Loot Chance Failed"

15:15:10 "FAI Unit 1.1: -=Elite=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Skilled=- Bandit Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:10 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:10 "FAI Unit 1.1: AI Units Deleted"

15:15:11 "FAI Unit 1.1: -=Skilled=- Sniper Spawned @ Location: [11900.5,15427.8] | Patrol Radius: 50m | Waypoints Assigned: 4"

15:15:11 "FAI Unit 1.1: AI Units Deleted"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FAI Unit 1.1: AI Units Deleted"

15:15:11 "FAI Unit 1.1: AI Units Deleted"

15:15:11 "FLoot: Extra Loot Chance Success"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Success"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:11 "FLoot: Extra Loot Chance Failed"

15:15:22 "MISSION 3: WellsFargo - Loading -=FAI=- Completed"

15:15:24 "MISSION 3: WellsFargo - Waiting..."

15:15:24 "FLoot: Extra Loot Chance Failed"

15:15:24 "FLoot: Extra Loot Chance Failed"

15:15:25 "FAI Heli 1.0: -=UH1H_DZ=- Spawned @ Location: [11897.9,15416.5] | Patrol Radius: 250m"

15:15:25 "FAI Vehicle 1.0: AI Heli Deleted"

15:15:26 Server: Object 2:11480 not found (message 221)

15:15:26 "FAI Vehicle 1.0: -=GAZ_Vodnik_DZ=- Spawned @ Location: [11895.7,15386.7] | Patrol Radius: 100m"

15:15:26 "FAI Vehicle 1.0: AI Vehicle Deleted"

 

 

 

This happens on a few of these missions any idea whats happening as the mission on ends up having 1-3 AI left to kill, Also the extra Loot never spawns it always says Extra loot chance failed is there a way to up the chances ?

Thanks

MegaZ

The AI are despawning because :

waitUntil 
	{
	(!EPOCH_MISSION3_RUNNING)
	};

As you can see in the example above (excerpt from FAI) they wait to get deleted until this variable is set.Look for:

 EPOCH_MISSION3_RUNNING = false;

and make sure it is not getting set too soon.

 

To adjust the extra loot chance percentage for your AI open FLoot for the appropriate type (Medic, Bandit, Sniper) and adjust the following:

_lootChance = .20;

to something higher like .50 or whatever percentage you want to use.

Link to comment
Share on other sites

EPOCH_MISSION3_RUNNING = false;

and make sure it is not getting set too soon.

 

Hi Foamsy thanks for the reply, I found this :

 

// Add some AI to patrol

sleep 1;

diag_log("MISSION 3

 

do I need to increase the sleep from 1 to longer if so what is the usual increase or is it trial and error ? A lot of the other sleep timers are set to.5 but to 10 once all AI have bee loaded: eg

 

sleep 10;

diag_log("MISSION 3: DeathWish - Loading -=FAI=- Completed");

 

thanks MegaZ

Link to comment
Share on other sites

EPOCH_MISSION3_RUNNING = false;

and make sure it is not getting set too soon.

 

Hi Foamsy thanks for the reply, I found this :

 

// Add some AI to patrol

sleep 1;

diag_log("MISSION 3

 

do I need to increase the sleep from 1 to longer if so what is the usual increase or is it trial and error ? A lot of the other sleep timers are set to.5 but to 10 once all AI have bee loaded: eg

 

sleep 10;

diag_log("MISSION 3: DeathWish - Loading -=FAI=- Completed");

 

thanks MegaZ

 

 

I need you to post the mission file in order to help you. I didn't write that script so I have no idea what's in it.

Link to comment
Share on other sites

Hi Foamy thanks for looking the mission was supplied from Snakeyes on here,

/*
File Name: FMission_M3_WellsFargo.sqf
File Created: 3/28/2014
File Version: 1.0
File Author: Snakeyes
File Last Edit Date: 3/28/2014
File Description: WellsFargo (M3)
Template by: Foamy
*/

// CHECK FOR ANOTHER MISSION 3 RUNNING START ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

if (isNil "EPOCH_MISSION3_RUNNING") then
{
EPOCH_MISSION3_RUNNING = false;
};

if (EPOCH_MISSION3_RUNNING) exitWith
{
diag_log("MISSION 3 already running");
};

// CHECK FOR ANOTHER MISSION 3 RUNNING END ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

// Don't forget to add all your "_names" to the private section
private ["_missionSpawnChance","_spawnMarker","_spawnRadius","_markerRadius","_markerColor","_item","_loot","_loot_lists","_loot_box","_wait_time","_spawnRoll","_position","_loot_pos","_loot_box","_textMarker_IconType","_markerText","_markerBrush","_base","_aiunit_spawn_pos","_aivehicle_spawn_pos","_aiheli_spawn_pos","_aiunit1","_aiunit2","_aiunit3","_aiunit4","_aiunit5","_aiunit6","_aiunit7","_attackgroup","_attacker1","_attacker2","_targetunitsAlive","_timeout"];

diag_log("MISSION 3: WellsFargo - Script Started");

_missionSpawnChance = .60; //Set Spawn Chance Here 1 = always
_spawnRoll = random 1;

diag_log("MISSION 3: WellsFargo - Checking MissionSpawnChance");
if (_spawnRoll > _missionSpawnChance) exitWith
{
diag_log format ["MISSION 3: WellsFargo - Failed with %1 it needed to be lower than %2",_spawnRoll,_missionSpawnChance];
};

sleep .5;
diag_log("MISSION 3: WellsFargo - Mission SpawnChance Success");

sleep .5;
diag_log("MISSION 3: WellsFargo - Mission Script Started");

EPOCH_MISSION3_RUNNING = true;

/*
// Edit Loot Box Contents Below
// Format is:
// 1st row = Weapons, Tools ( Compass, etc)
// 2nd row = Ammo, Food items etc
// 3rd row = Backpacks

The loot example in this template has 2 loadouts to choose from, you can add as many as you want. The more you add the more
variety you will have.
Each addition will use a block like this:
[
["DMR","NVGoggles","Binocular_Vector"],
["20Rnd_762x51_DMR","20Rnd_762x51_DMR","20Rnd_762x51_DMR","ItemSodaPepsi","ItemSodaR4z0r","ItemAntibiotic"],
["DZ_Backpack_EP1"]
], <---- The , is NOT needed on last loot block, see example below where the , is only used to separate the
first block from the second block. There is no , at the end of the second block as it is the last block in
the list.
*/

//---------------------------------------------------------------------------------

// Loot Box Setup
_loot_box = "GuerillaCacheBox";
_loot_lists = [
[
["M9SD","ItemMachete","Binocular"],
["15Rnd_9x19_M9SD","15Rnd_9x19_M9SD","15Rnd_9x19_M9SD","ItemGoldBar","ItemGoldBar","ItemGoldBar","ItemGoldBar","ItemGoldBar10oz","ItemGoldBar10oz"],
["DZ_CivilBackpack_EP1"]
],
[
["DMR","NVGoggles","Binocular_Vector"],
["20Rnd_762x51_DMR","20Rnd_762x51_DMR","20Rnd_762x51_DMR","ItemSodaMdew","ItemGoldBar10oz","ItemBriefcase100oz","ItemAntibiotic","ItemGoldBar10oz"],
["DZ_GunBag_EP1"]
],
[
["MP5SD","ItemFlashlightRed","ItemCompass"],
["30Rnd_9x19_MP5SD","30Rnd_9x19_MP5SD","30Rnd_9x19_MP5SD","ItemSodaMdew","ItemWire","ItemSilverBar10oz","ItemGoldBar10oz","ItemGoldBar10oz","ItemSilverBar10oz"],
["DZ_TerminalPack_EP1"]
],
[
["SVD_CAMO","ItemWatch","Binocular"],
["10Rnd_762x54_SVD","10Rnd_762x54_SVD","10Rnd_762x54_SVD","ItemSodaMdew","ItemBurlap","ItemGoldBar","ItemGoldBar","ItemGoldBar","ItemGoldBar10oz","ItemGoldBar10oz"],
["DZ_Backpack_EP1"]
],
[
["M4A1_AIM_SD_CAMO","ItemGPS","Binocular"],
["30Rnd_556x45_StanagSD","30Rnd_556x45_StanagSD","30Rnd_556x45_StanagSD","ItemSodaRbull","ItemGoldBar10oz","ItemGoldBar10oz","ItemGoldBar10oz","ItemGoldBar10oz"],
["DZ_ALICE_Pack_EP1"]
]
];

//---------------------------------------------------------------------------------

_loot = _loot_lists call BIS_fnc_selectRandom;

// Mission Variables
mission_despawn_timer = 1800; // This sets the Timeout if a timer is used.
_wait_time = 900; // This is how long the loot box will stay once it spawns.
_spawnRadius = 5000; // This is the distance from Center - Used to determine the radius in which missions will spawn
_spawnMarker = 'center'; // DO NOT Change this, UNLESS you need a hard coded center loc for custom purposes
_markerRadius = 350; // This sets marker radius and the area the loot can spawn in
_markerColor = "ColorBlue"; // This sets the Marker Color
_textMarker_IconType = "mil_objective"; // This sets the "Icon Type" (https://community.bi...wiki/cfgMarkers)
_markerText = "Mission: Wells Fargo Transport"; // Text to display at Marker (Leave "" blank if you dont want a message)
_markerBrush = "SOLID"; // Marker Brush - How the marker is filled in

// This sets the global position coords the mission needs to run, do not change.
_position = [getMarkerPos _spawnMarker,0,_spawnRadius,10,0,20,0] call BIS_fnc_findSafePos;
_loot_pos = [_position,0,(_markerRadius - 100),10,0,20,0] call BIS_fnc_findSafePos;

// Use these if using AI, Vehicles or Helis
_aiunit_spawn_pos = [_loot_pos, 30, 50, 30, 0, 20, 0] call BIS_fnc_findSafePos;
_aivehicle_spawn_pos = [_loot_pos, 30, 50, 30, 0, 20, 0] call BIS_fnc_findSafePos;
_aiheli_spawn_pos = [_loot_pos, 30, 50, 30, 0, 20, 0] call BIS_fnc_findSafePos;

//---------------------------------------------------------------------------------
// Mission Body STARTS Here
// Read General Script Instructions for Variable Usage per script.

// Add a Marker? Make sure to use FMarker3.sqf for M3 Missions
[_position,_loot_pos,_markerRadius,_markerColor,false,_textMarker_IconType,_markerText,_markerBrush] execVM "\z\addons\dayz_server\addons\FMission\FMarker\FMarker3.sqf";

// Add a base?
_base = createVehicle ["Land_fortified_nest_big",_loot_pos,[], 0, "CAN_COLLIDE"];
_base setPos _loot_pos;

// Add some AI to patrol?
sleep 1;

diag_log("MISSION 3: WellsFargo - Loading -=FAI Units=- Started");

_aiunit1 = [_aiunit_spawn_pos,50,4,"Bandit",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit2 = [_aiunit_spawn_pos,50,4,"Bandit",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit3 = [_aiunit_spawn_pos,50,4,"Sniper",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit4 = [_aiunit_spawn_pos,50,4,"Medic",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit5 = [_aiunit_spawn_pos,50,4,"Sniper",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit6 = [_aiunit_spawn_pos,50,4,"Bandit",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit7 = [_aiunit_spawn_pos,50,4,"Bandit",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit8 = [_aiunit_spawn_pos,50,4,"Sniper",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit9 = [_aiunit_spawn_pos,50,4,"Sniper",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit10 = [_aiunit_spawn_pos,50,4,"Sniper",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

_aiunit11 = [_aiunit_spawn_pos,50,4,"Bandit",_loot_pos,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf";

sleep 10;
diag_log("MISSION 3: WellsFargo - Loading -=FAI=- Completed");

sleep .5;

// Add a one off custom AI?
_attackgroup = createGroup east;

_attacker1 = _attackgroup createUnit ["TK_INS_Soldier_3_EP1", _base, [], 0, "Form"];
_attacker1 setUnitPos "AUTO";
[_attacker1] execVM "\z\addons\dayz_server\addons\FMission\FLoot\FLoot_Bandit.sqf";
_attacker1 setUnitPos "Middle";

_attacker2 = _attackgroup createUnit ["TK_Soldier_Medic_EP1", _base, [], 0, "Form"];
_attacker2 setUnitPos "AUTO";
_null = [_attacker2] execVM "\z\addons\dayz_server\addons\FMission\FLoot\FLoot_Medic.sqf";
_attacker2 setUnitPos "Middle";

_attackgroup setCombatMode "RED";
_attackgroup setBehaviour "STEALTH";

// Add a Heli Patrol?
_aiHeli = [_aiheli_spawn_pos,_loot_pos,250,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Heli.sqf";

// Add a Vehicle patrols?
_aiVehicle = [_aivehicle_spawn_pos,_loot_pos,100,"M1"] execVM "\z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Vehicle.sqf";

[nil,nil,rTitleText,"MISSION: WellsFargo - A Wells Fargo Transport has crashed. Hurry there now to secure the location!", "PLAIN",10] call RE;

diag_log("MISSION 3: WellsFargo - Waiting...");
_timeout = time + mission_despawn_timer;
waitUntil
{
_targetunitsAlive = {alive _x} count (units _targetgroup);
((time > _timeout) || (_targetunitsAlive < 1))
};

_targetunitsAlive = {alive _x} count (units _targetgroup);
if (_targetunitsAlive < 1) then
{
[nil,nil,rTitleText,"MISSION: Survivors have captured the Wells Fargo Transport cargo and eliminated the Bandits, Good Job.", "PLAIN",10] call RE;

// Create a loot box?
// Create loot box
diag_log("MISSION 3: WellsFargo - Creating loot box");
_loot_box = createVehicle [_loot_box,_loot_pos,[], 0, "NONE"];
_loot_box setPos _loot_pos;
clearMagazineCargoGlobal _loot_box;
clearWeaponCargoGlobal _loot_box;
clearBackpackCargoGlobal _loot_box;

// Add loot
diag_log("MISSION 3: WellsFargo - Loot box created, adding loot to loot box");
{
_loot_box addWeaponCargoGlobal [_x,1];
} forEach (_loot select 0);
{
_loot_box addMagazineCargoGlobal [_x,1];
} forEach (_loot select 1);
{
_loot_box addBackpackCargoGlobal [_x,1];
} forEach (_loot select 2);

// Wait for awhile so loot can be collected?
sleep _wait_time;

// Mission Body ENDS here
// ---------------------------------------------------------------------------------

// Add additional deleteVehicle _xxx; for each item that needs to be deleted.
// Add additional deleteVehicle _xxgroup; to delete the AI units
// Clean up
EPOCH_MISSION3_RUNNING = false;

deleteVehicle _base;
deleteVehicle _loot_box;
{ deleteVehicle _x } forEach units _targetgroup;
deleteGroup _targetgroup;
{ deleteVehicle _x } forEach units _attackgroup;
deleteGroup _attackgroup;

diag_log("MISSION 3: WellsFargo - Script Finished");
}
else
{
[nil,nil,rTitleText,"MISSION: Mission Failed", "PLAIN",10] call RE;

// Clean up
EPOCH_MISSION3_RUNNING = false;

deleteVehicle _base;
{ deleteVehicle _x } forEach units _attackgroup;
deleteGroup _attackgroup;

diag_log("MISSION 3: WellsFargo - Script Finished");
};

 

Thing is with these missions is that some times it will run and spawn the AI, But most of the time with the units being deleted.

thanks

MegaZ

Link to comment
Share on other sites

I found a couple things wrong.

_targetunitsAlive = {alive _x} count (units _targetgroup);
if (_targetunitsAlive < 1) then

1) It is looking for _targetgroup to check mission completion status however your group is called _attackgroup so change the targetgroup to attackgroup.

 

2) Remove the reference to _targetgroup in the Clean up section at the bottom in the first if statement so it looks like this

// Clean up
EPOCH_MISSION3_RUNNING = false;
deleteVehicle _base;
deleteVehicle _loot_box;
{ deleteVehicle _x } forEach units _attackgroup;
deleteGroup _attackgroup;
diag_log("MISSION 3: WellsFargo - Script Finished");
}
else
{
[nil,nil,rTitleText,"MISSION: Mission Failed", "PLAIN",10] call RE;
// Clean up
EPOCH_MISSION3_RUNNING = false;
deleteVehicle _base;
{ deleteVehicle _x } forEach units _attackgroup;
deleteGroup _attackgroup;
diag_log("MISSION 3: WellsFargo - Script Finished");
}; 

3) Look at all the ai (units, vehicle and heli) calls... they are set to M1, yet you are using an M3 template. Change all M1's to M3's and that should be it.

Link to comment
Share on other sites

Hi at all.

 

Just installed FMission on an Epoch Napf Server 1.0.4.2a.

 

But I got the following error:

 

22:03:07 "RUNNING EVENT: FMission_Launcher1 on [2014,5,11,6,3]"

22:03:07 "FMission Launcher 1: Checking Spawn Chance"

22:03:07 "FMission Launcher 1: Spawn Chance succeeded with 0.63689 it needed to be lower than 1"

22:03:07 "FMission Launcher 1: Selecting script and launching

22:03:07 "FMission Launche 1: Launching Mission: \z\addons\dayz_server\addons\Fmission\Missions\M1\Foamy\FMission_M1_Assassination.sqf"

22:03:07 Warning Message: Script z\addons\dayz_Server\addons\Fmission\Missions\M1\Foamy\FMission_M1_Assassination.sqf not found

 

I checked the folder. The file is on its place.

 

But why there is this error code???

Any suggestions?

Thanks

N8hawk
 

Link to comment
Share on other sites

I found a couple things wrong.

1) It is looking for _targetgroup to check mission completion status however your group is called _attackgroup so change the targetgroup to attackgroup.

2) Remove the reference to _targetgroup in the Clean up section at the bottom in the first if statement so it looks like this

3) Look at all the ai (units, vehicle and heli) calls... they are set to M1, yet you are using an M3 template. Change all M1's to M3's and that should be it.

 Hi Foamy 

Thanks this is what I was missing have changed as per instructions and all works like a charm Thanks again

MegaZ

Link to comment
Share on other sites

Hi at all.

 

Just installed FMission on an Epoch Napf Server 1.0.4.2a.

 

But I got the following error:

 

22:03:07 "RUNNING EVENT: FMission_Launcher1 on [2014,5,11,6,3]"

22:03:07 "FMission Launcher 1: Checking Spawn Chance"

22:03:07 "FMission Launcher 1: Spawn Chance succeeded with 0.63689 it needed to be lower than 1"

22:03:07 "FMission Launcher 1: Selecting script and launching

22:03:07 "FMission Launche 1: Launching Mission: \z\addons\dayz_server\addons\Fmission\Missions\M1\Foamy\FMission_M1_Assassination.sqf"

22:03:07 Warning Message: Script z\addons\dayz_Server\addons\Fmission\Missions\M1\Foamy\FMission_M1_Assassination.sqf not found

 

I checked the folder. The file is on its place.

 

But why there is this error code???

Any suggestions?

Thanks

N8hawk

 

Hi What Server Provider are you using?

My files are as this:

\z\addons\dayz_server\addons\Fmission\Missions\M3\FMission_M3_Wells Fargo.sqf"

 

Mine looks like this and works fine. Unpack dayz_server.pbo and I have this folder structure below:

 

f_missions_folder.png

upload imagem

Link to comment
Share on other sites

Hi again everybody!

Sorry. I am just a fool! ,-)

I don't know why, but I didn't recognized that I have to add the "addons" folder to the dayz_server.pbo!

No the missions spawn!!

THANK YOU FOR SCRIPTING FMission!

Cu later

N8hawk

Link to comment
Share on other sites

Being too lazy to define a bunch of units, I decided to use a for loop.  Setting it up this way, you can just tell a mission how many units you want to have and it will pick a random class and patrol radius for each.  I also set it up to call findSafePos for each unit so they will not all spawn at the same location.  You can do the same thing for vehicles and helis.

 

_groundUnitCount = 10;

 

 for "_i" from 1 to _groundUnitCount step 1 do
 {
             _class = ["Bandit", "Sniper", "Medic"] call BIS_fnc_selectRandom;
             _aiunit_spawn_pos = [_loot_pos, 10, 100, 10, 0, 20, 0] call BIS_fnc_findSafePos;
             _distance = random 100;
            [_aiunit_spawn_pos,_distance,4,_class,_loot_pos,"M1"] execVM "dayz_server\FMission\FAI\FAI_Create_Unit.sqf";
 };
Link to comment
Share on other sites

  • 2 weeks later...

couple of questions:

 

why does the mission marker stays on when completing the hostage mission?

 

and my second question is can I make one mission static in one location or does it have to be random?

 

thanks

Link to comment
Share on other sites

couple of questions:

 

why does the mission marker stays on when completing the hostage mission?

 

and my second question is can I make one mission static in one location or does it have to be random?

 

thanks

When the lootbox despawns the marker does as well. Wehn you "complete" Hostage Rescue, the loot box spawns and stays up for about 15 mins. 

 

You can set a static loc by setting a static coord.

Link to comment
Share on other sites

When the lootbox despawns the marker does as well. Wehn you "complete" Hostage Rescue, the loot box spawns and stays up for about 15 mins. 

 

You can set a static loc by setting a static coord.

 

my question is how to do it?

 

this is the location of my character where i abored : [64,[4627,16680.1,0.002]]

 

 

Do I just change this :

 

// This sets the global position coords the mission needs to run, do not change.
_position = [getMarkerPos _spawnMarker,0,_spawnRadius,10,0,20,0] call BIS_fnc_findSafePos;
_loot_pos = [_position,0,(_markerRadius - 100),10,0,20,0] call BIS_fnc_findSafePos;
 
to this:
 
_position = [64,[4627,16680.1,0.002]];
_loot_pos = [_position,0,(_markerRadius - 100),10,0,20,0] call BIS_fnc_findSafePos;
 
Thanks in advance
Link to comment
Share on other sites

hey guys im having trouble getting this to work, i put everything in the right folder and im getting an error saying

17:20:00 "RUNNING EVENT: FMission_Launcher1 on [2014,5,28,17,20]"
17:20:00 Warning Message: Script z\addons\dayz_server\modules\FMission_Launcher1.sqf not found
17:20:00 "RUNNING EVENT: FMission_Launcher2 on [2014,5,28,17,20]"
17:20:00 Warning Message: Script z\addons\dayz_server\modules\FMission_Launcher2.sqf not found
17:20:00 "RUNNING EVENT: FMission_Launcher3 on [2014,5,28,17,20]"
17:20:00 Warning Message: Script z\addons\dayz_server\modules\FMission_Launcher3.sqf not found

 

i double checked the folder and repacked it 3 times along with 3 separate restarts on the server, and nothing

Im running on Dayz Epoch 1.0.4.2 Napf map

 

Also i am hosting off of my own rig atm so the only file i need to repack is the dayz_server.pbo

and I am also using PBO manager

 

*SOLVED*

Link to comment
Share on other sites

 

my question is how to do it?

 

this is the location of my character where i abored : [64,[4627,16680.1,0.002]]

 

 

Do I just change this :

 

// This sets the global position coords the mission needs to run, do not change.
_position = [getMarkerPos _spawnMarker,0,_spawnRadius,10,0,20,0] call BIS_fnc_findSafePos;
_loot_pos = [_position,0,(_markerRadius - 100),10,0,20,0] call BIS_fnc_findSafePos;
 
to this:
 
_position = [64,[4627,16680.1,0.002]];
_loot_pos = [_position,0,(_markerRadius - 100),10,0,20,0] call BIS_fnc_findSafePos;
 
Thanks in advance

 

_position = [xxxx.xxxx, xxxx.xxxx];
Link to comment
Share on other sites

Hey Foamy, I'm getting undefined variable errors with Fmission using the latest beta 112555 and the dev branch beta 124802.

17:10:04 "FMission Launcher 1: Spawn Chance Succeeded with 0.279454 it needed to be lower than 0.7"
17:10:04 Error in expression <ion_type == "M1") then
{
waitUntil 
{
(!EPOCH_MISSION1_RUNNING)
};
{ deleteVehic>
17:10:04   Error position: <EPOCH_MISSION1_RUNNING)
};
{ deleteVehic>
17:10:04   Error Undefined variable in expression: epoch_mission1_running
17:10:04 File z\addons\dayz_server\addons\FMission\FAI\FAI_Create_Unit.sqf, line 178

These happen with FAI_Create_Unit.sqf, FAI_Create_Heli.sqf and FAI_Create_Vehicle.sqf

 

Errors fill the RPT file when a mission runs.

 

Got a fix? :)

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
×
×
  • Create New...