[Mod Help] How do I find out which mod is causing problems?

Started by Draconzis, January 12, 2020, 09:35:24 PM

Previous topic - Next topic

Draconzis

Sometimes when undrafting pawns, my UI will utterly glitched out, many parts disappearing, description boxes that won't go away, and/or becoming non-functional, resulting in the game being nearly unplayable. Disabling the mods I suspected were the caused of it did not work, and is utterly inconsistent. It seems that only certain pawns cause the problems, but which pawns do and don't cause it when undrafted seems to be utterly random. My last two playthroughs, the problem only started occurring a good ways into the game, so I can't even recreate it reliably. Checking the logs, when the bug occurs it gets flooded with things such as:

Root level exception in OnGUI(): System.NullReferenceException: Object reference not set to an instance of an object
  at RimWorld.ColonistBarColonistDrawer.DrawIcons (Rect rect, Verse.Pawn colonist) [0x00000] in <filename unknown>:0
  at RimWorld.ColonistBarColonistDrawer.DrawColonist (Rect rect, Verse.Pawn colonist, Verse.Map pawnMap, Boolean highlight, Boolean reordering) [0x00000] in <filename unknown>:0
  at RimWorld.ColonistBar.ColonistBarOnGUI () [0x00000] in <filename unknown>:0
  at RimWorld.MapInterface.MapInterfaceOnGUI_BeforeMainTabs () [0x00000] in <filename unknown>:0
  at RimWorld.UIRoot_Play.UIRootOnGUI () [0x00000] in <filename unknown>:0
  at Verse.Root.OnGUI () [0x00000] in <filename unknown>:0
Verse.Log:Error(String, Boolean)
Verse.Root:OnGUI()

All the logs that flood in are simular to this one. I scanned through a few to see if I could find a name or phrase that would point me to the problem mod, but to no avail. Any help at all is appreciated.

UPDATE: This happened in two different runs, and I found the common demoniator. The bug only started occurring whenever a mechanoid was downed or hacked. Looks like "What The Hack?!" is likely to blame. As it is a mod I very much wish to keep, I will try to find out the reason behind this.

LWM

At first glance, it sounds like one of the mods that changes how the pawn icons in the top row look is messing up when the pawn undrafts - the pawn mood bar, the one that shows weapons, etc.  Do you have any of those?

You could follow up on that idea by looking at the HugsLib debug log and searching for "icon" and see if any of the mods patch any of the icon creation stuff?