CD-i may not have the best reputation on the internet, but that doesn't mean there aren't any good games.

In my opinion one of the best games on the console is The Apprentice.
As a project I have remade this game in Unity and can be played for free here.

During the course of the project I have made several tools that can decode information stored on CD-i game discs. A bunch of which I made maps of.

Many of the games I played had big areas that you either couldn't fully explore or were difficult to even reach, if you could even reach these areas. Micro Machines and Dimo's Quest are just two examples of games that have places you can't reach. Games like Family Games' Full Attack were notoriously difficult to complete. Of the four levels I never got past the third. The same goes for Buzz Off on Family Games II; that one has eight levels (of which I never saw the last five)! Sometimes the map is seamless, but divided into screen-sized sections. One such map is present in Zelda's Adventure; easily the most beautiful game available on CD-i. Where else do you find realistic graphics on a '90s console? I know there are versions out there, but they're all scaled down or crappy in quality (damn you for using JPEG!). Another aspect many people don't realize is that a lot of games have secrets, or other hidden features that aren't easily revealed. Lucky Luke has transport points in each of the maps where you're not riding Jolly Jumper or a minecart!

I've spent quite a bit of time trying to map these games, often finding new things.

I'd like to share these findings.

18th of December, 2019, at 19:03

hroughout the years I've had a pet project going on a slow pace. Sometime during 2010-2011 I started working on it.
As with most hobby projects, they either take a long time to get anywhere, or simply never see completion.

It started as a simple challenge "Can I build a collision engine for a 2D platformer?". I began to answer this question in Excel so I could see one step at a time what would happen.
Having read this article that contains some technical data on how The Apprentice engine works I started out trying to replicate that. By that I mean a pixel based collision detection.
Long story short: don't.
So I took the math path, restarting from scratch at least 4 times before I got something simple, fast, and reliable enough to continue.

Once my engine sputtered into life and kept going reasonably strong, the time had come to get the assets from the original. My first attempts were getting my only the larger images like backgrounds, not the level tiles or character sprites.
This was a complete project on itself and I won't go into too much detail. Just that I gained so much insight into how CD-i can store information, and that many of the other games I looked at have had their levels layout converted into images.
The formats I found on the various CD-i discs:

And some of the compression methods used:
- CADPCM (a compressed version of ADPCM where one channel is spread to two channels, halving the length of the audio and therefor the stored data)
- ICE!

The new extractor programs I created were written in PHP and although they weren't fast, they got the job done. All of them required me to create input files with raw data; nothing was automatic or 'smart'. Each file contained either a set of equally wide images (CLUT) or a batch of sprites (ASM).
It took me roughly three or four months to get most the assets extracted from the game. A very painstaking process.
Most of the assets I had at the time were stored in CLUT, ASM, or CD-DA formats. I hadn't found any in the other format, or hadn't recognized it as an asset (you'd be surprised how much data I don't recognize).

Now that I had tons of images I could actually start construction on something that would become a game. For reasons I might reveal later my choice was Director, a program by MacroMedia and uses Lingo as its programming language. My engine was transformed once again after a few tests and continued to change little by little to get rid of the last bugs.
Somewhere in early 2017 this resulted in a major breakthrough, enabling me to:
- read the original level data (all three layers)
- create the required platforms and walls per tile (200 rows, 16 tiles per row)

I was ready to program more than a basic platformer; keep in mind all I had was Marvin (a square with a black border to I could see exact pixels), a bunch of platforms and walls, and a scrolling screen. No item, enemies, animation or any kind, no working statusbar.. just a movable Marvin.
It was time to add a ton of gameplay functionality.
Late in 2017 I returned to decoding more data from the disc; I found I lacked sound effects and they had to be somewhere! First I needed an audio decoder though.. decoding CD-DA to WAV was done by a pre-existing progam.
In this thread I went into great detail describing how to build one of these ADPCM decoders. CADPCM is also described there.
Armed with both decoders I quickly found my missing sound assets and continued building my game.

In 2018 around March the resulting game was far enough completed that I revealed its existence.
Cautious as I am, only videos were ever released showing actual gameplay (no post-processing whatsoever). Over the course of a few months many changes were made to get closer to the real game.
Once that was roughly completed I wanted to release it, but there was still the matter of legality. Releasing the game as it was at the time would have definitely broken the copyright laws.

At the time the game had all its images, sprites, sound effects, and music on-board (like all games). Those assets are what made that version quite illegal.
So I set out to make it a gray-area by requiring a copy of the disc to work.
The software (and language) my version of The Apprentice was programmed in has poor support for the methods the asset extractor uses to get the assets from the original game. In that aspect Director hasn't aged too well.
All preliminary tests had bad results: very slow or unable to do what needed to be done. I had to do this in a new environment: Visual Studio (programming in C#).
Re-purposing an extractor that had up until then been mostly manually used was quite the challenge! Not to mention the small adjustments I made to better use the resulting assets.. the program now had to do them.
But with the help of the Full Functional Specification Green Book and half a year of time, I had a new extractor program. One that would do what took me months in less than a minute.
Hooking this extractor up with Director wasn't too difficult: a little batch (command line) file.

My remake of The Apprentice now required three files:
- The game
- The file extractor
- A copy of the original disc (an IMG/ISO)

All required assets would be extracted to the hard drive before getting loaded into the game (and then deleted from the drive). A small yet crucial step was still bothering me.. those files had to be stored onto the disc first! And the extractor could be abused.
Once again I set out to see if I could somehow integrate the extractor in the game (save the assets in memory rather than disc) and ended up looking at Unity.
I'd played games created with Unity before so I knew one could do great things. The fact that it's language is C# was a big bonus: I could almost copy-paste my extractor! Also for a hobbyist it's free to use.
Having done a bunch of experiments with it to see if Unity could do the necessary things (answer: yup) I set out to translate ALL my Lingo code to C#; a process that would take over two months and more than a few missteps.

The result? A game that has everything integrated and is safe to release to the public.

Yep, you read right: I'm releasing The Apprentice!

For more information I refer to my posts on the CD-i forum.

I remade a game.
Care to play?

Download the game here

4th of February, 2021, at 00:37 | # | Rate up0 Rate down| Reply
Hello! I just got your free conversion of \\\"The Apprentice\\\" with the downloadable ROM image. I like the game itself. However, I have a question. How do I make the screen larger?

Get a Gravatar

NOTE - You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> [spoiler]