AkiniKites / AloysAdjustments

Mods for Horizon Zero Dawn
MIT License
100 stars 13 forks source link

NRE when loading existing patch #28

Closed Xymanek closed 1 year ago

Xymanek commented 3 years ago
System.NullReferenceException: Object reference not set to an instance of an object.
   at AloysAdjustments.Logic.HzdCoreExtensions.GetTypes[T](HzdCore core)
   at AloysAdjustments.Plugins.Outfits.OutfitsGenerator.GetPlayerModels(HzdCore core)
   at AloysAdjustments.Plugins.Outfits.OutfitsGenerator.GenerateModelList(Func`2 coreGetter)
   at AloysAdjustments.Plugins.Outfits.CharacterGenerator.<GetVariantMapping>d__12.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at AloysAdjustments.Plugins.Outfits.OutfitsControl.<LoadPatch>d__39.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at AloysAdjustments.MainWindow.<LoadExistingPack>d__33.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at AloysAdjustments.MainWindow.<InitializePlugins>d__27.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at AloysAdjustments.MainWindow.<Main_Load>d__24.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at AloysAdjustments.UI.Relay.<To>d__1`2.MoveNext()

Happened with both 1.7.3 and 1.7.4. Patch was generated using 1.7.3 (I think).

Changes in the existing patch:

Xymanek commented 3 years ago

I deleted the old patch, created a new one (using 1.7.4) and upon reopening AA, same NRE happens.

What's weird is that I definitely recall the loading of existing patches working properly at some point, but I have no idea what changed since (version maybe?)

AkiniKites commented 2 years ago

Could be a version think. I'm trying to maintain compatibility but its getting tricky. Are you still having issues with it?

Xymanek commented 2 years ago

Just tried both 1.7.4 and the recent 1.8.0 - both show the same error

alxkum commented 2 years ago

Getting the same error here on a fresh install of HZD 1.11 (Steam). I open the app, change the Nora Brave outfit to Carja Blazon Light -> Install Pack, close app, open app again and the error shows up in the status bar with the error.log having the same stack trace as OP posted. As a matter of fact, trying to actually equip the Nora Brave outfit in the game leads to an endless loading icon without ever finishing. No other mods installed.

Xymanek commented 2 years ago

trying to actually equip the Nora Brave outfit in the game leads to an endless loading icon without ever finishing

Works fine here (also 1.11 from steam), although I had to recreate the patch file after the game's update (otherwise the game wouldn't even play the logo sequence)

alxkum commented 2 years ago

lol, how does it work for you but not for me? Can you try my patched file? This way we know if it's an issue with the generated file or with my game for whatever reason. This is the file where Nora Brave is replaced with the Carja Blazon Light outfit, please try to equip it. And see if you also get the same error in the app here when that file is in the Packed_DX12 folder. Patch_AloysAdjustments.zip

Xymanek commented 2 years ago

Tried your file:

alxkum commented 2 years ago

Thanks. Then it's just plain weird for me. I change the outfit in Inventory and when I hit escape to go back into the game, I'm just stuck in the Inventory with the loading spinner in the corner of the screen forever. And when I equip the outfit, quit the game, add the patch, and then try to load the game now - the loading screen will just get stuck at like 80%. In both cases, one core on my CPU is at full load until I kill the process in task manager.

AkiniKites commented 1 year ago

This should be fixed in 1.8.1