Auroriax / PuzzleScriptPlus

Puzzlescript Plus: Open Source HTML5 Puzzle Game Engine (with lots of extra functionality)
https://auroriax.github.io/PuzzleScript/
34 stars 4 forks source link

level_select_unlocked_rollover is broken #118

Open Auroriax opened 1 year ago

Auroriax commented 1 year ago

Describe the bug Setting rollover doesn´t seem to actually lock any levels at all!

Reproduction Steps In the metadata you set:

level_select
level_select_lock
level_select_unlocked_rollover 3

And then you enter the game, level select, then you should see all levels unlocked.

What did you expect would happen? As described in documentation.

OS & Browser version, desktop/mobile Ubuntu 22, Firefox

Screenshots, example projects, other relevant issues, etc. Reported over Discord.

Auroriax commented 1 year ago

Hmm, for me this seems to reproduce in a normal tab but not in an incognito tab, which probably means that there's some kind of save file weirdness going on?

My hunch is that sections that no longer exist are still somehow counting towards level progression for rollover purposes. (Or sections that are no longer accessible because the unlock conditions changed: e.g. solving the last level, then setting the rollover to 1, should the final level still count for rollover purposes? Or should the game forget we solved that level if it's solved but not unlocked?)

Unexian commented 1 year ago

I think you should only count levels that have been unlocked towards the rollover