How hard would it be to hack these racers?
Re: How hard would it be to hack these racers?
I was comparing 128k version running on machines with and without memory contention to estimate the performance cost of running some code in slow memory. I do not see any speed improvements on 48k machine.Old-User wrote: ↑Mon Mar 04, 2024 12:42 am So you have confirmed that 128K version does run a bit slower? That's really unfortunate.
(What about forcing 48k version to run on 128k machine as 48k version, i.e. , no ay, no bank switching? Assuming that's possible to hack would there be any benefit compared to a 48k machine?)
Re: How hard would it be to hack these racers?
@thealfest : I think I may have stumbled on a workaround to force 48k version to run on 128k machine, at least on emulation...
Can I send you a small file for you to test if it also works with you?
Re: How hard would it be to hack these racers?
@Old-User Sure
Re: How hard would it be to hack these racers?
As using the AY chip isn't as CPU-hungry as the beeper, I'm wondering if the 128k version plays faster.
Re: How hard would it be to hack these racers?
The weird thing about Outrun, which I’m surprised that nobody pointed out when it was released, is just how S-L-O-W the timer runs at. Like a second in the game timer takes about 2 seconds in real life. And nobody said “that isn’t right”. it’s also strange that the developers didn’t pick up on this, it’s like it’s supposed to be running at 2x speed but somehow when the game is finally running on the Spectrum it’s half speed.
Try it on 2x playback and it looks much better, but then the music isn’t right. It’s too fast.
Try it on 2x playback and it looks much better, but then the music isn’t right. It’s too fast.
Re: How hard would it be to hack these racers?
toot_toot wrote: ↑Tue Mar 05, 2024 5:00 pm The weird thing about Outrun, which I’m surprised that nobody pointed out when it was released, is just how S-L-O-W the timer runs at. Like a second in the game timer takes about 2 seconds in real life. And nobody said “that isn’t right”. it’s also strange that the developers didn’t pick up on this, it’s like it’s supposed to be running at 2x speed but somehow when the game is finally running on the Spectrum it’s half speed.
Try it on 2x playback and it looks much better, but then the music isn’t right. It’s too fast.
Alan Laird tells in the interview that the graphic density he decided to use in the game is responsible for bringing the game speed way down, sometimes 3 fps.
This must be true because a simple level like stage 2 (first left turn, the "dusty desert") runs much faster than the rest and plays surprisingly decent.
The timer is a good way to tell how fast or slow the game is running (cpu load/code execution?) since it cannot even keep with true seconds interval, it lags or speeds up according to the performance variation of the different stages.
However, there must be something else also responsible for the performance hit and it seems to me that has to do with 128k mode "engaging".
Even if a 128k machine is used and the lighter 48k levels are loaded instead of 128k levels the game still runs slower (than on a 48k machine).
If 48K version is forced to run on 128k machine the game plays as "fast" as the 48k version running on a 48k machine. I've tried and confirmed this.
Maybe there was not enough time to optimize the game for a 128k machine, overlooked some technical aspect that causes the additional slowdown or simply put "...but this game was never destined to be lightening fast."
Re: How hard would it be to hack these racers?
@Old-User
One "second" in outrun is just 10 frames (full screen updates).
One "second" in outrun is just 10 frames (full screen updates).
Re: How hard would it be to hack these racers?
The timer is probably just counting every X game frames, it's less accurate but fairer on a player since they don't get penalised for game slowdown that way.
I can't off hand think of a reason the game would run slower on a 128, especially not the 48K version. Unless it's still using the ROM interrupt handler (which takes longer on the 128) or is doing some floating bus thing on the 48 to give it more time for drawing and just disabling that code if it doesn't think it's a real 48K.
I can't off hand think of a reason the game would run slower on a 128, especially not the 48K version. Unless it's still using the ROM interrupt handler (which takes longer on the 128) or is doing some floating bus thing on the 48 to give it more time for drawing and just disabling that code if it doesn't think it's a real 48K.
Re: How hard would it be to hack these racers?
Yes it is 1/10th, you can clearly see it in "lap" line.
I`ve just measured speed again and there`s no difference in performance between 48k and 128k machines. For both it took about 11 videoframes (11/50 second) to render new game frame on average.
Re: How hard would it be to hack these racers?
Looking at Enduro Racer, which I’m going to presume uses the same engine as Outrun as it’s by the same authors, and while the timer isn’t exactly matched with a real world clock it’s still a lot faster/smoother. Plus it’s moving a lot of sprites around, the other bikes, trees, the various rocks as well as playing AY music and beeper sound FX.
It does make you think there’s a fundamental bug somewhere in Outrun that’s slowing things down.
It does make you think there’s a fundamental bug somewhere in Outrun that’s slowing things down.
Re: How hard would it be to hack these racers?
@toot_toot It is not a bug, Alan said that the game engine was improved in later games.
Re: How hard would it be to hack these racers?
Maybe I didn't make myself clear or... I'm just talking rubbish.
The 48k version of the game doesn't load normally on 128k machines. As far as I understand it checks the presence of the AY chip and changes to AY music/Fx and uses bank switching. What we get in the end is the enhanced 128k version, not the 48k version (beeper music /fx) running on 128k hardware.
But when forced to the game plays faster, or should I say, with the better responsiveness found on the 48k version.
The 48k version of the game doesn't load normally on 128k machines. As far as I understand it checks the presence of the AY chip and changes to AY music/Fx and uses bank switching. What we get in the end is the enhanced 128k version, not the 48k version (beeper music /fx) running on 128k hardware.
But when forced to the game plays faster, or should I say, with the better responsiveness found on the 48k version.
Last edited by Old-User on Tue Mar 05, 2024 7:28 pm, edited 1 time in total.
Re: How hard would it be to hack these racers?
@AndyC
But sprites in Enduro are much bigger and active screen area is also much bigger. I think the Enduro engine is just more advanced.
@Old-User
But 48k version is not faster than 128k.
But sprites in Enduro are much bigger and active screen area is also much bigger. I think the Enduro engine is just more advanced.
@Old-User
But 48k version is not faster than 128k.
Re: How hard would it be to hack these racers?
Ok, I cannot refute that. I'm not saying you're wrong. I don't have the knowledge to explain it in the same terms.
What I am trying to say is that, from my experience (and that is mostly playing the game on real 48k/128k machines), the 48k version always feels more responsive and "faster" (can't quantify that, 1 fps, 2fps, 3fps?).
It's not that much of a difference of course but my eyes tell me its moving less jerky.
Re: How hard would it be to hack these racers?
@Old-User
If there`s any difference you should be able to measure it. I recorded videos in emulator and compared them frame by frame. It is not very accurate but it is more accurate than just "see" or "feel".
By the way - 1 fps difference would be more than 20% for Outrun.
If there`s any difference you should be able to measure it. I recorded videos in emulator and compared them frame by frame. It is not very accurate but it is more accurate than just "see" or "feel".
By the way - 1 fps difference would be more than 20% for Outrun.
Re: How hard would it be to hack these racers?
128k version must be slower (there's more graphics)
Re: How hard would it be to hack these racers?
@goodboy
May be, I only measured speed at the beginning of the first level.
May be, I only measured speed at the beginning of the first level.
- PeteProdge
- Bugaboo
- Posts: 3595
- Joined: Mon Nov 13, 2017 9:03 am
Re: How hard would it be to hack these racers?
With Enduro Racer, they've not bothered with sprite masking - the pixels are just plonked on whatever's there, so that makes the graphics easier shift in a fast way.
Reheated Pixels - a combination of retrogaming, comedy and factual musing, is here!
New video: Nine ZX Spectrum magazine controversies - How Crash, Your Sinclair and Sinclair User managed to offend the world!
New video: Nine ZX Spectrum magazine controversies - How Crash, Your Sinclair and Sinclair User managed to offend the world!
Re: How hard would it be to hack these racers?
Outrun effectively has to calculate and render two roads all the time (it's how branching and highways work), which requires significantly more maths than the single road of Enduro. And the progression was Nightmare Rally -> Enduro -> Outrun, as evidenced by the interview with Alan Laird.
Re: How hard would it be to hack these racers?
Meanwhile, my first ever (and probably only one ) spectrum game hack is progressing.
No mock up!
Next step will be re-arrange the order of some stages to match course layout of international version of Outrun.
And finally change the color of the road on some of them to a more suitable one (above - stage 1, coconut beach - is now bright yellow instead of green ) given the limitations of the spectrum palette.
No mock up!
Next step will be re-arrange the order of some stages to match course layout of international version of Outrun.
And finally change the color of the road on some of them to a more suitable one (above - stage 1, coconut beach - is now bright yellow instead of green ) given the limitations of the spectrum palette.
Re: How hard would it be to hack these racers?
All right, order has been altered and color changed on some of the stages:
- Gateway is now white;
- Wilderness is now dark yellow;
- Alps is pink;
- Seaside Town is bright cyan;
Also, I've been trying to change key "M" for "Space" because it's better on 48k+ or +2.
I've located the routine and managed to set new key but the change isn't permanent. It seems to default to "M" if called again.
- Gateway is now white;
- Wilderness is now dark yellow;
- Alps is pink;
- Seaside Town is bright cyan;
Also, I've been trying to change key "M" for "Space" because it's better on 48k+ or +2.
I've located the routine and managed to set new key but the change isn't permanent. It seems to default to "M" if called again.