Hard Light Productions Forums

Modding, Mission Design, and Coding => The Modding Workshop => Topic started by: HLD_Prophecy on October 19, 2015, 08:56:44 pm

Title: How to end a mission when player lands in hangar bay
Post by: HLD_Prophecy on October 19, 2015, 08:56:44 pm
Hey all!

So numerous campaigns, particularly Blue Planet, feature some kind of FREDing trick that ends the mission when the player flies into the hangar bay of a capital ship. I would like to do this myself, but I can't figure out how. Could someone explain this?

Thanks!
Title: Re: How to end a mission when player lands in hangar bay
Post by: Lepanto on October 19, 2015, 09:06:28 pm
Use the end-mission SEXP when the player is (say) 500 meters or less from the fighterbay of the capship you're landing on.
Title: Re: How to end a mission when player lands in hangar bay
Post by: General Battuta on October 19, 2015, 09:09:41 pm
In your event's conditional branch, use the < operator, then make one of its subcases 'distance'. I think there might be a 'distance-ship-subsystem' or somesuch.
Title: Re: How to end a mission when player lands in hangar bay
Post by: perihelion on October 19, 2015, 10:04:30 pm
And don't set it too low or your player will have to bump around inside the hanger until he finally gets close enough to trigger the event.  This works fine if comedy is your aim, but it can kind of break the mood in a for-super-serious mission.
Title: Re: How to end a mission when player lands in hangar bay
Post by: HLD_Prophecy on October 20, 2015, 09:13:48 am
And don't set it too low or your player will have to bump around inside the hanger until he finally gets close enough to trigger the event.  This works fine if comedy is your aim, but it can kind of break the mood in a for-super-serious mission.

Oh yeah, I've had this happen to me in some campaigns.

Looks like that symbolic expression is only available when using one of those comparative operators. That confused me for a bit - I can't just add it in without having the "<" or some such operator first.

Thanks guys, I think I'm good now! :)