voult2 / BetterPawnControl

A RimWorld mod that allows bulk assignment of animals to zones and colonists to outfits (or drugs) in one single action
MIT License
20 stars 21 forks source link

Exception in BetterPawnControl.AssignManager.SaveCurrentState #49

Open hachi opened 2 months ago

hachi commented 2 months ago

I'm getting an exception here... which is quite annoying because I can't close the Assign window, which means I can't save or anything to get of the situation by restarting.

Root level exception in OnGUI(): System.NullReferenceException: Object reference not set to an instance of an object
[Ref 598B62A9]
 at BetterPawnControl.AssignManager.SaveCurrentState (System.Collections.Generic.List`1[T] pawns) [0x00198] in <d63137978eb745fc9419e58a486554c6>:0 
 at BetterPawnControl.Patches.Window_PreClose.Postfix (Verse.Window __instance) [0x00038] in <d63137978eb745fc9419e58a486554c6>:0 
 at Verse.Window.PreClose () [0x00000] in <3d931901449c4087b86953a6d5c84d50>:0 
     - POSTFIX VouLT.BetterPawnControl: Void BetterPawnControl.Patches.Window_PreClose:Postfix(Window __instance)
 at Verse.WindowStack.TryRemove (Verse.Window window, System.Boolean doCloseSound) [0x00051] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainTabsRoot.ToggleTab (RimWorld.MainButtonDef newTab, System.Boolean playSound) [0x00056] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainTabsRoot.SetCurrentTab (RimWorld.MainButtonDef tab, System.Boolean playSound) [0x0000a] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainTabsRoot.EscapeCurrentTab (System.Boolean playSound) [0x00000] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainButtonWorker_ToggleWorld.Activate () [0x00054] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainButtonWorker.InterfaceTryActivate () [0x0008d] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainButtonWorker.DoButton (UnityEngine.Rect rect) [0x000ee] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainButtonsRoot.DoButtons () [0x00119] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.MainButtonsRoot.MainButtonsOnGUI () [0x0000e] in <3d931901449c4087b86953a6d5c84d50>:0 
 at RimWorld.UIRoot_Play.UIRootOnGUI () [0x00037] in <3d931901449c4087b86953a6d5c84d50>:0 
 at Verse.Root.OnGUI () [0x00046] in <3d931901449c4087b86953a6d5c84d50>:0 
     - POSTFIX UnlimitedHugs.HugsLib: Void HugsLib.Patches.Root_OnGUI_Patch:OnGUIHookUnfiltered() 
(Filename: ./Runtime/Export/Debug/Debug.bindings.h Line: 39)
TheLonerD commented 1 month ago

Can you send your save file so I can debug it?