Changes:Warp Changes- Added OF_LIMBO flag (Bumbumbum...)
- Added field to ai-warp-out to toggle departure
- Added ai-warp-in
- Added is-in-limbo SEXP
- Many, many other changes and incremental improvements to support uninteractable OF_LIMBO objects
- Fixed ships disappearing at the wrong time with warp
- Fixed/Completed sounds for BTRL and Homeworld warp effects
- Fixed Homeworld effect 'jumping' at transition between opening or closing sequences
- Fixed Homeworld and BTRL warp dimensions when docked (Known issue: BTRL FTL effect may get rendered under docked objects)
Scripting Changes- Added On Frame Simulation hook
- Added gr.CurrentCamera
- Added boolean to ship:warpOut to toggle departure
- Added ORDER_ARRIVE for ship:giveOrder()
- Fixed ship.Textures indexing by name
- Fixed ship.Velocity to calculate speed/fspeed when set
- Fixed lua vector/orientation indexing with uppercase characters
- Changed createVector and createOrientation to newVector and newOrientation
- Changed camera 'Self' and 'SelfSubsystem' to 'Host' and 'HostSubsystem'
Other- Got rid of unnecessary Assert(banks_fired)
- Tested HUD damage gauge with custom subsys name (it worked)
- Tested camera deceleration (it worked)
Intrasystem Warping:Set the second field on ai-warp-out to "0" and then call ai-warp-in when you're ready for the other ship to come in.
This uses the old limbo method to do this. The plus side is that all of the SEXPs work with the ships while they're in limbo, so if you want to rearm/repair or change the ship's position etc you can do so. The down side is that all of the SEXPs work with the ships while they're in limbo, so you have to keep track of ships yourself. has-arrived-delay and has-departed-delay will not work - those still work with the mission arrival and departure cues.
Multiplayer, as far as I know, doesn't support this arrangement right now. I could add extra data to the packets but that would break compatibility.
In general, everything will behave like the ship that warped out has departed for good. This means if you have a ship on course to dock with a ship that warps out, you'll have to reissue the dock order once it jumps back in. One exception is the escort menu - it'll retain memory of the ships that have jumped out and keep those on the list. You can still send messages from ships in limbo and they won't show the targeting brackets. Ships will also not show up on the F4 screen when they limbo in/out - see "Jargon" below.
There's also some interesting things you could do with this as future coding features, like flagging certain wings to just warp out when ordered to depart and appear on the reinforcements list when warped out. With some SEXP or scripting, you could then slowly repair the ships over time until the player ordered them back in.
Jargon"Arrived" and "Departed" remain specific to the act of entering and exiting the mission. A ship which warps in or out does not arrive or depart, and won't appear that way to any of the SEXPs. This is by necessity - it would obviously make them worthless if they behaved as they do now and got set for good once a ship had warped in/out once, and confusing if they got reset every time.
SEXPsSEXPs will act like the ship is still in the mission and still at the spot where it warped out (until you move it with SEXPs or scripting, or it warps back in). I need to go through the list, but I'm up in the air on this. I can see instances where it might be useful to know where a ship in-limbo is, but I can also see where it would cause mass confusion.
Extendability:If somebody wants to implement something else that uses limbo, you just need to call:
//Enter limbo
obj_set_flags(objp, objp->flags | OF_LIMBO);
//Exit limbo
obj_set_flags(objp, objp->flags & (~OF_LIMBO));
Know bug:Colossus doesn't warp in at the right spot on "Endgame". This doesn't actually have anything to do with the limbo code, it's almost certainly an issue with the default warp effect changes I made.
I was going to hold off release until I'd fixed this bug and looked into making ships appear in the F4 screen, but I want to have the maximum amount of time for people to test intrasystem warping and let me know if I've missed any changes I need to make. I expect SEXPs will be one thing, but again, I haven't had time to look over them.
TODO:- Test/bugfix
- Look into F4 screen w/ regard to limbo
- Look over SEXPs w/ regard to limbo
- Group HUD wingman status code in hud wingman status section
- Finish implementing lights in scripting
- Add $On Object Create/$On Primary Fired/$On Secondary Fired hooks
- Look over scripting functions
- Rest and relax
Build:http://fs2source.warpcore.org/exes/latest/C09062008.zip