Bug with option "force solving levels"?

Found a bug in R'n'D? Report it here!

Moderators: Flumminator, Zomis

Post Reply
User avatar
Holger
Site Admin
Posts: 4073
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Bug with option "force solving levels"?

Post by Holger »

filbo wrote:
I'm having a new problem which I'm not sure if it's caused by the recent code updates. When I switch to a levelset I've solved some levels of, it's insisting that I haven't solved them; I have to turn off 'force solving levels' to be able to get past them. I noticed you added a 'tape solves level' tape-flag, is it now consulting that (in my old tapes which obviously don't have that flag) before letting me pass?
(Hint: The above bug report relates to unreleased development code.)

May it be possible that you had "force solving levels" turned off for some time before noticing the above behavior? Because this would explain it: If this option is turned off, you can select and play every level you like. However, if you start playing with level 5 and solve it (just as an example), it would not make much sense to set the "lowest unsolved level" counter for that level set to "5", because you haven't solved levels 0 to 4 (or 1 to 4, depending on the level set). So, if this option is turned off, that counter is not touched at all (except if you solved the level with the same number as "lowest unsolved level", in which case it gets incremented, too). So if you would turn this option on again later, the described situation may occur (unless you have solved all levels in perfect numerical order).

That new tape flag "tape solves level" should have nothing to do with this. I've just added it to be able to decide on the score server if an "unsolvable" tape is unsolvable because it did not solve the level on the client system either (which may happen when uploading tapes after being offline, for example), or if it is a victim of the notorious "broken tape" bug. :-/
filbo
Posts: 647
Joined: Fri Jun 20, 2014 10:06 am

Re: Bug with option "force solving levels"?

Post by filbo »

This was as I was revisiting a levelset I finished years ago, so -- I have no idea how it was set at that time.

But, supposing it is as you say -- this makes an ugly situation. No way to fix that levelset, except either manually edit its levelsetup.conf, or go back and play every level in sequence? (And by 'play in sequence' I basically mean 'replay the tape, take control 1s from the end, finish manually -- now there is a spurious extra high score entry & tape upload recording my need to subvert the system.....)

In normal config, my local RnD has copies of all of my tapes *and* contact with your server; and your server knows which tapes solve their levels. So it is possible for the local RnD, in communication with the server, to determine which levels have in fact already been solved, and advance the pointer past them. (It could also do this locally, but then it would have to run the tapes, which takes a noticeable amount of time even in blank warp mode...)

Unfortunately, doing this would only partially solve the problem. Many levelsets have a few levels that just can't be solved (too few emeralds or whatever). Others have levels that are just too annoying to play out. What's wanted is a 'currently active tip of playing this levelset' pointer, which sensibly knows about both solved levels and intentionally skipped levels.

I think a good heuristic would be something like: look at all the tapes, determine which are solutions, then put the pointer at the last solved tape which was part of a contiguous block of *attempted* levels. So if levels 1-10 are: win, win, partial, win, win, untried, win, win, win, win -- put the pointer at 10. But if it ends ... 7:win, 8:untried, 9:untried, 10:win -- 10 is an outlier, put the pointer at 7. ('at' meaning wherever it should go if organically solved up to 7; i.e. probably 8, but maybe not if the user has auto-advance disabled -- I'm not sure...)

=====

Meanwhile, I am very tempted to ask for a facility to go back and edit all of one's old tapes, to annotate them with the 'solves level' flag. BUT. I also very much like that the old tapes have filesystem timestamps reflecting when they were created. So if such a facility existed, I would kind of want it to apply the change, then force the FS timestamp back to the original playing time (from the pre-edit file timestamp, or from the embedded timestamp if necessary). And others would be appalled at such a thing, so it would probably be a setting, 'Do / do not set "fixed" tape timestamps back to original'... This could eventually apply to edits which fix the 'broken tape' bug, assuming you ever figure out the exact cause and it turns out to have a retroactively applicable fix...

For maximum historical accuracy, such edits could put an 'edited to fix the following thing' changelog timestamp *inside* the file... :)
Post Reply