Monday, July 14, 2014

Tile Editing

One of the problems with CannonBall feature development is that many of the remaining tasks are hard to achieve. Take the music selection screen for example; it's one of the parts of the game that isn't widescreen and remains letterboxed.

Now it would be easy to simply drop in a replacement graphic at this point and bypass the original code to display it. In fact many people have sent me such an image over the last couple of years in the hope I would do just that. But that's not really true to the ethos of what CannonBall is about. The real solution is to extend the original tilemap and use the tile layer to render the screen, rather than hack in a replacement.

Unfortunately, this approach needs a full tile editing tool, which is a rather complex way of achieving something that will look no different to the end user. Nevertheless, I'm writing such a tool so that tilemaps can be edited, new tiles created and the screen finally widened.


Currently I have the ability to import the music selection tilemap, edit tile data and edit tile maps. I'm in the process of creating the new tiles to extend the image to widescreen. As you can see above, the right hand side is relatively easy to extend and I'm just starting to tackle the more complex five columns on the left hand side. 

OutRun contains plenty of unused tiles, which can be replaced for this purpose. For example, the larger Space Harrier font exists in the tileset, which is of course unused. 

Now that tiles can be edited, I can also move on to create HUD graphics for the High / Low gear change, a MPH display and so forth. The next version of CannonBall will feature these improvements. 

UPDATE: And here is the final result in CannonBall. The observant among you will notice that I've based the new tilemap on the 3DS version. 


It was a lot of work for something that looks simple. One of the complications with the System 16 tilemap format is that bits have a shared usage, that I'd previously overlooked. After all, the complications of it don't really matter when simply rendering existing data. For example a typical word of the tilemap is configured as follows:

 MSB          LSB
 ---nnnnnnnnnnnnn Tile index (0-8191)
 ---ccccccc------ Palette (0-127)
 p--------------- Priority flag
 -??------------- Unused

As the index and palette share bits, this locks tiles to certain palettes dependent on their index. Therefore the previously identified unused tiles are not usable. Instead the new tiles end up being scattered through the tilemap from location 4096 onwards. I also had to create new palette entries to map to these tiles.

This explains why Sega games have tile duplication, where the same tiles appear multiple times in the graphic roms. It enables them to be used with multiple palettes. In practice I can't help but think it would have been simpler to double the tilemap memory, thus giving the palettes their own distinct bitrange and avoiding tile duplications. I guess this may have been a cost saving measure.

Tuesday, July 08, 2014

OutRun Unidesa PCB

Here are some relatively high quality photos from the Outrun PCB manufactured under license by Sega to the Spanish company Unidesa. You can click on the images for a larger version and then right click to save a high quality version.

Close up of the top left of the CPU PCB


Manufactured 5th May 1987

The main difference with the licensed PCB is the ribbon cable used to connect the two boards, as opposed to the direct connector on the original. 


The connectors are also slightly different, although I believe they are wired the same. The black connectors below are the power connectors for the two boards. 


Here are the connectors on the video board:


Here is a picture of the top CPU PCB. I haven't separated the boards to get a shot of the Video PCB yet.


I haven't powered up the board yet, but I'm told the ROMs are identical to the standard Revision B version. More information on this version of OutRun can be found here.

Tuesday, July 01, 2014

OutRun Enhanced Edition 1.10

A new version of OutRun Enhanced Edition is out. This is the enhanced version of the original OutRun ROMs, designed to be programmed and used with the original hardware. This version includes some new features and fixes from Adrian Smethurst.

There are selectable timing system fixes; 60 seconds on the lap timer represents 60 genuine seconds in real-time and the correct time when passing the Checkpoint when EXTEND TIME is shown.
 
The timing system fixes can be toggled in the Diagnostics mode in the Dip Switch assignments screen by moving the gear stick. Your choice will be backed up when the machine is powered down.



There are improvements to high-score inital entry system. Backspace can be used over the final initial to match many other Sega titles.

The Last Wave music is also added as an option to the sound test menu.

The timing system fixes will also feature in the next version of CannonBall too for those interested. 

Tuesday, June 17, 2014

CannonBoard Hardware Update

Colin is busy at work with the latest iteration of the CannonBall hardware. He's constructed a bare bone version of CannonBoard using the new board designed, and programmed with the firmware that we prototyped on the previous Arduino setup. 

Currently it's a minimal setup, with only the essentially components soldered into place (the CPU, the RS232 level shifting chip, some debugging LEDs, the resistors and capacitors). All looks good so far. 



Thursday, May 01, 2014

Super Mario meets Super Hang-On

This is a fun hack from Adrian Smethurst. As might be expected, it turns out that the audio engines for Super Hang On and OutRun are very similar (both FM synthesis and PCM sample playing). With a lot of patience and some reference to these blog posts (which I never expected anyone to find that useful), he managed to replace one of the tunes in Super Hang-On.



He actually inputed the new music by hand - brave man! Adrian adds:
I downloaded the sheet music from mariopiano.com and set about on the most pointless 8 hours of my life!  You can get away with doing that when you're only doing one track for a bit of fun, I wouldn't recommend it for anything more than just that though!
Adrian has also been working on some fun hacks using the OutRun Enhanced tools. I'll post these at a later date once I've integrated them in the package. 

Sunday, April 27, 2014

CannonBoard Latest Hardware Design

Colin is continuing to make great progress designing the CannonBoard hardware. Below you can see the latest iteration. You'll note that the Arduino is no-more, and a CPU fully integrated with the design. So to use CannonBall in a cabinet, you'll need a PC, the CannonBoard interface, and a VGA to CGA card / Ultimarc Arcade VGA or video card with soft 15khz.

It's possible that I'll port CannonBall to something like an ODroid so that you don't even need a bulky PC but that will come later.


I've been implementing some diagnostics options in CannonBall that will make it easier to work with a real cabinet. Not particularly exciting, but certainly useful. 

The outputs, including the start lamp and brake light should also now be hooked up.




Wednesday, April 23, 2014

3DS OutRun

M2's version of OutRun for the Nintendo 3DS is out in Japan. M2 have done a fantastic job with the previous SEGA ports, so it's exciting that OutRun has finally made it. Playing these titles in 3D for the first time is an awesome experience. This is also the first new port of the original OutRun for around ten years.



Whilst I haven't tried the 3DS version yet, I've checked out the videos and information online. There's a good interview with M2 in Japanese. Part 1 and Part 2.



There are plenty of solid features: 3D graphics, 60 FPS gameplay, widescreen mode, optional car colours, car handling settings and the usual difficulty and time DIP switch options from the arcade machine.

In terms of bugs, interestingly, M2 opted to fix the timing issues that we discussed in a previous post. However, the arcade mode uses the original timing. It's a confusing way of doing things I think as it creates two separate OutRun timing systems. The sprite scaling bug is fixed and the level object issue with the broken Gateway arches also appear fixed. Regarding the audio, the corrupt PCM samples are fixed.

So, you're probably thinking - is this the best best version of OutRun ever? Unfortunately, there are a few drawbacks if you're looking for a truly faithful experience. The biggest gripe is the Ferrari substitution, an inevitability due to licensing issues.


Whilst the car is purely cosmetic, it's also THE memorable graphic from the original game. It would be disappointing to replace Sonic the Hedgehog with a blue badger for example, even if the gameplay was identical.

Other graphics that have been changed include the Porsche graphic, which has had the spoiler removed.


The Marlboro lookalike sign on the start banner has been altered further to differentiate it from the cigarette brand. I spotted a sign that had been edited to contain an M2 logo also. 



There appears to be a sprite clipping bug on Stage 2 with the large stone graphics. It's possible this is an optimization to help the game run faster on the 3DS, but the large stones are disabled as they get closer to the camera. It's also possible M2 forgot to update a hard-coded value in the drawing routine for this object for widescreen displays. 


The shadows also seem to be too dark, so I'm not sure what's happened there. Maybe a palette optimization with the translucency for speed purposes on the 3DS? The Saturn conversion got this right, so I'm guessing it's not an oversight.  



Regarding the extras to change the car handling, I have mixed views on their merits and will wait to see how they play. Maybe being able to bump into traffic with no ill effects, drive off-road at full speed, grip corners more tightly and drive at a higher speed will be awesome and add a new dimension to the game. Maybe these are just cheap and easy features for M2 to implement! ;) Either way, they are pretty easy additions to CannonBall if they prove to be popular and there is a genuine demand for them.

In terms of a commercial OutRun release, this is probably as good as it's ever going to get so please buy a copy when it's released in your territory and show M2 and SEGA some support.

I'll keep this post updated as I find out more information!