Send player to specific system with specific desc after death?

For future reference.

So I had an epiphany on a storyline that will be fun, easy for me to write, has a moral and satisfies the constraints of the (Colosseum) universe, all at the same time, and it's for CTC-C. I now have an outlet to progress upon in CTC-C, but I can talk about that later. Much later. 😉

As I'm laying all these events, missions, background, etc in a CMAP, I've realized that there's a plot element that I'm not sure I'll be able to implement quite the way I want it. At one point among the mission branches the player will encounter a bunch of ships whose goal is to destroy the player.

If the ships trying to destroy the player succeed I want the player to be ejected in an escape pod (which will be given to the player when the mission starts, of course, if the player doesn't have one already) have a desc telling the story of the player's final moments pop up, and then dump the player in the end system.

If the player succeeds in defending himself the player will be given a desc continuing the story, and will be able to move on.

The latter is possible using an OnShipDone desc, but I have no ideas about the former. I'm hoping somebody has an idea on how this could be accomplished; I would go so far as to say that this will make CTC-C an extremely interesting piece of work.

This post has been edited by JacaByte : 07 March 2010 - 06:22 PM

This post should help:

QUOTE (Edwards @ Jun 22 2005, 09:54 PM) <{POST_SNAPBACK}>

If the "mission fails if ship is disabled/destroyed" flag is not set:
When you use an escape ship , nothing happens to your active missions (however, your escorts abandon you). When you use an escape pod , your missions' OnAbort fields are evaluated.

If that flag is set, the mission will fail as soon as your ship is disabled.

QUOTE (Edwards @ Jun 22 2005, 09:54 PM) <{POST_SNAPBACK}>

Using an escape pod/ship does not cause either the pod or ship's OnPurchase field to be evaluated. However, if you use an escape pod, sh�p 128's OnPurchase field is evaluated as soon as you recieve it.

I see... I shall test this in TCTC and see how it all behaves in-game.

Edit: It seems that the nxxx and mxxx operators are ignored when the mission is aborted in such a manner; the system that is chosen by the escape pod sequence takes precedence over any operators, it seems.

I'm about 95% sure that using a second mission that auto aborts when the main mission aborts and putting the mxxx operator in the OnAbort field of Mission B will do the trick, however.

Edit2: Huh, seems that 5% chance hath bit me in the bottom; I've been unable to get the mxxx operator to move the player anywhere. Here's the plug-in I made if that helps any. I'm kinda at a loss, but it's not that big a problem. Yet.

This post has been edited by JacaByte : 07 March 2010 - 08:02 PM

If all else fails, you can remove any escape pod/escape ships the player has at the beginning of the mission and use this method:

Make an "escape ship" with the escape pod sprite and stats (or whatever stats you want), but not escape type.
Make the AI enemies have disable and not destroy behavior.
Make the "Live or Die!" mission fail when the player is disabled.

Live or Die! mission 1
OnFail Exxx Myyy Szzz Gaaa
where xxx is the fake escape pod, yyy is the system to move to, zzz is the mission with the death text which displays when the mission starts, and aaa is a real escape pod with auto-eject.

mission triggered on failing first mission
Displays text, then triggers the next mission

mission three
Kills the player (who know has an escape pod and auto-eject), and sets whatever other bits are necessary for the completion of the death sequence.

Mission 2 and 3 may be able to be combined depending on how you want the text to run.

I know that this solution isn't as good because it uses the on-disable trigger, but that's all I can think of right now. Can you Exxx the player OnAbort when he ejects? You might be able to use this to have a realistic fighting in-game player's ship destruction and eject sequence, and then revert to normal mission behaviour. Try Exxx-ing the player into a "real" ship temporarily.

LNSU, a modification to your method. You do not need to grant the player an escape pod and auto eject. You can simply make those two standard outfits on the fake escape pod.

However, in my opinion, the method suggested by Qaanol and created by Edwards is more efficient.

@darthkev:
The method suggested by Qaanol was attempted (see Jacabyte's post above), however it does not evaluate the Mxxx operator, which is why I suggested the following. The method suggested by Qaanol will work for displaying mission text, setting/unsetting bits, starting/ending missions, and perhaps even modifying/replacing the player's ship. The problem is that the escape pod sequence lands the player on a planet before s/he can be Mxxx-ed to where Jacabyte wants. Using a 100% availability auto-accept-on-landing at any spaceport mission, which would only be available when the bits set by failing the "Live or Die!" mission are set, it would be possible to modify the player's ship as needed and Mxxx him to the wanted system. However, this has the unfortunate effect of an intermediate landing on a planet, which the player will notice as the main landing screen background will be visible.

<facepalm> Right, I missed that, sorry. 😊

Well you should use Gxxx where you have Oxxx. The Mxxx works fine for me. What isn't working is the auto-abort, but I don't have time to look into why that is right now since it's class time.

Huh. That's strange. I should try setting the systems to have the same government, remove the mxxx operator as a test (see if the escape pod placement is random or not) and then try the mxxx operator again.

QUOTE (Edwards @ Jun 22 2005, 10:54 PM) <{POST_SNAPBACK}>

If the "mission fails if ship is disabled/destroyed" flag is not set:
When you use an escape ship , nothing happens to your active missions (however, your escorts abandon you). When you use an escape pod , your missions' OnAbort fields are evaluated.

If that flag is set, the mission will fail as soon as your ship is disabled.

Not true. If I told you that, I'm sorry. Using an escape pod/ship does not cause either the pod or ship's OnPurchase field to be evaluated. However, if you use an escape pod, sh�p 128's OnPurchase field is evaluated as soon as you recieve it.

Overly dramatic sigh.
Escape pods ARE sh�ps (RID 895), and have been ever since EVC. They DO use sh�ns (RID 895), and if you change a few numbers in the sh�p resource, you can even purchase them and fly around in them.

Edwards

Wait a minute. If a captain ejects using an escape pod, does that mean he gets the SHIP specified in the CHAR resource, or SHIP 128? Because my SHIP 128 is a big fat warship, not a shuttle.

Char's are simply a way to start a player in different conditions. Past what they set at the pilots creation, they have no effect.

An ejecting player will restart in ship RID 128.

(EDIT) Just tested to confirm. You restart in ship RID 128.

This post has been edited by Eugene Chin : 07 April 2010 - 10:55 AM

Awesome! Now I'm even more eager to play EVN:UGF! All I gotta do is die and I can rule the galaxy! :laugh: