Wednesday, December 24, 2008

A saga about SAGA

I wanted to tell this story for a quite long time. A draft of it was sitting on my HD for couple of years. And now, there finally it is. A piece of ScummVM story, a saga.

All of this started back in May 2000. Daniel Balsom was so delighted in furry Inherit the Earth game, so he began to peek into its executables in order to make it run on his Windows XP. YARN (Yet Another Remake? Nifty!) was born. The aim of this project was to run both Inherit the Earth and I Have no Mouth and I Must Scream, though practically straight away he switched to The ReInherit Engine, supporting just the first game.

I may say that it was a horrible time. Daniel ran original game with DOS Debugger and tried to figure out what is going on there, staring into a hex editor and documenting it on sheets of paper of different sizes and then attempting to curl his head in order to write C code. He told me that there was a big pile of those papers and he even offered to scan them. Ugh!

In some time the game intro was showing with handful of bugs, but next real world event killed the work. Original Inherit the Earth director, Joe Pearce, announced that he acquired full rights on the game and that there is a re-release in the works, compatible with Windows XP. Thus, whole purpose of the ReInherit project was voided, and Daniel was discouraged to continue any work on it. It was around December of 2003 when last commit to the engine was performed.

As soon as in March 2004 I found this abandoned project and offered Daniel Balsom to join our team. He was pretty busy at that time (and still is), but offered his help as a consultant. We got his sources, ported it over to OSystem (core of ScummVM hardware abstraction layer), then started to map out functions in Interactive Disassember.

In parallel I tried to contact Joe Pearce of Wyrmkeep and inquiry about the game engine soruces. Daniel told me that he already tried to contact Joe about a year earleir, but that was exactly the time when Joe was in process of the game rights clearance, so obviously, he was not able to pass any game materials. We thought it was a fat chance. Mr.Pearce was not fast with replying my mails, but suddenly, at end July 2004 a miracle has happened. We were given complete sources for ITE!

Thus, we closed our IDAs and started to look straight into C/Asm code of the original. According to the accompanying license we could not use more than 5% of original code verbatim, that's why instead of porting original code we continued to work with ReInerit codebase and fix it along the way.

I found a guy from Russia, Andrew Kurushin who joined our team in December, 2005 just for helping us with the engine. After a year of work, in August of 2005 we finally announced support for Inherit the Earth game.

After completing support for ITE we decided to pursue the ultimate goal of YARN, that is to support both games of the engine. Thus, work on I Have no Mouth and I Must Scream started. This time we did not have any source code. The engine developed quite a lot, but still it was the same. I started very slow and time consuming work of mapping it out. Pretty quickly we stuck, as there were subtle changes in actor handling which prevented game from playing, and actor code is one of the most complex in the engine.

The work was practically on hold for 2.5 years until June 2007 when Filippos Karapetis joined us to resume development. During that period I tried to encourage developers to help me with the engine, but due to complexity of the task, I did not succeed. Andrew became superbusy with his real life, and I had much of other work to do with ScummVM.

Filippos lead the development by a huge leaps. No longer that just in 3 months I Have No Mouth was announced as supported and that is without source code (!).

This was story about SAGA (Scripts for Animated Graphic Advenures) engine. But it continues even today. There exists SAGA2 engine, on which games Dinotopia and Faery Tale Adventure 2 are based, and Filippos recently started to0 work on them. We also got source code for FTA2 on a similar license as ITE, and I hope that pretty soon yet another couple of games will be added to ScummVM collection of fine games.

Tuesday, July 22, 2008

0.12.0 has been branched

Basically that means that there are just a few days that Tinsel engine will be in SVN. No, 0.12.0 will not contain it, as the engine is too raw, and there are still some legal questions to resolve.

I really hope that this will not interfere much with the testing season, as it will still not appear in the daily builds. But for our porters it will mean that we the compile-testing ;) will start on it for all supported platforms which will let us work on the portability issues. Read More...

Thursday, July 10, 2008

Discworld: A Smooth Tale

Here is a short note from one of the playtesters:

"I have played Discworld on an 80486 originally and then a Pentium and many years later on DOS Box and I can say without any doubt that the ScummVM version is the smoothest and most pleasurable Discworld experience ever!

Congratulations to the ScummVM team for such a wonderous achievement in such an early private build of the engine." Read More...

Wednesday, July 9, 2008

Discworld: End of game

Here it is. It was made just yesterday with current code base. Libcoro was so non-portable, that it did not work well even under Windows. Now when it's gone, we're portable enough, so we expect it to work across all ports. Read More...

Tuesday, July 8, 2008

Goodbye, libcoro, goodbye

Our Tinsel team finally got rid of unportable libcoro in the favor or method described by Simon Tatham here. This means that soon, very soon Tinsel engine may appear in the SVN trunk.

I do not have an end game screenshot handy, but I suppose that you will be able to produce it by yourself pretty soon.

So, yet another important part of adventure gaming history will get a second life soon. Read More...

Saturday, June 21, 2008

Discworld1 is completable

Yes, it has been less than a month, and Discworld 1 is completable. Actually it is completable since last Sunday, just afer 215 commits. Now the commit count is 320, as the Tinsel engine team works pretty fast. It has been mentioned on the forums that there are few glitches and some portability issues (mainly endianness, 64-bitness and alignment), but the engine itself is in a very good shape.

Though don't ask when the engine will land to trunk. There is a major task ahead, that is engine rewriting. Yes, that's right. We chose a most efficient path of adopting, that is take original sources and port them quickly to ScummVM OSystem. But the code now reselmbles original a lot, and this is a big no-no according to our license agreement with the rights holders. So we have to refactor it, rewrite, and get rid of those co-routines, which will make the engine wastly different from what we have now. And only then we will go public.

Next target is DW2, and perhaps we will integrate it before the refactoring will finish, granted that we will get hold of it soon.

Anyway, this is already a really exciting news.

Thursday, June 5, 2008

ScummVM Goes Wii

Today we finally accepted patches by dhewg which implement Wii port of ScummVM. It is one of long awaited ports, and we're happy to have dhewg onboard. That means that this port will be official with our next release, and that users of this port can get some help even now. There has been created another subform specially for port-related discussions.

It is yet another great platform, and I myself witnessed one more time how portable ScummVM is. I will truly need that experience to myself pretty soon, just when that package with some cool  gadget will arrive and I will start hacking for it :) Read More...

Tuesday, May 27, 2008

The D-Day


Thursday, May 22, 2008


Yes, we finally reached it. 4,000,123 official downloads (at least). It was a good time, and it was fun time to watch its progress.

This number comprises of downloads of only ScummVM binaries from servers. It it is 8.9 TB worth of data since October 2001. Wow, I hardly imagine who could host that for us for free besides SourceForge. That is a definitely great service.

If you talk about all ScummVM downloads from, including game data and cutscene packs, the figures are a bit more scary and that is 5.3 millions and whopping 61.7 TB. Unbelievable. This truly shows that ScummVM is one of the most successful open source projects in the world.

I hope that downloads will continue increasing, especially as we add more supported platforms and yet more supported games. Keep downloading! Read More...

Monday, May 12, 2008

(almost) Glitchless Boozooks

Someday I am going to translate that long letter of mine from Russian to English and tell the world true story of gob engine in ScummVM.

It used to be called dso module, and we are still not sure how it was called originally. In these days DrMcCoy drives most of the effort, he is our expert in this engine, dealing with its both graphical and code-wise weirdness.

Gob3 support was lightning fast because there are not much changes between those generations of the engine, but Woodruff made Sven stuck. Plainly stuck for several months. He could not dare to decipher hundreds of cryptic routines which deal with VMD movies playback, and since Woodruff is all about running those VMDs all over the screen, the progress was just zero.

However, recently there happened to be a breakthrough. He decided to ignore most of that code after he found out that it deals mostly with caching, as original game was intended to run directly from CD-ROM. After ignoring that and adding like 700 lines of code, he finally figured out most of the differences and is routinely moves forward since that. Among the things which were implemented recently are scrolling, text positioning, proper hotspots, sound in object videos and saving/loading.

As a side effect, The Last Dynasty intro is now playable, so it was added to detector. It may happen that we will see Woodruff completable (albeit with glitches) in nearest time.

Saturday, May 10, 2008

There is no Kyra4

That's truly amazing, but just in a slightly more than a month of development time, Kyrandia3 is playable until completion. Of course, there are lots of bugs, and the engine is not yet mature enough to be announced as supported, but the progress is enormous. Both LordHoto and athrxx added over 16,000 lines of code to kyra engine since 0.11.1.

There is no Kyra4 for them to continue their extraordinary work, as they seem to be on wave, but there are already certain plans from both. :)

So I suppose that pretty soon whole The Legend of Kyrandia series will be fully supported.


Thursday, May 1, 2008


"Never pay more than 20 bucks for a computer game."

How laughable are these words when you look at this auction.

Yes, it is FM-TOWNS version of Zak McKracken, a game which originates from same folks whom I quoted above. And this game is being offered "just" for 599 EUR. With today's rates it goes as much as $932 USD. What amazes me even more is that shipping for this piece of art is not free, neither there is an insurance offered as a default option.

All of this is sad. Only couple of folks in ScummVM team own this game, and moreover, one of the owners is not active anymore. This makes even more difficult to squish bugs in this particular version of the game, and most of the work will go blind. Of course, we ourselves could be somewhat blamed for these rocket high prices, as this is basically the support by ScummVM what makes this item so popular on eBay.

So, never pay a grand for a computer game. Read More...

Monday, April 28, 2008

Still not perfect but good enough

Further investigations and comparisons finally lead to success. Now Japanese DIG looks very close to original. There are still slight differences in how the subtitles are positioned on the screen, but I consider it as a good enough (ScummVM is on the right):

Our code differs too much from the original Blast Text rendering routines, so to make a pixel perfect rendeting I would need to rewrite all of that code. Still I consider it to be good enough and if someone else in the future would want to tickle it a bit more, he is welcome.

Besides Japanese Kanji fixes, new code also fixes line breaks in Korean and Chinese versions of SCUMM 6+ games. I did not test it, but with old code there were cases when longer strings were not split in a proper way. As a side effect there are slight changes to versions which use Latin characters, so there could be potential regressions. File a bugreport if you will notice any chopped subtitles in FT, DIG or COMI. Read More...

Saturday, April 26, 2008

Kanji got more fixes

Finally I managed to make all Kanji in Japanese DIG rendered. 

It appeared that somebody (ahem) just is not able to count, even with help of a calculator. 
japanese.fnt was not read completely and thus it got read past the array bounds.

Still there are certain problems with rendering. As seen on the right screenshot, proper line breaks for Kanji just do not work, also text positioning is not perfect. I am still in process of comparison with original, and the code there is quite hairy. Stay tuned. Read More...

Tuesday, April 22, 2008

GSoC 2008 students announced

Yesterday final list of Google Summer of Code was settled down. Six students for ScummVM this year, and they have exciting skills.

Christopher Page will drive Return to Launcher / Global Savestate task. It is a long awaited one, when users finally will have possibility to return to launcher after their game play. The main obstacle with this feature was that the engines did not clean up after themselves well and produced leaks, instability and all. There was an infamous commit from Endy four years ago to loop the launcher which was revoked in a half year and lead to certain controversy, but now we are going to get a proper support for this feature. Additionally the student will implement loading of save games from the launcher, will add support for thumbnails view to all engine saves which will add more to ScummVM experience.

Next task is.... FreeSCI plugin, ta-da. Sami Zerrade is the student for it. Again, this does not mean that FreeSCI will be merged into ScummVM. It is some kind of a cross-project task and most of the code will land down in FreeSCI repository. Of course, it will require ScummVM OSystem to be somewhat extended and perhaps our make system rearranged a bit, and this will bring two projects close as never before. Basically if the student will be successful with his task, FreeSCI project is going to turn into an external ScummVM plugin and will have most (all?) of its hardware abstraction layer stripped down in favor of ScummVM OSystem. We think that perhaps we will share even the port builders between the projects, but this all is need to be discussed in more details first. In short, see FreeSCI on NDS and PSP soon!

GUI overhaul is an exciting task by Vicent Pere Marti Guardiola. The goal is to turn our GUI into vector based format, add TTF font rendering, perhaps add some way to easily translate the interface and tons of other rewrites. API will stay as is, or will be minimally changed, but we expect that GUI will be much more flexible and configurable. Another goal is to make it scalable enough so that even smaller ports like NDS and SymbianOS could run it.

Stephen Kennedy will implement Virtual keyboard and Keyboard mapper. This was our failure last year when that student did not write any significant code, and moreover, he tried to trick us. We are in a really big demand of these two features, and we are looking forward to unify our ports. Even desktops will benefit from it as there are tablet PCs and of course, users could want to remap default keys. The appoach promises to be flexible enough for engine developers to cover all supported games.

Amiga sound formats, including TFMX support. Yes, full support for Amiga Monkey Island is on the go. Also within this task first C++ implementation of MaxTrax player used in Legend of Kyrandia 1 and other games is going to be implemented. We will see what other formats Marwan Hilmi will manage to cover.

And finally, our last year successful student Kari Salminen aka Buddha is going to add Support for Operation Stealth. The CinE engine was for a while in ScummVM, but only Future Wars was supported so far. There are big misses in opcodes and other parts of the engine which make Operation Stealth not completable, but I am sure that Kari will manage to finish it.

Thus, stay alert and see that at the end of the year, probably on second major release from now (we are at 6 months release cycle) , ScummVM will be greatly improved. Read More...

Sunday, April 20, 2008

We came out from the deep

Today, after 802 internal commits we finally went public with M4 engine. In fact, our team did not want to go public until some viable results were achieved.

The M4 engine is used for Riddle of Master Lu and Orion Burger games. Also historically it evolved from MADS engine which was used for at least three more games. Currently scripts work, although there are many missing opcodes; animation, graphics, sound get decoded. Intro could be enabled at compile time. Menus, conversation and text rendering are all covered. The progress on the engine is pretty rapid, though now the bottleneck is johndoe with his script data extractor.

As a bonus today was also committed another engine, the smallest one up to date. That is called M.A.D.S. and it was used for Return to Zork and couple of other less known games. Johndoe REd is as a side excercise and it is in almost complete state.

Today was a significant day in ScummVM history.

Thursday, April 17, 2008

Kanji struggle

For the last several days I was trying to add support for Japanese DIG. It was reported in this bug report.

For some reason there is a bug with Kanji processing in our code. You may see it in these two screenshots (on the left is original and ScummVM is on the right):

As you may see, Kanji 出 (de) is rendered as garbage. Basically it looks like all Kanji is rendered bad. Investigations and test runs showed that computation of offset in font file (SJIStoFMTchunk() function) is correct, but the function produces value behind the font file end. Probalbly there is some preprocessing on font load. Need to clarify that too. Read More...

So, it starts

Yes, we were discussing this internally for a while, and I myself wanted to tell some news in some more permanent place than #scummvm for a while.

I am starting this thing called blog, about which everyone went crazy these days. I am sure that I will not post here often or regularly, but I will do it from time to time.

Soon there will be an aggregator for all ScummVM-related blogs scattered around the net, as some of the devs already have them created for a while. We are going to use PlanetPlanet software for that. The aggregator is already installed, we just are waiting for moment X to turn the switch on.

Also GSoC slots are about to be permanently allocated, and we have several excellent student applications this year. Stay tuned. Read More...