OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: satexas69 on 18 Mar 2007, 09:59:01

Title: Objectives - Showing the next (obj2) only after the previous is done (obj1)
Post by: satexas69 on 18 Mar 2007, 09:59:01
I have a map with many objectives.

For example:  Obj1 --> Obj9

How can I "hide" them in the notes or mission briefing (as they're listed in the Briefing.html) and only SHOW them when the previous is done?

IE, once OBJ1 completes (=true), then show OBJ2 in the notes and display it's marker?

Is that even possible?
Title: Re: Objectives - Showing the next (obj2) only after the previous is done (obj1)
Post by: sharkattack on 18 Mar 2007, 10:20:58
"2" ObjStatus "HIDDEN" in init sqs
then when you want to reveal it
"2" objStatus "ACTIVE"

also for markers

markername  SetMarkerType to "empty" in init then.. again when you want to reveal it SetMarkerType to"flag"
havnt tried it myself  but thats how it was done in ofp..
Title: Re: Objectives - Showing the next (obj2) only after the previous is done (obj1)
Post by: Cheetah on 18 Mar 2007, 10:35:26
Let's say you've a trigger named trigger_obj2.

In the init.sqs:
"trigger_obj2" setMarkerType "empty";

When you want to activate the marker:
"trigger_obj2" setMarkerType "MarkerType";
Here the marker type can be any from the list, like arrow - flag - flag1 - dot. Depends on your preferance.

Don't think that you can actually hide stuff active in the briefing / notes. What you can do is to create a special section, with the following code in the briefing:

Code: [Select]
<hr>
<hr>
<h2><a name="obj2"></a>Objective 2<br></h2>
<h4>
Blablablabla text text text, the officer might be at mapgrid Ef67
</h4>

Most of the times I put this code after the objectives section in the briefing, so that's between the objectives part and the end of the html document.

Now, in the objectives part you do the following:
<p><a name = "OBJ_1"></a>Kill comrade Mantov</a></p>
<hr>
<p><a name = "OBJ_2"></a>Find the other officer. <a href="#obj2">More information</a></a></p>
<hr>

If you want to make things even more "perfect", I suggest that you give out a little hint to the player that his objectives have been updated. So in the trigger, or script whatever you use to detect if the objective has been completed:
hint "Objectives Updated";

Good luck.
Title: Re: Objectives - Showing the next (obj2) only after the previous is done (obj1)
Post by: LeeHunt on 19 Mar 2007, 18:37:27
You should also download Chris's Script Editor:

http://www.ofpec.com/ed_depot/tools.php

It can create perfect briefings for Armed Assault, EXTREMELY useful resource.