RimWorld
Misc. Robots
irilis 15 Thg08, 2021 @ 1:17pm
NullReferenceException in log
I see multiple errors like this in Player.log:

Exception in BreadthFirstTraverse: System.NullReferenceException: Object reference not set to an instance of an object at RimWorld.GenConstruct.CanConstruct (Verse.Thing t, Verse.Pawn pawn, Verse.WorkTypeDef workType, System.Boolean forced) [0x00000] in <00638943358e4807bd44cd7bc8f572da>:0 at RimWorld.WorkGiver_ConstructDeliverResourcesToFrames.JobOnThing (Verse.Pawn pawn, Verse.Thing t, System.Boolean forced) [0x0002e] in <00638943358e4807bd44cd7bc8f572da>:0 at RimWorld.WorkGiver_Scanner.HasJobOnThing (Verse.Pawn pawn, Verse.Thing t, System.Boolean forced) [0x00000] in <00638943358e4807bd44cd7bc8f572da>:0 at AIRobot.X2_JobGiver_Work+<>c__DisplayClass1_0.<TryIssueJobPackage>b__1 (Verse.Thing t) [0x0000e] in <a0adc82c73eb48cc9870e2f9e12039e7>:0 at Verse.GenClosest+<>c__DisplayClass4_0.<RegionwiseBFSWorker>b__1 (Verse.Region r) [0x000f7] in <00638943358e4807bd44cd7bc8f572da>:0 at Verse.RegionTraverser+BFSWorker.BreadthFirstTraverseWork (Verse.Region root, Verse.RegionEntryPredicate entryCondition, Verse.RegionProcessor regionProcessor, System.Int32 maxRegions, Verse.RegionType traversableRegionTypes) [0x00054] in <00638943358e4807bd44cd7bc8f572da>:0 at Verse.RegionTraverser.BreadthFirstTraverse (Verse.Region root, Verse.RegionEntryPredicate entryCondition, Verse.RegionProcessor regionProcessor, System.Int32 maxRegions, Verse.RegionType traversableRegionTypes) [0x00044] in <00638943358e4807bd44cd7bc8f572da>:0 (Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 39)
< >
Đang hiển thị 1-3 trong 3 bình luận
irilis 29 Thg08, 2021 @ 4:03am 
I may have found the cause of this error.

Without "MiscRobots WorkTab support" mod robots have "<workSettings IsNull="True" />" in save files. With that mod robots have at least "<workSettings><priorities IsNull="True" /></workSettings>".

RimWorld.GenConstruct.CanConstruct seems to use pawn.workSettings without checking for null, which generates NullReferenceException.
Pacifist 18 Thg11, 2021 @ 3:30am 
Nguyên văn bởi irilis:
I may have found the cause of this error.

Without "MiscRobots WorkTab support" mod robots have "<workSettings IsNull="True" />" in save files. With that mod robots have at least "<workSettings><priorities IsNull="True" /></workSettings>".

RimWorld.GenConstruct.CanConstruct seems to use pawn.workSettings without checking for null, which generates NullReferenceException.
what does that mean? would you then not want MiscRobots WorkTab support then?
irilis 18 Thg11, 2021 @ 8:29am 
Nguyên văn bởi Pacifist-ish:
Nguyên văn bởi irilis:
I may have found the cause of this error.

Without "MiscRobots WorkTab support" mod robots have "<workSettings IsNull="True" />" in save files. With that mod robots have at least "<workSettings><priorities IsNull="True" /></workSettings>".

RimWorld.GenConstruct.CanConstruct seems to use pawn.workSettings without checking for null, which generates NullReferenceException.
what does that mean? would you then not want MiscRobots WorkTab support then?
That means that "MiscRobots WorkTab support" fixed a bug that was cousing NullReferenceException. I don't use "MiscRobots WorkTab support" to change robot priorities, I just use as a patch for a bug.
< >
Đang hiển thị 1-3 trong 3 bình luận
Mỗi trang: 1530 50