Submission #4661: FatRatKnight's NES Rad Racer in 20:32.89

Console Nintendo Entertainment System Emulator FCEUX 2.2.2
Game Version USA Frame Count 74095
ROM Filename Rad Racer (U) [!].nes Frame Rate 60.0988138974405
Branch Rerecord Count 12671
Unknown Authors FatRatKnight
Game Rad Racer
Submitted by FatRatKnight on 4/19/2015 12:27:42 AM

Submission Comments
Today, our racer probably breaks a few traffic or racing laws by frequently using other cars as springboards.
This run beats Saturn's TAS (78959 frames) by 4864 frames, however our goals aren't identical.
  • Emulator: FCEUX 2.2.2
  • Aims for fastest time
    • Doesn't care about high score, hoever
  • Contains subtitles
  • Genre: Racing

About this game

Get to the end before time is up. Honestly, is there a need to attach a story? Square did a pretty good job with the graphics, since the 3D effect is very smooth, which is saying something about the NES. As important as it may be to go fast, careful steering and braking will ensure you don't go crashing off the side of the road in a hurry. To add to this, you're not the only car on the road -- Watch out for other cars, as they may send you swiftly off the road if you're not careful, or in more extreme cases, make you crash outright.
I remember this game as a childhood memory. I did get pretty far, even knowing a trick to continue the game when I end up losing, which was frequent. I don't recall if I ever made it to the ending, though. Still, this has given me some pretty decent memories, and I still have got to love those times where my car just inches to the next checkpoint long after the timer has expired. The game certainly feels simple and rather polished, controls are pretty intuitive for the most part, and it's got some music I find difficult to forget.

About this run

Hmm... Not a whole lot to say, really. Stage by stage comments aren't useful in my case, as I can't really give any good diverse statements, since I used the same basic TASing pattern to try to get through all the courses. Namely, heavy use of TASEditor and trying to figure out this crazy maze of cars.
I also have a script for FCEUX. I don't need to say that it's something I produced for use with TASing this game, and obviously it had what I need, since I made the script myself. There's a lot of information to absorb, though.


As I can't get Saturn's run to fully sync on FCEUX, a stage by stage comparison is difficult. I have not tried getting FCEU running on this computer, however.
My file may be shorter by 4864 frames, but the main difference in goals here is that I brake before clearing the finish line while Saturn gets as much score from extended distance as possible. I don't know the exact frame difference of this choice, but making an estimated 220 frames per course (very rough guess; May be off by 150), for 1760 frames of savings, that leaves 3104 for more optimal driving. Most of which is handling the CPU cars better.
I do believe there are grounds to obsolete Saturn's run with this one: A no-pause high score run would be slightly less optimal than this run; A run that maximally abuses the pause trick will also have less optimal traffic, but will certainly hit max score from keeping the time remaining frozen indefinitely, but lets not forget the frequent blips it makes. A sample of using bare-minimum effort to get maximum score for course 1. Saturn clearly didn't know the full extent of the pause trick while making his run, though.

Pause trick

Just pause and unpause the game. This will adjust how timer-based cars spawn. No effect on lanes with zero timers at the time of pause.
However, pausing like this costs a minimum of four frames, and will cost another two frames at the goal if this was done to delay timers, due to having more time to count at the goal tally. Great for casual play when you need more time, but not so great for speedruns.

Traffic Manipulation

Obviously, there are other cars on this road, not just you. They are also traveling along at a rather high speed, too, and have absolutely no trouble at all staying in their lane, no matter how much the road curves and no matter how hard you slam into them. Since your car is a suitable pinball when colliding with them, it is to your best interest to drive into them when you can't take the next curve at full speed, in TAS conditions, of course.
Cars are generated as follows:
  • A timer, ticking exactly like your "time left" indicator, determines when they spawn.
    • This timer was observed to be 0, 2, 4, 8, 16, or 32.
    • The timer is reset and changed to a new value at certain distance benchmarks.
  • When the timer reaches zero, spawn a car somewhere ahead of you.
    • Speed is some base value plus a random range.
    • This base value and random range is based on your location in the course.
Cars change lanes at times:
  • Each lane has a frame timer. When it overflows, an adjacent car might change lanes.
  • This timer runs faster on later courses. Increments by 1 every frame on course 1, but by more later on.
  • A specific distance range (64~101) is also required for a car to change lanes.
  • They must also be visible -- Hills can block visibility, as well as being on the opposite side of road when near.
Now, nearly all forms of manipulation require you to lose speed:
  1. Cars disappear when they are far enough ahead of you or get behind you
    • Obviously, for them to get that far ahead, you must slow down.
    • Change your speed to change the timing behind you; Only way from 255 kph is to slow down.
  2. Adjusting the timer by pausing obviously takes time: 4 frames, or 6 if it saved a "time left" tick.
    • Pausing is unavailable as a manipulation tool if cars are using a zero timer.
  3. The random speed factor only advances when a new car is generated.
    • The above manipulation always costs time, and must be done to affect the random speed.
  4. Reaching distance thresholds at different times requires different speeds.
    • 255 kph is the max speed, so obviously, different speeds are all slower.
    • These thresholds may change the timer or speed of upcoming cars.
  5. Colliding with cars can affect their speed.
    • However, hitting their back slows you down to their speed minus one, and is the only way to adjust their speed.
    • Hitting their side has no impact on speed.
    • Hitting their front may get them to disappear sooner, but useful situations (doesn't knock you off-road AND isn't already necessary to go fast AND lane uses zero timer or is at the right timing for a "tick") basically don't exist.
So in order to adjust traffic, you must slow down at times. Pausing delays you, brakes are needed to get cars to disappear ahead of you, and also to get them to disappear behind you later, and bumping their back to speed them up slows you down.

Collision effects

Sends you right
CPU moves 3 units back
CPU speeds up 8
Sends you left
CPU moves 3 units back
CPU speeds up 8
Sends you left
Sends you right
Sends you right
CPU moves 5 units forward
You slow to CPU speed-1
CPU slows by 8
CPU gains some speed
CPU moves 2 units forward
You slow to CPU speed-1
CPU gains some speed
Sends you left
CPU moves 5 units forward
You slow to CPU speed-1
CPU slows by 8
CPU gains some speed
The boost to the CPU car speed depends on how fast you crash into them relative to their own speed. In a special case, if your relative speeds are too great, you instead make a hard crash like hitting a road-side obstacle, with this tolerance going down at later courses.
The special case isn't completely bug-free. If you are "too deep" into them, you are instead safe for the next frame, with the following effects: You are sent toward the opposite side; The CPU car is pushed forward a number of units; The CPU car may slow down 8 kph; Your speed is unaffected; CPU does not receive boost from your speed. I don't know the measure of this "too deep," but at around frame 51500, I've slammed into the back of a car going too slow, stayed "inside" this car (merging traffic, yo) until its speed underflowed and all of a sudden I have a fast companion CPU car to abuse.
One can also get the effect of the wrong side of collision by driving fast enough into their side for the game to count you as on the other side of the CPU car. You'll need a strong curve, however, and the only reason I got it in course 3 is due to a mistake, really. These collision glitches need further examination.
On a side note, the speed up they get when you hit their front hardly matters, as due to the push back they get, they will almost certainly disappear behind you two frames later. If they're going fast enough, this can also overflow their speed.

Possible Improvements

I will not like it if you trim off some end frames. My goal choice is minimizing the time needed to reach the ending, not minimizing the input file length. Note, the two goals in this case are incompatible, as while I can allow the car to begin coasting over six seconds earlier, it doesn't brake effectively at the goal, taking about 2.5 seconds longer to reach the ending screen.
However, there are over three seconds of known improvements to the first course, largely due to fetching a fast CPU car before the long stretch where the RNG speed is reduced to 63 and the spawn timer is 32 seconds. The reason it isn't implemented in this run is that it desyncs course 4. I made a promise to someone that I will submit by today if I haven't finished the course 2 improvements. If I never go back to work on it, there will, at least, be an improved published run (I hope), and some information on how to improve things further if someone gets the time.
Remember this FCEUX script. I have put a fair amount of effort in getting and understanding the information inside the game. The information this script provides will be virtually essential to have any chance to improve any course. I wouldn't be surprised if there's more potential information to display, especially since I can think of one good facet to look into, but building on something might be easier than starting from scratch.
And, of course, we shouldn't forget there are glitches I'm aware of, particularly collision errors, that need further examination.
Suggested screenshot: Frame 51574 - Warning: Merging traffic

Noxxa: Judging.
Noxxa: Accepting as an improvement to the published movie.
Spikestuff: Publishin'.

Last Edited by on 1/1/2022 6:14:14 PM
Page History Latest diff List Referrers