Troubleshooting Common FREDding Mistakes

One of the biggest problems new FREDders face is how to solve problems with their mission just isn't working. Debugging a mission is about as much an art as learning how to create missions in the first place.

Some bugs however are very common. In order to help you, here are some of the bugs you might encounter along your way.

Directives don't appear at the right time

This one has stumped many FREDders over the years. Directives might appear either too early (generally right at the start of the mission) or very late (i.e after the directive is actually complete).

Too early

This one is usually because of a very simple mistake. FS2_Open is smart enough to not show directives that hinge on the destruction of a ship until the ship is actually present in the mission. Some FREDders make the mistake of assuming this means that FS2_Open can automatically predict the time to show other directives. Of course, it can't. If a Directive is showing up too early you should chain it to an event that comes true just before you want the directive to appear.

Too late

is-event-true-delay in directivesThis is more of an insidious problem. Take the event to the left. That should display a directive telling you to kill Heavy Raider 4. What happens though is that the directive only appears after the Raider is destroyed. Or it appears as failed if the Raider jumps out.

The cause of the problem is that the game uses is-event-true-delay to determine when the event is complete and when it should display the directive. There is a third optional argument for the SEXP that allows you to say "If this SEXP is being used in a directive, use is-event-true-delay to determine when to show the directive, rather than when it is complete."