OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: ACtrigger on 22 Sep 2002, 16:17:42
-
I have created a mission where you get picked up from a base, then assault another one. I have created the briefing and it works fairly well, but I don't want the 2nd objective to show untill I reach a certain point during the mission. HOW?
-
Checkout snYpir's tutorial "How to use Objectives and init.sqs" in Getting Started in the Editor's Depot .... I'd answer myself but I can't remember the syntax. It's all dead easy anyway.
-
In a units int, or in an init.sqs put;
2 Objstatus "hidden"
This will hide the objective at the start of the mission.
Then use
2 Objstatus "active"
so show it later in the mission.
-
In a trigger that is true at the start of the mission I have made the objective hidden but it appears in the opening briefing before the mission starts. If you put it in a units init. will it be invisable at the starting briefing?
-
hmm, dunno. try it
if you put it in init.sqs it won't appear in the briefing.
-
I'm not to good at scripting, could you gimmie a link to snYpirs tutorial?
-
The scripting part is a piece of cake ... and if you get stuck, just ask
Click on Editors Depot at the top of this screen
Once you're in the Ed depot click on "Getting Started" under Tutorials on the left hand side
Its about 2/3 of the way down the list.
There are loads of other good tutorials there too.
-
[attachment deleted by admin]
-
I think you have gotten a superfluous underscore in there :-X
-
Ok answering some questions in a polite manner as told to by my OFPEC parole officer.
The Init.sqs is just like any other script except that it is automatically called before the mission. You do not need to call in, it does it itself. Much like the init field of a unit, these changes happen before the mission starts, before the briefing shows.
All you need do to make an init.sqs is make a new text file in your flashpoint mission folder and type whatever commands you want in it. If you really want, you could take all the init commands youve put into the units and put them in this sqs (though you would need to use names and not "this").
Triggers on the other hand, are not activated until the mission has started. Infact it takes them a few tenths of a second before they are activated. Which is why you might see a flash of your character before a trigger activated intro.
So there you have it, init.sqs good, triggers bad. Init fields are exactly the same (but without a script and not very well organized).
-
I tried this but the objectives still show at the beggining where you see the mission briefing before the mission starts.
:help:
-
Just noticed the typo in Icarus' post.
2 Objstatus "hidden" <--- wrong
"2" Objstatus "hidden" <--- right
"2" Objstatus "active"
-
Cheers, that worked. (not being sarcastic even though it sounds like it)