Technical Differences in Ultima Underworld on Pocket PC

From Ultima Codex
Jump to navigation Jump to search


Description[edit]

This article is a real work-in-progress. I don't count it as an article yet, just a place I'm dumping my notes and get organized to make a real article.

I don't have an emulator setup so my observations are from videos I see online, on YouTube for example, and by analyzing the game files.

Some file data comparisons were done with UWXtract

--Sir Robin

Versions[edit]

There are two versions, one for MIPS and one for StrongARM. The installs are identical except for the executables (UU.exe and gx.dll)

File Comparison[edit]

  • root: In the root folder the PPC version has only UU.exe (not UW.EXE) and gx.dll.
  • CRIT: In the crit folder there exactly the same files. Many have binarry changes, but these seem to be only encoding changes because the frames and animations output by these files are pixel-perfect matches between versions.
  • CUTS:
    • CS012.N01: this file contains the credits for the DOS version. It is still present in the PPC version. bout 15kb has been trimmed off the end of this file. It doesn't seem to affect the contents of the file. All credits screens are present and identical to the DOS versions.
    • CS400.N00: It's not known exactly what this files does, likely it is a control file for CS400.N01 which contains the images of window views of the volcano shaft.
    • CS401.N00: It's not known exactly what this files does, likely it is a control file for CS400.N01 which contains the images of gravestones.
    • CS405.N01: This file contains several images of note scrolls found in the game.
  • DATA:
    • CHRGEN.DAT: not sure what this changes. Character generation stats? Need to investigate further.
    • COPYRIGHT.BYT, CREDIT1.BYT, CREDIT2.BYT, CREDIT3.BYT: new files
    • OPSCR.BYT: modified, added copyright notice at the bottom
    • UW.CFG: Not sure why this is here, there is no setup or install or other exe file, maybe it's made by the CAB installer?
    • WEAPONS.DAT: Some adjustments to the mace's offsets
  • DATA3D: a new folder to hold 3d model files
    • *.E: Model files, unknown file format, plain text
  • SOUND
    • xx.VOC: all gone
    • all drivers: gone
    • AWxx.XMI: all gone
    • UWxx.XMI: all gone
    • UWxx.MOD: replace the XMI files
    • VOCxx.wav: replacing the VOC files

Interface[edit]

The Pocket PC does not have a physical mouse and keyboard so the game had to be adapted to use the touchscreen as a mouse and a virtual on-screen keyboard at the bottom of the display. Other than that the Pocket PC's interface functions nearly identically to the DOS version.

The virtual keyboard is not QWERTY or any other standard layout, it is simply two rows of touch buttons that include digits 0..9, letters A..Z, backspace, enter, spacebar, and capslock keys. In a promotional screenshot of the character creation screen the charcter's name has an equals sign in it. It is not clear how that was entered.

Screen Layout[edit]

The the DOS version the screen is rendered at a resolution of 320x200, while the Pocket PC version uses 320x240. The upper 200 lines mimic the 200 lines of the DOS screen while the lower 40 lines contain a virtual on-screen keyboard to make up for the Pocket PC's lack of a hardware keyboard. However on the main screen the 320x200 area of the Pocket PC doesn't exactly match the DOS version. It seems there are a few layout discrepencies of the graphic elements. Bad layout has produced obvious graphical artifacts.

Uw1ppc.ss.compare.gif
  • Several images are stretched 1 pixel too high, normally with their first row of pixels duplicated, and other odd stretching artifacts present:
    • The gargoyle's eyes
    • The entire character info panel
    • The "pickup" and "use" buttons on the left panel
    • The scroll dragons and their upper tails (the mid-tails are part of the frame graphic and are unaffected)
    • The vitality and mana flasks
  • The viewport overlay elements coming from 3DWIN.GR are drawn in seemily random places on the screen
    • The upper part of the compass holder is drawn above the gargoyle's left-side hand
    • One spike from the scroll dragon's mid-tail are drawn on the viewport frame, on the upper edge on the right side
    • Another spike is drawn on the far right side of the screen
  • Both scroll dragons have a horizontal line of pixels missing from their sprites
  • On the message scroll along the bottom of the screen:
    • The message window is drawn 1 pixel column too narrow and 1 pixel row too long, creating artifacts along those edges
    • The edges of the scroll, meant to be filled with graphics from scroledge.gr are drawn one pixel row too short (28 instead of 29) thus creating artifacts in the bottom corners of the scroll
  • The entire screen is shifted one pixel to the left

Renderer[edit]

Texture Transparency[edit]

The DOS version allows transparencies in 2d graphics such as object icons and critter sprites, but not in textures on level geometry and texture mapped objects. Any transparencies in textures are rendered as opaque black. The door graphics (in DOORS.GR) have transparents areas in their textures, but these are not seen in-game in the DOS version. Judging by screenshots of the Pocket PC version, it does allow transparencies in the textures.

In the PPC version the next room can be seen around the edges of the door, through the keyhole, and even the cracks between the boards.

Icon Scale[edit]

The second thing I noticed watching PPC videos is that the object icons seem to be drawn bigger in the PPC version.

Object icons are stored in FILEobjects.gr and that file hasn't changed between versions so it must be the renderer that's changing the size of the sprites. The graphics are exactly the same.

Lighting[edit]

The PPC version seems to be over-lit. The videos shown don't use any light source and yet they are brighter than my playing with the torch lit. Also the UI looks a lot brighter. Not sure if it's actually brighter or just an artifact of whatever device was used to capture the screen.

The PPC fonts are all bright white where the DOS verion has them in various shades of various colors.

This was likely done to increase visibility of darkened game elements, as mobile devices are often played in environments with varied and often sub-optimal ambient lighting.

Graphics[edit]

Main Menu, Copyright, Credits[edit]

The DOS version displays a copyright notice at the bottom of its title screen, stored in cutscene file FILECS011.N01, and credits screens are stored in a cutscene file, FILECS012.N01. The main menu screen is stored in a bitmap file in the DATA directory, called FILEOPSCR.BYT.

The Pocket PC version adds a copyright notice to the bottom of FILEOPSCR.BYT, a full copyright notice in a new file called FILECOPYRIGHT.BYT, and credits in 3 new files, FILECREDIT1.BYT, FILECREDIT2.BYT, and FILECREDIT3.BYT, all of these in the FILEDATA folder.

The reason for this change is probably because the Pocket PC install has the cutscene files as an optoinal install to conserve storage space consumed by the install. Having the copyright notcies and credits in files outside the cutscene files means they are always part of the core install and won't be missing from a "lean" install.

Weapon Offsets[edit]

Critter Animations[edit]

The critter animations seem to have massive changes between versions. About half the files are different, some with just a byte chagned and some with most of the file changed. But what changed? The actual artwork? the sequences? Or just recompress the files? Because the compression on the original files was pretty sloppy, I remember. Anyway, need to analyze this, determine the differences.

Analysis: The changes seem to have been purely structural. The animation sequences and the sprites defined match exactly, even though there are binary differences in the files.

Audio[edit]

Music[edit]

All music is now in 8-channel MOD file format - Do I mean that music on the Amiga from the late 80s that was all over the 90s demoscene? Yes, yes I do.

Mostly it sounds right on with the music I'm acustomed to, a few tracks sound off though. Particularly 5, 8, and 14. Maybe it's my player? I haven'[t dug into it much, but I notice the other tracks are all 8 channel while these are 4.

Sounds[edit]

The FILEsounds.dat file is identical between the DOS and PPC versions.

the VOC files have been replaced with .wav files. The file "xx.VOC" is now "VOCxx.wav". All 42 files are there.

Data[edit]

The file FILEchrgen.dat is modified. It is the file that holds the character generation: The classes, their starting stats, their selectable skills. This file has chagned between versions however the data coming out of it is exactly the same, so maybe the changes were purely structural? Need to investigate more.

The file FILEweapons.dat holds offset for all the hud graphics for the weapon animations. There are some changes to this file, but stangely enough, they're all in non-drawn sprites, at the end of the animations, when the weapon is offscreen and there is nothing to draw. Not sure what the point of that is. DOS left them all at (0,0) but PPC sets them to at or near the next frame's offsets, but not always.

master
frame
weapon hand animation frame DOS PPC
59 mace right slash charge 4/4 0,0 0,32
64 mace right slash attack 5/5 0,0 120,57
68 mace right bash charge 4/4 0,0 143,111
73 mace right bash attack 5/5 0,0 100,18
77 mace right poke charge 4/4 0,0 123,11
171 mace left slash charge 4/4 0,0 113,32
176 mace left slash attack 5/5 0,0 0,58
180 mace left bash charge 4/4 0,0 0,111
185 mace left bash attack 5/5 0,0 60,20
189 mace left poke charge 4/4 0,0 31,13

And that's it. No other data files are modified.

Models[edit]

There is a new folder off the main, called DATA3D. It's full of files that seem to be 3d model definition files. There are 30 of them and I can't think of 30 models that are in the game. There are ones there like BARROPEN and BARRCLOS that I'd guess are barrel opened and barrel closed, except that the barrel in the game didn't have two states. Neither the object table nor the level maps are modified, so no new objects have been added to the game, so I really wonder where all these models are being used. And there is a file called BED, is that a bed from Ultima Underworld II? This all need more investigation, and I don't know the model file format or I'd like to look at them in 3d.

I did a crude view of the models, here's what I found:

Filename Notes
40LOTUS.E Sadly, this is not actually the lotus turbo espirit model. It has all the same points as the table but much fewer faces.
ARROW.E An arrow
BARRCLOS.E a barrel, identical to BARROPEN, seems similar to DOS version barrels
BARROPEN.E a barrel, identical to BARRCLOS, seems similar to DOS version barrels
BEAM.E a long rectangular beam, looks similar to the DOS version which wasn't seen in-game
BED2.E a bed, similar to those in UW2, but slightly different
BENCH.E a bench, seems similar to the DOS version bench
CHAIR.E a very basic chair, might be the chair from System Shock
CHAIRFAN.E a fancy chair
CHAIRSIM.E a simple chair, seems similar to the DOS version chair
CHEST.E a chest, seems similar to the DOS version chest
CUBE.E a cube
DFRAME.E a door frame
DOOR.E a door
FBRIDGE.E a bridge object, a flattened cube, missing front and back faces
GATE.E a moon gate?
GRAVE.E a grave
NEWPILL.E a pillar
NEWPORT.E a portcullis
NITESTAN.E copy of table, this is not the nightstand from the DOS version
OFRAME.E just the narrow parts of the door frame
RBRIDGE1.E a rope bridge? just three points
ROCKBIG.E big boulder, not the same as in the DOS version
ROCKMED.E medium boulder, not the same as in the DOS version
ROCKSMAL.E small boulder, not the same as in the DOS version
SHRINE.E a shrine, seems similar to the DOS version
TABLF3.E a table, looks similar to the DOS version which wasn't seen in-game
TMAP16X16.E a simple square, probably used for switches and engravings
TMAP32X32.E a simple square, not sure where this is used
TMAP64X64.E a simple square, probably used for drains, grates, tapistries, windows, etc

Cutscenes[edit]

Cutscenes seem to still be done in CSxxx.Nyy files with audio in .wav files (from DOS version's VOC files), I haven't inestigated these at all yet.

The file CS012.N01 holds the credits screens. This file has had 15,724 bytes shaved off the end of it, but that doesn't seem to affect the contents of the file. Both versions of the file hold 14 identical images.

There are two small files that are different, CS400.N00 and CS401.N00, with a few binary changes. I'm not sure what these files all, probably some kind of control files for their respective .N01 files. CS400.N01 holds the shaft window view images and CS401.N01 holds the gravestone view images. These files are unchanged.

There is an extra file, CS405.N01, that I don't see in my GOG version. Its date is in 1995, well after the DOS releases of UW1. It contains blown up views of some of the notes found in the game.

Gallery[edit]