Jump to content
  • 0

Problem with Wicked AI


demarotu

Question

At first i believed that it was not spawning any loot, until i realized it was not even reading the mission being complete at all, here is a sample of the default files being used, wondering if i was suppose to change something or if i messed it up at all.

 

if(isServer) then {
 
private ["_complete","_crate_type","_mission","_position","_crate","_baserunover","_baserunover1","_baserunover2"];
 
_position = [30] call find_position;
_mission = [_position,"Easy","Medical Supply Camp","MainHero",true] call mission_init;
 
diag_log format["WAI: [Mission:[Hero] Medical Supply Camp]: Starting... %1",_position];
 
//Setup the crate
_crate_type = crates_small call BIS_fnc_selectRandom;
_crate = createVehicle [_crate_type,[(_position select 0) + 15,(_position select 1) + 5,0], [], 0, "CAN_COLLIDE"];
 
//Medical Supply Camp
_baserunover1 = createVehicle ["Land_fortified_nest_big",[(_position select 0) +15, (_position select 1) -20,0],[], 0, "CAN_COLLIDE"];
_baserunover2 = createVehicle ["Land_Fort_Watchtower",[(_position select 0) +25, (_position select 1) +10,0],[], 0, "CAN_COLLIDE"];
_baserunover = [_baserunover1,_baserunover2];
 
{ _x setVectorUp surfaceNormal position  _x; } count _baserunover;
 
//Troops
[[_position select 0,_position select 1,0],4,"Easy","Random",4,"Random","Bandit","Random","Bandit",_mission] call spawn_group;
[[_position select 0,_position select 1,0],4,"Easy","Random",4,"Random","Bandit","Random","Bandit",_mission] call spawn_group;
 
//Condition
_complete = [
[_mission,_crate], // mission number and crate
["kill"], // ["crate"], or ["kill"], or ["assassinate", _unitGroup],
[_baserunover], // cleanup objects
"Bandits have taken over a medical re-supply camp! Check your map for the location!", // mission announcement
"Survivors have taken control of the medical supply camp!", // mission success
"Survivors were unable to capture the medical supply camp" // mission fail
] call mission_winorfail;
 
if(_complete) then {
[_crate,0,0,[70,crate_items_medical],0] call dynamic_crate;
};
 
diag_log format["WAI: [Mission:[Hero] Medical Supply Camp]: Ended at %1",_position];
 
h_missionrunning = false;
Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...