NullException if you die in a dungeon, let video play, then load an exterior save [RESOLVED]

Locked
R.D.
Posts: 379
Joined: Fri Oct 07, 2016 10:41 am

NullException if you die in a dungeon, let video play, then load an exterior save [RESOLVED]

Post by R.D. »

sing the latest code (commit 16b2a1e), if you die in a dungeon (probably also happens for any interior), let the death video play, then load a save in an exterior location, the following null exception happens, and the game screen is stuck black.

Code: Select all

NullReferenceException: Object reference not set to an instance of an object
DaggerfallWorkshop.Game.Automap.saveStateAutomapDungeon (Boolean forceSaveOfDungeonDiscoveryState) (at Assets/Scripts/Game/Automap.cs:1383)
DaggerfallWorkshop.Game.Automap.OnTransitionToDungeonExterior (DaggerfallWorkshop.Game.TransitionEventArgs args) (at Assets/Scripts/Game/Automap.cs:1716)
DaggerfallWorkshop.Game.PlayerEnterExit.RaiseOnTransitionDungeonExteriorEvent () (at Assets/Scripts/Game/PlayerEnterExit.cs:1323)
DaggerfallWorkshop.Game.PlayerEnterExit+<Respawner>c__Iterator0.MoveNext () (at Assets/Scripts/Game/PlayerEnterExit.cs:444)
UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress) (at C:/buildslave/unity/build/Runtime/Export/Coroutines.cs:17)
No problem happens in the following cases:
- The player dies but before the death video can play you load a saved game.
- The player dies and the death video plays, but you load a saved game in an interior. It doesn't matter whether the player character or the interior is the same as the game where the player died.

User avatar
Interkarma
Posts: 7247
Joined: Sun Mar 22, 2015 1:51 am

Re: NullException if you die in a dungeon, let video play, then load an exterior save

Post by Interkarma »

Thanks for the diagnosis. I've just merged a changed that should fix this one.

Locked