FirstPersonKSP / FreeIva

Work in progress mod for Kerbal Space Program which allows getting out of your seat and moving around the vessel while on IVA.
GNU General Public License v2.0
25 stars 8 forks source link

Kerbal can die if his original part gets destroyed #399

Open numberlesstim opened 7 months ago

numberlesstim commented 7 months ago

Repro:

  1. Build or load the below craft and spawn it with 1 Kerbal each in the Cockpit and the second CrewCabin
  2. Move the Kerbal from the Cockpit to the InlinePort seat.
  3. Move the other Kerbal to the Cockpit seat
  4. Stage to destroy the second Kerbals original part
  5. Observe the Kerbal die at the same time the part does despite empty seats being available

Craft Craftfile: InlinePort1.zip

JonnyOThan commented 7 months ago

Hijacking this issue for a more generic pass:

Currently, unbuckling is conceptually similar to opening the crew transfer dialog window. You're still in your old seat until you move to a new one. Even so, some seats like the inline docking ports are "fake" - the part doesn't have crew capacity so you still actually are assigned to whatever part you came from. That can lead to strange results when parts are decoupled or destroyed.

In general, if the part you are actually assigned to gets decoupled or destroyed, then we should find an empty seat close to where you are now and assign you there. If that's not possible, we could remove the kerbal from the old vessel and let them roam around in the current one, but they'd have to go EVA at some point. Or see if the game will work with overfilling a crewed part.