Killface1980 / RW_FacialStuff

MIT License
17 stars 15 forks source link

Failed to find Verse.ThingDef named Gun_RailgunMKI. #76

Closed TehGOOSE closed 3 years ago

TehGOOSE commented 4 years ago

I noticed there was an error similar to this back in January but I had no issue prior to patch, just wanted to start new game today. Got recent patch and went to start new game and pretty much after every new menu when trying to start a game the error pops

Failed to find Verse.ThingDef named Gun_RailgunMKI. There are 3621 defs of this type loaded.
Verse.Log:Error(String, Boolean)
Verse.DefDatabase`1:GetNamed(String, Boolean)
Verse.ThingDef:Named(String)
FacialStuff.GameComponent_FacialStuff:WeaponCompsNew()
FacialStuff.GameComponent_FacialStuff:.ctor(Game)
System.Reflection.MonoCMethod:InternalInvoke(Object, Object[], Exception&)
System.Reflection.MonoCMethod:InternalInvoke(Object, Object[])
System.Reflection.MonoCMethod:DoInvoke(Object, BindingFlags, Binder, Object[], CultureInfo)
System.Reflection.MonoCMethod:Invoke(BindingFlags, Binder, Object[], CultureInfo)
System.RuntimeType:CreateInstanceImpl(BindingFlags, Binder, Object[], CultureInfo, Object[], StackCrawlMark&)
System.Activator:CreateInstance(Type, BindingFlags, Binder, Object[], CultureInfo, Object[])
System.Activator:CreateInstance(Type, Object[])
Verse.Game:DMD<DMD<FillComponents_Patch1>?-924513664::FillComponents_Patch1>(Game)
Verse.Game:.ctor()
RimWorld.Page_SelectScenario:BeginScenarioConfiguration(Scenario, Page)
RimWorld.Page_SelectScenario:CanDoNext()
RimWorld.Page:DoBottomButtons(Rect, String, String, Action, Boolean, Boolean)
RimWorld.Page_SelectScenario:DoWindowContents(Rect)
Verse.Window:InnerWindowOnGUI(Int32)
UnityEngine.GUI:CallWindowDelegate(WindowFunction, Int32, Int32, GUISkin, Int32, Single, Single, GUIStyle)

published log: https://gist.github.com/d8f20ec1c31df42f51eed066153e13c4

I Don't have an output_log.txt in my RimWorldWin64_Data Heres a player.txt I was able to generate, hopefully it helps some.. https://gist.github.com/TehGOOSE/8ab87c567528990e7887fe6ee858503f

Mods xml: https://gist.github.com/TehGOOSE/725e8e85fbe339bee0f0f4739cb6dea1

I have no save game file, the error pops up before I Start.

Thanks for all you do!

JamesStrife commented 4 years ago

I also had this error. Found that the Gun_RailgunMK1 file was missing a linefeed/carriage return. I added the additional line and my file loaded with no issues.

PS - I also removed the railgun file and tried to load without it first before making the adjustment if that end up mattering.

Location should be: [Steam/Modpath]\Defs\WeaponExtensionDefs Filename: WeaponExtensionDef_Gun_RailgunMKI.xml

TehGOOSE commented 4 years ago

Where did you add the carriage return? would love to continue playing myself!

JamesStrife commented 4 years ago

oops, my mistake. it was at the end. You can find the call out in the commit: 9dffb72

TehGOOSE commented 4 years ago

I don't know enough to do what needs to be done. Ill just have to practice my patience :-p

JamesStrife commented 4 years ago

image

That is the note from the commit.

To make the change, go to the file location I noted above (for me it is C:\Program Files (x86)\Steam\steamapps\workshop\content\294100\818322128\Defs\WeaponExtensionDefs) I didn't put the full path because I'm not sure that Steam gives the same ids or if they are random.

Once in that location, open the file (WeaponExtensionDef_Gun_RailgunMKI.xml). You will most likely have to right-click it and choose either "edit" or "open with"(then choose Notepad).

Once you have the file open, simply add the return(hitting Enter on the keyboard) after the last character. So after the ">" on the last line.

TehGOOSE commented 4 years ago

oh Thats what I did in notepad and notepad++ thought I just misunderstood, I must have other issues too.

Same Issue. Thanks anyways.

Killface1980 commented 4 years ago

Thank you for reporting, I guess the cause for the error is the line <descriptionHyperlinks IsNull="True" /> Please remove it for now. It's a new variable by RW 1.0 which is added by default, I wasn't aware that also the gun received it. I'm working on a solution to remove this error for good.

TehGOOSE commented 4 years ago

Happy to help!

I'm striking out, I've tried doing what suggested above, and I tired just deleting the line above, but the error keeps popping up w/ error window.

I just recently started playing the game so not sure if ignoring the error popups is as forgiving as it can be in other games so Ill just patiently wait for the fix.

Thanks for your reply and hard work!

Hechicera64 commented 4 years ago

I tried adding a carriage return and verified editor did not strip on save. No love. I tried removing that line. No love. I did delete the file, and that worked. Of course, in a new game and the possibility of that being a weapon in my game is nil. Unsure what will happen if one does exist in a game of mine later. I'm also not sure if the error was benign anyway, as I had no crashes with it. Using the edit button during character creation won't work with the file deleted. So I found that out.

Hechicera64 commented 4 years ago

Testing on unstable tonight RimWorld 1.1.2586 rev1244, if I make a vanilla Crashlanded game, with only this mod and harmony new errors. Only 2 of the 3 pawns was consistent, and odd:

Initializing new game with mods:

Unloading 0 unused Assets to reduce memory usage. Loaded Objects now: 22142. Total: 89.939700 ms (FindLiveObjects: 1.162600 ms CreateObjectMapping: 1.211500 ms MarkObjects: 87.349600 ms DeleteObjects: 0.215700 ms)

Exception drawing Libby: System.NullReferenceException: Object reference not set to an instance of an object at FacialStuff.Animator.PawnHeadRotator.FindClosestTarget () [0x00042] in :0 at FacialStuff.Animator.PawnHeadRotator.FaceHead () [0x0000f] in :0 at FacialStuff.Animator.PawnHeadRotator.RotatorTick () [0x00065] in :0 at FacialStuff.CompFace.PostDraw () [0x000d5] in :0 at Verse.ThingWithComps.Comps_PostDraw () [0x00018] in :0 at Verse.ThingWithComps.Draw () [0x00006] in :0 at Verse.DynamicDrawManager.DrawDynamicThings () [0x000d8] in :0

(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

Exception drawing Makaka: System.NullReferenceException: Object reference not set to an instance of an object at FacialStuff.Animator.PawnHeadRotator.FindClosestTarget () [0x00042] in :0 at FacialStuff.Animator.PawnHeadRotator.FaceHead () [0x0000f] in :0 at FacialStuff.Animator.PawnHeadRotator.RotatorTick () [0x00065] in :0 at FacialStuff.CompFace.PostDraw () [0x000d5] in :0 at Verse.ThingWithComps.Comps_PostDraw () [0x00018] in :0 at Verse.ThingWithComps.Draw () [0x00006] in :0 at Verse.DynamicDrawManager.DrawDynamicThings () [0x000d8] in :0

(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

Killface1980 commented 3 years ago

Might be fixed by now.