Hard Light Productions Forums
Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: sgtbeil on July 24, 2008, 11:49:49 pm
-
well the title says it all
-
Well what are you trying to do? Did you do the walk trough? Open a mission that you know has directives that work and take a look at how it's done.
-
well the walkthrough isnt that clear, im sure i did everything correct and i dont have any other missions that have directives
-
Well, I'll see if I can clear it up a little. As a general rule (with tons of exceptions but let us ignore those for now), for a directive to appear two things must be true: The event for it needs to have the directive text attached (it'll be marked with a red ball instead of the normal blue if it does), and the condition on the event must be achievable by the player at the point in the mission where the directive is to appear.
For example, you want a directive to destroy Gemini wing. To do this, you first make an event and type "Destroy Gemini" into the text box marked "Directive text" which is located just below the tree view in the event editor. Secondly, instead of the default "true" condition for the event, you set it to "is-destroyed-delay" and select Gemini wing as the target, which will then look like this:
* Gemini Objective
- op when
- op is-destroyed-delay
# 0
# Gemini
- op do-nothing
With an even like this, upon the arrival of Gemini wing, the directive will appear, and upon it's destruction, the directive will become completed. The directive will not appear until the wing does, as it is not possible for the player to achieve it before then.
-
thanks shade but another thing i dont really understand is how to make one of my directives appear when a ship does. i checked invalid objective in the mission objective editor and validated it in the events editor and it is always visible
-
Sgtbeil, i would be happy to create a small mission from which you can look through the mission, play it and find out how a mission works, at least the basics. it would save everyone a lot of time for all concerned.
-
alright go for it, like i need to know how to make directives appear as a ship does, how to make ships fire beams stuff like that
-
it sounds to me like you dont want any help. so be it, unless i misunderstood? :).
-
thanks shade but another thing i dont really understand is how to make one of my directives appear when a ship does. i checked invalid objective in the mission objective editor and validated it in the events editor and it is always visible
You are confusing directives and objectives. They are not the same thing.
Directives are the instructions that appear on the left side of the screen, and these are exclusively done within the events editor as explained earlier. Objectives are the main goals of the mission which are displayed on the last page of the briefing and which give you a small "goal completed" popup when you succeed at them, and these are when you were making changes to in the objectives editor. What the "invalid objective" tickbox does is simply make it not appear in the briefing so that it may be used as a surprise for the player.
-
thanks shade but another thing i dont really understand is how to make one of my directives appear when a ship does. i checked invalid objective in the mission objective editor and validated it in the events editor and it is always visible
Now that is an interesting question.
1) Never confuse Objectives (goals) and Directives. Directives appear at the side of the screen. Goals appear when you press F4 or at the start of the mission. They are completely separate things with no connection between them. You can of course make a goal and a directive to destroy a certain ship if you wish but they are still different things.
2) My FAQ has a long, detailed explanation of what invalid objective actually does here (http://homepage.ntlworld.com/karajorma/FAQ/fredretail.html#events). It's a very useful feature and I recommend all FREDders learn but it's nothing to do with what you're trying to do.
3) Making a directive appear relies on certain things. Several SEXPs automatically have an effect on when a directive using them appears. For instance is-destroyed-delay will cause any directive using it not to appear unless the ship(s) in question is already present in the mission. is-event-true will cause the Directive not to appear until the event is true (unless you add the 3rd optional argument in which case you can choose what to do).
An old rule of thumb was to do this
Event 1 (Make Directive Appear)
When
-Conditions that come true when you want the directive to appear
-do-nothing
Event 2 (Directive - Chained to event 1)
When
-Conditions that determine if you actually achieve the directive.
Due to the chain the directive can't appear until Event 1 has triggered. This method is slowly falling out of favour with some FREDders (like myself) as it is somewhat cumbersome but it does work well and is easily understandable by new FREDders.
-
thanks that really helped but i still dont know how to make capital ships use their beam cannons
-
Something I found by clicking a link in a FRED article on Kara's FAQ (http://home.att.net/~clay.h/fs2/beamfaq.htm).
-
thx i must have missed that