The unloadaircraft
event fires when an aircraft has been unloaded.
The dispatched event uses the AircraftLoadEvent
interface.
> "unloadaircraft",
undefined
Aircraft 0 unloaded
Aircraft 1 unloaded
Aircraft 2 unloaded
aircraft_unload()
callback is roughly equivalent to this event, with one caveat: the XLua event only fires for the user's aircraft (aircraft 0). JetScript fires this for every aircraft; you can check if the event is for the user's aircraft by checking event.user
.