RimWorld

RimWorld

Animal Gear
Anjo 22 Jul, 2024 @ 9:49pm
mod ver 1.5 here are the errors that I encounter
Mod requirements are fulfilled and mod load order is okay.



On load with animal gear base, with or without any animal armor mods:

[HugsLib][ERR] AnimalGear.AnimalGearController caused an exception during child mod instantiation: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> HarmonyLib.HarmonyException: Patching exception in method null ---> System.ArgumentException: Undefined target method for patch method static System.Boolean AnimalGear.PawnRenderNode_Apparel_MeshSetFor_Patch::PawnRenderNode_Apparel_MeshSetFor_Pre(Verse.PawnRenderNode_Apparel __instance, Verse.Pawn pawn, System.Boolean ___useHeadMesh, Verse.GraphicMeshSet& __result)
[Ref 863C5FC]
at HarmonyLib.PatchClassProcessor.PatchWithAttributes (System.Reflection.MethodBase& lastOriginal, System.Boolean unpatch) [0x00047] in <abec11463bc04855a5322a0a868aeb22>:0
at HarmonyLib.PatchClassProcessor.Patch () [0x0006e] in <abec11463bc04855a5322a0a868aeb22>:0
--- End of inner exception stack trace ---
[Ref 3B45911]
at HarmonyLib.PatchClassProcessor.ReportException (System.Exception exception, System.Reflection.MethodBase original) [0x00154] in <abec11463bc04855a5322a0a868aeb22>:0
at HarmonyLib.PatchClassProcessor.Patch () [0x000a0] in <abec11463bc04855a5322a0a868aeb22>:0
at HarmonyLib.Harmony.<PatchAll>b__10_0 (System.Type type) [0x00007] in <abec11463bc04855a5322a0a868aeb22>:0
at HarmonyLib.CollectionExtensions.Do[T] (System.Collections.Generic.IEnumerable`1[T] sequence, System.Action`1[T] action) [0x00014] in <abec11463bc04855a5322a0a868aeb22>:0
at HarmonyLib.Harmony.PatchAll (System.Reflection.Assembly assembly) [0x00006] in <abec11463bc04855a5322a0a868aeb22>:0
at <0x26db354ac00 + 0x0013a> <unknown method>
at (wrapper managed-to-native) System.Reflection.MonoCMethod.InternalInvoke(System.Reflection.MonoCMethod,object,object[],System.Exception&)
at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00002] in <eae584ce26bc40229c1b1aa476bfa589>:0
--- End of inner exception stack trace ---
[Ref 814CA896]
at System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) [0x00014] in <eae584ce26bc40229c1b1aa476bfa589>:0
at System.RuntimeType.CreateInstanceMono (System.Boolean nonPublic) [0x000a8] in <eae584ce26bc40229c1b1aa476bfa589>:0
at System.RuntimeType.CreateInstanceSlow (System.Boolean publicOnly, System.Boolean skipCheckThis, System.Boolean fillCache, System.Threading.StackCrawlMark& stackMark) [0x00009] in <eae584ce26bc40229c1b1aa476bfa589>:0
at System.RuntimeType.CreateInstanceDefaultCtor (System.Boolean publicOnly, System.Boolean skipCheckThis, System.Boolean fillCache, System.Threading.StackCrawlMark& stackMark) [0x00027] in <eae584ce26bc40229c1b1aa476bfa589>:0
at System.Activator.CreateInstance (System.Type type, System.Boolean nonPublic) [0x00020] in <eae584ce26bc40229c1b1aa476bfa589>:0
at HugsLib.HugsLibController.EnumerateChildMods (System.Boolean earlyInitMode) [0x000f8] in <9270b4f3a0574e6ab5e5325b2e8ba741>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch1 (string)
HugsLib.Utils.ModLogger:ReportException (System.Exception,string,bool,string)
HugsLib.HugsLibController:EnumerateChildMods (bool)
HugsLib.HugsLibController:LoadReloadInitialize ()
Verse.LongEventHandler:RunEventFromAnotherThread (System.Action)
Verse.LongEventHandler/<>c:<UpdateCurrentAsynchronousEvent>b__28_0 ()
System.Threading.ThreadHelper:ThreadStart_Context (object)
System.Threading.ExecutionContext:RunInternal (System.Threading.ExecutionContext,System.Threading.ContextCallback,object,bool)
System.Threading.ExecutionContext:Run (System.Threading.ExecutionContext,System.Threading.ContextCallback,object,bool)
System.Threading.ExecutionContext:Run (System.Threading.ExecutionContext,System.Threading.ContextCallback,object)
System.Threading.ThreadHelper:ThreadStart ()



On dev test after spawning a horse then tamed and upon the horse equipping armor it throws this for each armor equipped:

Exception setting up node for DevDesigner_Apparel_Horse_DarkCaparisonBack on Horse34255: System.NullReferenceException: Object reference not set to an instance of an object
[Ref D4EB507]
at Verse.PawnRenderTree.ProcessApparel (RimWorld.Apparel ap, Verse.PawnRenderNode headApparelNode, Verse.PawnRenderNode bodyApparelNode) [0x000ab] in <8135c646de5b47a8a5382fd69e7b5317>:0
- POSTFIX OskarPotocki.VFECore: Void VFECore.PawnRenderTree_ProcessApparel_Patch:Postfix(PawnRenderTree __instance, Apparel ap, PawnRenderNode headApparelNode, PawnRenderNode bodyApparelNode)
at Verse.PawnRenderTree.SetupApparelNodes () [0x00074] in <8135c646de5b47a8a5382fd69e7b5317>:0
UnityEngine.StackTraceUtility:ExtractStackTrace ()
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.Log.Error_Patch1 (string)
Verse.PawnRenderTree:SetupApparelNodes ()
System.Reflection.MonoMethod:Invoke (object,System.Reflection.BindingFlags,System.Reflection.Binder,object[],System.Globalization.CultureInfo)
System.Reflection.MethodBase:Invoke (object,object[])
HarmonyLib.Traverse:GetValue ()
AnimalGear.AnimalGearHarmony/PawnRenderTree_SetupDynamicNodes_Patch:SetupApparelNodes_SetupDynamicNodes_Pre (Verse.PawnRenderTree)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition:Verse.PawnRenderTree.SetupDynamicNodes_Patch1 (Verse.PawnRenderTree)
Verse.PawnRenderTree:TrySetupGraphIfNeeded ()
Verse.PawnRenderTree:EnsureInitialized (Verse.PawnRenderFlags)
Verse.PawnRenderer:EnsureGraphicsInitialized ()
Verse.PawnRenderer:DynamicDrawPhaseAt (Verse.DrawPhase,UnityEngine.Vector3,System.Nullable`1<Verse.Rot4>,bool)
Verse.Pawn:DynamicDrawPhaseAt (Verse.DrawPhase,UnityEngine.Vector3,bool)
Verse.Thing:DynamicDrawPhase (Verse.DrawPhase)
Verse.DynamicDrawManager:DrawDynamicThings ()
Verse.Map:MapUpdate ()
Verse.Game:UpdatePlay ()
Verse.Root_Play:Update ()