From fc6d3defde354e7647b8545646e9f81f121550f1 Mon Sep 17 00:00:00 2001 From: Fate-JH Date: Mon, 4 May 2026 12:23:03 -0400 Subject: [PATCH] failsafe on the failsafe for cargo dismounting (carrier needs to exist, if not a vehicle) (#1364) --- .../net/psforever/objects/vehicles/CargoBehavior.scala | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/scala/net/psforever/objects/vehicles/CargoBehavior.scala b/src/main/scala/net/psforever/objects/vehicles/CargoBehavior.scala index d90baa787..2a9e9cd97 100644 --- a/src/main/scala/net/psforever/objects/vehicles/CargoBehavior.scala +++ b/src/main/scala/net/psforever/objects/vehicles/CargoBehavior.scala @@ -61,8 +61,10 @@ trait CargoBehavior { def startCargoDismounting(bailed: Boolean): Unit = { if (!startCargoDismountingNoCleanup(bailed)) { - isDismounting = None - CargoObject.MountedIn = None + CargoObject.Zone.GUID(CargoObject.MountedIn).orElse { + isDismounting = None + CargoObject.MountedIn = None + } } }