Jump to content
Sign in to follow this  
Pappy60

tasks not updating for all players on MP

Recommended Posts

I am assuming I am doing something wrong in the briefing as the tasks are listed properly and do update for the player that completes the task, but does not update for other players, JIP or not. I need the tasks to update for all players when one of the players completes the task...is this in the briefing or somewhere else ?

Here is my current briefing:

// A2BM W     110
// DO NOT EDIT THIS FILE

waitUntil {!(isNull player)};
waitUntil {player==player};
switch (side player) do
{
case WEST:
{
player createDiaryRecord ["Diary",["1","<br/> Welcome to Pappy's Helo Training Server<br/><br/> I put this up for training pilots flying helos. This particular mission is about transport helos and the tasks are based on either insertion or extraction. The tasks start out easy and get progressivly harder. As the tasks progress the flights get more difficult and there is more pressure on the pilot as the LZ's become hot and time becomes a factor.<br/><br/> Server rules: NO TEAM KILLING! & Be HELPFUL! others are here to learn<br/><br/> ONE PILOT PER HELO ONLY ! these are training missions based on crew count, adding another player will result in consistent task failure. <br/><br/>These missions are for training so the helos do respawn at the base and unattended helos off base will respawn at the base. Spawn on crashes is 15 seconds for both player and helo, spawn on unattended is 120 seconds. <br/><br/>All missions are based on flying the UH-1 helos either Jolly61 or Jolly62, if you join the game and either UH-1 is missing, then grab a cobra and fly cover for the UH-1 .    "]];


tskObj_4=player createSimpleTask ["Extract Fireteam Razor"];
tskObj_4 setSimpleTaskDescription ["<br/> Your mission is to use one of the MH-60s helos (Jolly61 or Jolly62), fly to 078022 and extract Fireteam Razor2 then fly back to your takeoff pad at the airport . <br/>Take a heading NNE 50 degrees from the airport, when you get in range Razor2 will contact you on the radio. <br/><br/> The LZ is tight, make sure you put down very close to the fireteam and make sure your helo is providing cover for the fireteam, most of the enemy fire is coming from the northern side of the clearing. <br/>Important! after you land at the LZ wait for Razor2 to radio you that all units are onboard before you lift off. If a member has died and cannot get onboard, the task has failed!<br/>
This task is for experienced pilots, a good pilot can get in and out with all passengers alive and zero damage to the helicopter. No waypoints or markers are used, Pilot must fly on headings and coordinates. Time is critical, the longer you take in the hot zone the more damage your helo takes. 
<BR/> <BR/> NOTE: HEADINGS ARE BASED ON TASKS FLOWN IN ORDER!<BR/><BR/>
<br/> Task skill level: Difficult
<br/>
<br/> Success is determined by a fast extraction with all players alive and returned to the airport.  <br/>  <br/>Pappy<br/><br/>","Extract Fireteam Razor2","Extract Fireteam Razor"];



tskObj_3=player createSimpleTask ["Dr Smith "];
tskObj_3 setSimpleTaskDescription ["<br/>  When you drop off Sniper1 at the Airport Field Hospital you will pickup Dr Smith a civilian doctor, he needs to be transported to our Gorka Field Hospital on the north side of Gorka at GPS coordinate 063095 on a heading of 105 degrees ESE . Be carefu, intel reports hostile fire just north of the Gorka Field Hospital, you will need to get in and out quickly<br/> <br/>   This task is for student pilots with enemy fire added into the mix. 
<BR/> <BR/> NOTE: HEADINGS ARE BASED ON TASKS FLOWN IN ORDER!<BR/><BR/>
<br/> <br/> Task skill level: Mildly difficult
<br/>
<br/> Success is determined by following orders, arriving at appropriate coordinates and not crashing.  <br/>  <br/>Pappy<br/><br/>","Dr Smith","Dr Smith"];



tskObj_2=player createSimpleTask ["Dustoff Sniper1 "];
tskObj_2 setSimpleTaskDescription ["<br/>  The LZ's in this task are not visible Rescue LZ's and have no visible markers, you need to fly and land stricly by coordinates. Sniper1 is injured and needs a Dustoff or Medevac run. Find him, land and pick him up, then take him to the field hospital on the far west side of the airport. Success will not be hard if you follow your compass bearing and use GPRS coordinates in this briefing. <br/> You will receive mission orders on the fly via radio and need to be prepared to change priorities. <br/> <br/>   This task is for student pilots, coordinates are fly due north at 05 degrees from Novy Sobor insertion, to GPS 069040, sniper1 will be waiting near the front of Devils Castle . 
<BR/> <BR/> NOTE: HEADINGS ARE BASED ON TASKS FLOWN IN ORDER!<BR/><BR/>
<br/> <br/> Task skill level: Mildly difficult
<br/>
<br/> Success is determined by following orders, arriving at appropriate coordinates and not crashing.  <br/>  <br/>Pappy<br/><br/>","Dustoff Sniper1","Dustoff Sniper1"];



tskObj_1=player createSimpleTask ["Extract Fireteam Vector"];
tskObj_1 setSimpleTaskDescription ["<br/> This is an easy mission with no enemy fire, the objective is to get beginning pilots to fly without waypoints using compass bearings and GPS coordinates. The LZ's in this task are visible Rescue LZ's and are easy to spot if you follow your compass bearing and use GPRS coordinates in this briefing. <br/> You will receive mission orders on the fly via radio and need to be prepared to change priorities. <br/> <br/> Start out with a compass heading of 157 degrees and head to GPS coordinate 080059, pickup Fireteam Vector and return to the airport unless other orders are received.  This task is for student pilots, markers are provided but students should avoid using markers and rely on bearings and coordinates. 
<BR/> <BR/> NOTE: HEADINGS ARE BASED ON TASKS FLOWN IN ORDER!<BR/><BR/>
<br/> Task skill level: Easy
<br/>
<br/> Success is determined by following orders, arriving at appropriate coordinates and not crashing.  <br/>  <br/>Pappy<br/><br/>","Extract Fireteam Vector","Extract Fireteam Vector"];
};
case EAST:
{
};
case RESISTANCE:
{
};
case CIVILIAN:
{
};
};

Share this post


Link to post
Share on other sites

It's not in the briefing i guess. Could you explain how you complete the tasks? (Via script or trigger or whatever...)

Share this post


Link to post
Share on other sites

all objectives are completed by triggers, no scripts.

Share this post


Link to post
Share on other sites

Does that trigger condition have "player" in it?

Share this post


Link to post
Share on other sites

no, the triggers are based on helo presence and count of crew.....should they have the player in the condition?

Share this post


Link to post
Share on other sites

a typical trigger condition is:

Jolly61 in thisList && getpos Jolly61 select 2 < 2 and vector in (thislist select 0)

and activation :

tskobj_1 settaskstate "SUCCEEDED"; null = [objnull, objnull, tskobj_1, "SUCCEEDED"] execVM "CA\Modules\MP\data\scriptCommands\taskHint.sqf"; hint "Objective Complete! Vector Inserted!"; player setcurrenttask tskobj_2; {_x action ["GETOUT", vehicle _x]; unassignVehicle _x;} forEach (units vector); Jolly61 vehicleRadio "radioMsg2"; jolly61 vehicleradio "RadioMsg6";

and the task will update for the player that completed the objective/task but it will not show completed in the briefing for the other players......

Share this post


Link to post
Share on other sites

I have the same problem, but more confusing.

3 objectives, that are listed (generated) in the briefing, only "work fully" for the player completing it.

2 objectives, that are generated by triggers within the mission, work fully and "globally". All players get the task success and the green light on map/tasks, etc. I was thinking publicVariable might have an effect so it looks like this:

"4" objStatus "DONE"; tskObj4 setTaskState "SUCCEEDED"; null = [objNull, ObjNull, tskObj4, "SUCCEEDED"] execVM "CA\Modules\MP\data\scriptCommands\taskHint.sqf"; Obj4 = true; publicVariable "0";

I have the identical text for another tskObj# and it doesn't "work for all players".

The only thing I noticed is the one's that Dont get the "green light" for all players, are the ones listed in the briefing.

Is there a code I use to mark the briefing documents' tasks, as complete, and then JIP people would also see it has completed a task or 2?

Thanks,

Jack_Ryan

Share this post


Link to post
Share on other sites
"4" objStatus "DONE";

That does nothing in Arma 2.

publicVariable "0";

You are supposed to use a variable you want to pubvar.

----------------

One way to handle task update is to use a double trigger method.

Each task will have a trigger with the condition for the objective like:

!alive someDude

The onAct of that trigger would be:

obj1 = true; publicvariable "obj1";

Second trigger would be:

cond: obj1

onact: tskObj1 setTaskState "SUCCEEDED"; null = [objNull, ObjNull, tskObj1, "SUCCEEDED"] execVM "CA\Modules\MP\data\scriptCommands\taskHint.sq f";

That makes it so that when JIP connects, the variables which were pubvar'd from the first triggers are synced to the player and will fire the second triggers, updating tasks.

Share this post


Link to post
Share on other sites

Thanks shk, I thought maybe the "0" for PubVar was on/off, true/false, I had only seen it in some posts and thought I could use it.

So to clarify, whatever i put in " Obj4= true;" gets echo'd in " publicVariable "Obj4";

If i use the terminology ' tskObj1 tskObj2 etc " to define the tasks, do I always the usethe full ' tskObj# ' in other references? I notice alot are simply obj3, or even a unique name. Like yours shows obj1 and tskObj1 referencing the same.

I'll try switching them to double trigger method, Thanks again.

Jack

Share this post


Link to post
Share on other sites

obj1 is just a true/false that is used in triggers (like a temp variable to fire the actual task trigger)

tskObj1 is the actual task that will be updated

Yes, whatever is in the variable (Obj4 in your example) will be synced with publicvariable "Obj4".

Share this post


Link to post
Share on other sites

Thanks, shk. I have been confused about publicvariables, tskObj0, Obj1, OR WHATEVER !, LOL, now I switched to the 2 trigger method, and got my peanut around the = true part, and my mission works fully. phew

Hi5 to the community for this resource.

Jack

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×