viddie / ConsistencyTrackerMod

A mod to track your progress while grinding goldens in Celeste! GameBanana page: https://gamebanana.com/mods/358978
12 stars 10 forks source link

Nullpointer when storing old session data #73

Closed viddie closed 1 year ago

viddie commented 1 year ago
Celeste Error Log
==========================================

Ver 1.4.0.0-fna [Everest: 4000-azure-f4545]
05/25/2023 20:39:37
System.NullReferenceException: Object reference not set to an instance of an object.
   at Celeste.Mod.ConsistencyTracker.Models.ChapterStats.StoreOldSessionData(PathInfo chapterPath) in /home/runner/work/ConsistencyTrackerMod/ConsistencyTrackerMod/Models/ChapterStats.cs:line 163
   at Celeste.Mod.ConsistencyTracker.Models.ChapterStats.ResetCurrentSession(PathInfo chapterPath) in /home/runner/work/ConsistencyTrackerMod/ConsistencyTrackerMod/Models/ChapterStats.cs:line 123
   at Celeste.Mod.ConsistencyTracker.ConsistencyTrackerModule.ChangeChapter(Session session) in /home/runner/work/ConsistencyTrackerMod/ConsistencyTrackerMod/ConsistencyTracker.cs:line 574
   at Celeste.Mod.ConsistencyTracker.ConsistencyTrackerModule.Level_Begin(orig_Begin orig, Level level) in /home/runner/work/ConsistencyTrackerMod/ConsistencyTrackerMod/ConsistencyTracker.cs:line 454
viddie commented 1 year ago

couldnt reproduce and also dont see where nullpointer could occur here.

the people that had this happen said it was their first time entering the chapter after cct update that introduced session history, so its probably caused by some value / reference not being set correctly there

i just added a try/catch around it for now :glumbsup: