Hard Light Productions Forums

Modding, Mission Design, and Coding => The FRED Workshop => Topic started by: the_dark_light on October 29, 2007, 05:41:17 pm

Title: Controling Fighter Waves
Post by: the_dark_light on October 29, 2007, 05:41:17 pm
I have a question about fighter waves.

When a percentage-ships-destroyed SEXP is used with a wing bsed on multiple waves, does it use only the number of ships in play or the entire wing (number of ships in wing * waves)

Reason being I'm trying to create pirate wings of fighters and bombers with more realistic behaviour.  Now since pirates are not diehard fanatics (well unless you did something to really p*ss them off) they probably won't fight to the death.

The idea is that the fighters (escorting bombers) will bug out when the bombers (attacking a freighter) are taken out and likewise, the bombers won't stick around if their escort is taken out.
Title: Re: Controling Fighter Waves
Post by: FUBAR-BDHR on October 29, 2007, 06:06:36 pm
From the Wiki:

Quote
percent-ships-destroyed
        Boolean function which returns true if the percentage of ships in the listed ships and wings which have been destroyed
is greater or equal to the given percentage.  For wings, all ships of all waves are used for calculation for the total possible
ships to be destroyed.


Takes 2 or more arguments:
        1:      Percentge of destroyed ships at which this function will return true.
        2+:     List of ships/wing whose destroyed status should be determined.
Title: Re: Controling Fighter Waves
Post by: the_dark_light on October 29, 2007, 06:55:30 pm
Sorry, I guess I should RTFW next time