HarbourMasters / Shipwright

3.27k stars 490 forks source link

Enhacment presets no longer reimport randomiser settings #4561

Closed Pepper0ni closed 2 days ago

Pepper0ni commented 3 days ago

This fixes the No Hint issue found by Louist in the discord internal channels, which was caused by the Warp Song Hint setting reapplying when an enhancement preset was applied mid-game, causing the seed to try and look up hints that did not exist.

I do not know the purpose of this line, but do not see why enhancment presets would be applying randomiser settings anyway, so i moved forward with this PR, but I have no idea what to test for issues/regressions.

Build Artifacts

Malkierian commented 2 days ago

Since DrawPresetSelector is used anywhere a preset dropdown is placed, it's also the randomizer preset selector. If you lock ReloadOptions() behind a check to see if presetTypeId == PresetType.Randomizer, it should accomplish the same thing.

Pepper0ni commented 2 days ago

Noted, I made that change and it should only apply that check to the Randomiser Settings Preset button now. This means the original bug is replicable with that button, but the solution to this will have to be a deeper separation of the in-use context and the randomizer settings.