Supaplex engine bugs

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

Moderators: Flumminator, Zomis

User avatar
Martijn
Posts: 794
Joined: Sat Jun 19, 2004 10:54 am
Location: the Netherlands (Holland)
Contact:

Post by Martijn »

Holger wrote:Principally, I fully agree here! The least I could do would be a setup option for the Supaplex engine like "allow zig-zag movement: on/off". Maybe "on" should even be the default, as most people who play native Supaplex levels in R'n'D most probably don't care at all if they can be played in the original game. And those few who do could enable it in the setup. Hmmm...
Well, an option to choose would be the best I think, too! But in my opinion, the default option should be "off" then, since that is exactly the original behaviour...

Somewhere else, you (Holger) remark this:

Well, it depends on how close to the original the engine should be. I had the same problem with the Emerald Mine engine, which had the same kind of input key priority issue, but I just changed this right away to the more convenient R'n'D behaviour, which was no problem, as there do not exist any tapes for EM levels, as the original EM does not have such a feature. But as the original Supaplex has a similar tape recording facility (tapes are called "demos" there), changing the input key processing will most probably invalidate correct tapes/demos due to the different interpretation of key order, as it does not store movements, but raw input key events.
Well, if you decide to create such an option, maybe you should create it for the Emerald Mine engine as well, to be able to choose between key priority and hence play it in "exactly the same way" as the original game or to play it in "almost exactly the same way" as the original.
Visit my Boulder Dash website at:
http://www.bd-fans.com

Watch my avatar! That orange little thing is Murphy, the Supaplex star!
Anonycat
Posts: 47
Joined: Thu Mar 27, 2008 4:45 am

Re: Supaplex engine bugs

Post by Anonycat »

The timer in the SP engine counts way too fast--once every 20 frames, which disagrees with the tape time if nothing else. Furthermore, it gets screwy at the end of a level--using the level 93 tape I linked earlier in the topic, many years ago (0:37.08 by the tape display), the timer counts up at an accelerated rate to 092, then upon reaching the exit it immediately goes back down to 037 and plays the tally from there.

I've looked at some native Supaplex videos and the timer actually appears to run at 70fps there (assuming it takes 8 frames to cross a tile). A list of historic SP time records I found are also consistent with being able to move 8.75 tiles per second. Is the 20 figure a relic of some attempt (gone wrong) to bump the standard 50 up to 70, or something entirely unrelated?
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

The "time" counter (in the game panel) for Supaplex levels counting too fast will be fixed in the upcoming new version 3.3.0.2 of R'n'D.

The Supaplex speed is either (by mistake) 70 fps (if playing the original, unmodified DOS version on non-historic hardware, which results in game speed being twice as fast as originally intended), or 35 fps (if using the original, unmodified DOS version on historic hardware, or when using Herman Perk's "SpeedFix" version, which fixes this and other bugs in the original game and adds a lot of useful features). To emulate this with R'n'D, either use "fast" game speed for playing with approximately 70 fps, or "very slow" game speed for around 35 fps. This will then also be reflected in the "time" counter and in the tape recorder (which will then both run faster or slower).
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Wow, I've just noticed the forum is back up and there is a new release of R'n'D, great! Could you tell me what exactly are "fixed two game engine bugs in Supaplex game engine" related to?
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

The following bugs regarding the Supaplex engine have been fixed in R'n'D 3.3.1.0 (this and all other changes and fixes can also be found in the file "ChangeLog" included in the R'n'D package):

* fixed displaying Supaplex time (now based on 35 fps instead of 50 fps)
* fixed bug with accidentally removing preceding buffer in SP engine
* fixed another memory violation bug in the native Supaplex game engine
(this potential memory bug was also in the original Megaplex code, but
apparently only occured under rare conditions triggered by using the
additional added preceding playfield memory area to make a few strange
levels using dirty off-playfield tricks (bugs) like "12s033.sp" also
solvable (this all worked fine in the classic DOS version, of course))

Some more Supaplex related changes since version 3.3.0.1:

* improved single step mode in R'n'D, EM and SP engines
* added graphics performance optimization to native Supaplex game engine
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Thanks for the details! I've just started to play through all Supaplex levels from scratch, so I'll let you know if everything works. ;-)
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

There *might* be a bug in level 69 - when you kill Electrons with orange disk, it turns to *nine* infotrons, while in the original it would only produce four (when smashed from up) or 6 (when the explosion reaches it diagonally). Could someone verify that in the original game?
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Ok, now it's what I'm 100% sure is a bug. Infotron falling on top of the red disk makes it explode:
Here's a screenshot from level 75. When I push this orange disk, Infotron falls on the red disk in the opening and it explodes:

Image

What is more interesting is that it doesn't occur when the zonk ("stone") falls on the red disk, as per example:

Image -> Image

So it's a bug with infotron bevahiour only. I don't know yet if it renders this level (#75) uncompletable - maybe not, but it sure makes things more difficult, at least until it's fixed. ;-) [edit] The level is still completable. :-)

PS. I wanted to attach a tape to this post, but it doesn't save. Regardless if I start playing normally, or if I press record in the menu, then play, then press stop - I cannot figure the way to save the tape. Is the tape only saved when I complete the level?
Last edited by bojster on Tue Feb 04, 2014 1:30 pm, edited 1 time in total.
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

PS. I wanted to attach a tape to this post, but it doesn't save. Regardless if I start playing normally, or if I press record in the menu, then play, then press stop - I cannot figure the way to save the tape. Is the tape only saved when I complete the level?
To manually save an "incomplete" tape (other than being asked if you want to save the tape after successfully finishing a level), just stop the tape and then press the "eject tape" button -- the game will then ask you if you want to replace the existing tape with this new one (or just confirms saving the tape if there was no existing tape found for this level). Hope that helps!

Regarding the game engine bugs you have reported, I will try to check this (mis-)behaviour against the original game (either in the DOS executable or the game Megaplex, which uses the original engine code from the DOS executable). Unfortunately, I have to do some work before I am able to do that, as I found out that the Megaplex game does not work inside my Windows VM inside VirtualBox (failing with errors in the VisualBasic runtime), while it did work with the Windows VM inside VMware (on my old PC not running anymore). Testing with DOS Supaplex should work, but I have to hack the game files to be able to play/test any level without having to play all preceding levels before... Maybe I can get Megaplex to work by running my VirtualBox VM with a newly set up VMware player instance. If all else fails, I have to find a "real" Windows PC somewhere to test it there...
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

About "saving a tape at any time": I totally forgot about the easiest way to instantly save a tape: Just press F1! (It will also ask if you want to overwrite the existing tape, if needed).
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Holger wrote:About "saving a tape at any time": I totally forgot about the easiest way to instantly save a tape: Just press F1! (It will also ask if you want to overwrite the existing tape, if needed).
Thanks, I forgot about it as well. ;-) And it's also because I didn't need that so far, as I decided to play all the levels as they were intended - without any saving. So it's: die -> start from scratch. I'm at level 75 now. :-)

As for the original engine: you could also try the Amiga version in UAE, maybe it will be easier. I don't know about the DOS files, but in Amiga version it was fairly easy to hex-edit the data in the files, one file was responsible for player progress and it was something like: 00 - unplayed, 01 - completed, 02 - skipped (totally guessing now, I don't have *that* good memory ;-). I remember that I made a special, custom font representing all game elements, created levels using text editor CED and then converted toe text files to Supaplex level files with arexx script. thus making my own, custom version of the game. So I'm 100% sure it was all about simple hex editing.
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

OK, I've now checked those levels mentioned using the original DOS Supaplex game engine (using Herman Perk's SpeedFix version, of course). For quick and easy testing, I've modified the levels in question to have Murphy immediately at the right position for testing, saved the modified levels in R'n'D, saved the native Supaplex file of the modified level using the ":snl" cheat (for ":save-native-level") and loaded it in Supaplex by entering "spfix63.exe # :file.sp" on the DOS command line for each level to test.

The (surprising) results: The encountered behaviour of level 69 (kill electrons with orange disk and get nine infotrons), and level 75 (infotron falling on top of the red disk makes it explode) are 100% original game engine behaviour!

To be able to test for yourself, just start "spfix63.exe" (which you can google and download) as described above with the test levels, which I have attached to this post.

Strange behaviour, isn't it? But it's really true and original...
Attachments
075b.sp
Modified Supaplex level 075 (second case)
(1.5 KiB) Downloaded 556 times
075a.sp
Modified Supaplex level 075 (first case)
(1.5 KiB) Downloaded 543 times
069.sp
Modified Supaplex level 069
(1.5 KiB) Downloaded 566 times
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Weird stuff. Is it possible that it worked differently in the Amiga version? I never played the DOS version, only the Amiga version and I'm pretty sure that killing electrons with orange disks only did not produce infotrons on the fields with disk explosion (with the exception of the central field where electrons stood), which made level 69 harder to complete (one had to work harder to collect infotrons in the previous room). With 9 infotrons from each electrons this level is fairly easy to complete. As for the infotron-falling-on-the-red-disk - it might be intended, I cannot vouch for that, I just don't remember it ever happening. One thing to remember, though: Speedfix version is *not* the original version, but a dis- and re-assembled one. There *may* be some differences. The Amiga version, on the other hand, is the "real original". ;-)

As I wrote before, those are not show-stoppers - level 75 is still completable, and level 69 is even easier - and player-made levels are probably mostly based on the speedfix version anyway, so it's probably a better idea to leave the engine as it is (e.g. some player-made levels depend on the "trick" that explosion of scissors that is triggered by electrons, produce infotrons as well - I don't remember such behaviour from the Amiga version).

[edit] On http://www.elmerproductions.com/sp/tricks.html it says this about yellow and red disks: "When a zonk falls on top, the disk does not explode, but when an infotron (or orange disk) falls on top, the disk does explode" (and for both yellow and red disks - it works this way in RnD). So this report of mine seems to be bogus - sorry. Unless, of course, this page describes the modified behaviour of the speedfix version, and not the original. ;-)
User avatar
Holger
Site Admin
Posts: 4178
Joined: Fri Jun 18, 2004 4:13 pm
Location: Germany
Contact:

Re: Supaplex engine bugs

Post by Holger »

First of all, you are right that the final reference for game engine behaviour should theoretically be the initial, original version of Supaplex, which was the Amiga version, while the MS-DOS version came later as a port of the game to the PC. Practically though, the whole "Supaplex fan scene", including additional levels, seems to be (or was) centered around the DOS version of the game, where "the game" was soon identical to "the SpeedFix version of the game" by Herman Perk. The later relevant incarnation of the game is "Megaplex", which uses the (nearly) exact same code (disassembled and ported to VisualBasic) of the game engine from the SpeedFix version. (The only difference in compatibility of "Megaplex" to the "SpeedFix" version of Supaplex is the use of bad memory accesses in the DOS version which was not emulated in Megaplex. The Supaplex game engine in R'n'D also emulates this, so there are a few levels that are solvable in the original/SpeedFix version and in R'n'D, but not in Megaplex.)

And you are right that it may be possible that there are game engine differences from the original DOS Supaplex executable to the SpeedFix and Megaplex versions, but I am pretty sure that Herman Perk did not touch the original game engine in such regards (like "infotron falling onto red disk" behaviour etc.).

But you may indeed be right that there are game engine differences between the Amiga version and the DOS version, but as most additional levels seem to be tested against the DOS/PC versions of Supaplex/Megaplex, I will take them as a practical reference for the game engine implementation in R'n'D.
User avatar
bojster
Posts: 458
Joined: Fri Jun 18, 2004 7:42 pm
Location: Poland
Contact:

Re: Supaplex engine bugs

Post by bojster »

Ok. :-)
Post Reply