BadMagic100 / TheRealJournalRando

A Hollow Knight Itemchanger addon that allows changing and randomizing additional Hunter's Journal entries
MIT License
0 stars 3 forks source link

Count mimic pickups as vanilla mimic kills #6

Closed BadMagic100 closed 1 year ago

BadMagic100 commented 1 year ago

https://github.com/BadMagic100/TheRealJournalRando/blob/master/TheRealJournalRando/IC/JournalKillCounterModule.cs#L88-L106

For cases where mimics and notes are randomized, but entries are not, picking up a mimic item does not increment the vanilla kill counter and thus does not allow previews

TBD - should this be part of IC? TBD - do we need to avoid double-counting actual killed mimic containers in vanilla or does the container need extra help to suppress the kill?

BadMagic100 commented 1 year ago

Proposed implementation: Switch from ModHooks.RecordKillForJournal to hook EnemyDeathEffects.orig_RecordKillForJournal. Add a bool or enum flag to JKCM that specifies how mimic containers should be handled w.r.t. vanilla journal, and create the module in OnExportCompleted to specify the appropriate handling based on randomization type (current behavior works fine except in notes-only rando, so that's the case we need to address specifically).