Saturday, 24 November 2007

Added Tile Properties


It took me a while to sort out the new file format for the terrain objects but I've now got a simple machine/human readable format which I can reuse for the monster and item files. Now that I've done this I've thinking of splitting game objects into 3 different areas - terrain, monsters and items. The map/item format is very simplistic just now so will probably need to be expanded at some point.

As always I'm wasting time changing little image files instead of sticking with a handful of basic tiles and adding features to the editor and game. Anway I finally added some properties for the different types of terrain in the game. Decided to leave out animation and visibility for tiles just now. For now I've kept it very simple with tiles having a small number of properties:

  • Tile no - the image number from the tile sheet
  • Name - a text description for look commands
  • Passable - can the tile normally be walked through
  • Map link - does the tile offer an entrance or exit to another map level (E.g. staircase)

I'd like to really start making Demons Eye feel more like a game. I might add a player status and inventory pages and some simple console style messages. It would also be nice to be able to have a bit of simple treasure hunting and combat!

Saturday, 10 November 2007

Demons - Slow Progress



Progress is slow mainly because I keep going back and fiddling with little things rather than adding new features to the engine. There's still no actual functionality or properties to tiles so this is really something I need to make a start on - it's not difficult.

Anyway there are a few cosmetic changes. I've added an Ultima style border dividing the screen into three main area - overhead view, messages and the character status/inventory browser type area.

The 16x16 font has been replaced with an 8x8 one - currently Joshua Steele's Ultima 4 Upgrade one. I wanted to be able to put quite a lot of textual information on the screen for combat, conversations and intentory details but this was difficult with the larger font and a smaller font also leaves more space for item graphics, status bars or icons which I think will make the display a lot more interesting. This font is good for now but I'll keep my eye open for something a bit more unique.

I've reverted to the David Gervais tileset and RLTiles tileset. Both are good tilesets with plenty of intersting to tiles though there are a number of typical tiles I'll need to create/find elsewhere to complete some content.

Really need to add some simple tile properties. Are tiles passable? Can they be seen through? Do they link to another map? And so on...

Friday, 19 October 2007

Bitmap Fonts


Added some bitmap font functions. SFML already has good font support for many popular types of font built into it but I was wanting to use a simple fixed-width bitmap font. The font in the picture is from Alternate Reality: The Dungeon. A simple map loader has been added (loading in an Ultima 5 map in the picture) but I still need to add a save function.

Wednesday, 17 October 2007

Inspiration from other games

I've been playing some of the old games that I like and thinking about what are the positive and negative features of each game and which I want to incorporate or avoid in Demons Eye. I've just been playing Ultima V and this has given me a few ideas. One of things that put me off playing Ultima V more when I was younger was that some of the exploring seemed quite tedious. For example exploring a castle meant a lot of searching for secret doors (all of which seem to be locked) and also moving potted plants around to get to said secret doors. These are fine if there are interesting things behind them but if not then they just annoy me and take a lot of fun out of the game. This specific issue seems to be worse in Ultima V.

Ultima V manages to make fairly varied maps out of a limited set of tiles (256 terrain tiles + 256 monsters/items). I spent a lot of time over the last few days messing around with lots of tiles adding them to the tilesheet and probably not using them. I also need to think about how I want to handle lighting and line of sight in Demons Eye. Personally I often find that limiting the view this way detracts from the game. Maybe it would work best in Dungeons where there is more tension about unknown creatures coming out of the darkness.

On the combat front I think I've decided on a single player rather than a party. Party combat is too tedious I think unless it has an automatic option where most of the party fight under computer control. It also means that you can focus on really developing your single character rather than having to share out experience and items between a party. I know a number of Ultima players like to play with a small party (or single character) as it makes play a lot simpler. There will still be the option to summon various helpers through magic or possibly get help from passing good characters.
In summary:

  • Good design using a small number of tiles rather than hundreds of different tiles.
  • Sparing use of secret and locked doors.
  • A decent number of searchable objects (e.g. chests, baskets) should contain some objects!
  • Night and day cycles and Line of Sight shouldn't limit the view too much.
  • Single player rather than party.

Saturday, 13 October 2007

The Map Editor - 8 hours

I'm finding it hard to keep track of how much time I'm actually spending on Demons Eye but I think my actual coding must be at about the 8 hour stage. The editor now has a working view and tile section for selecting tiles. Basically the cursor keys can be used to move around on the current map and the page up/page down buttons let you scroll through the tiles available. The left and right mouse buttons can be used to select tiles and place them down onto the map canvas.

Some of these pieces of coding came together very quickly which was a pleasant surprise. The mouse coding in particular was very easy to do. The map structure is currently very simple with 2 layers - one for the landscape, walls, doors etc and another for monsters, characters and items. Ideally I should change the items into a linked list at some point to save on space and processing time. I'm also considering a third, middle level to cover decorative items - tables, rugs, blending tiles. This will allow me to reuse certain tiles over different base tiles without having to make multiple versions.

I'm considering expanding the current tileset with some new landscpae tiles and will have a go at creating some of my own over the coming weeks. I think there are plenty of good monster, character and item tiles in David Gervais' set so I should be fine there. A lot of features still to add to the editor before I'll be able to really start using it but I'm making some progress.

Sunday, 7 October 2007

New Tiles

As I now have a working map viewing program I decided to change the temporary Ultima tiles and map for the David Gervais tileset. For those not familiar with this tileset they are a very large colletion of tiles designed for Angband originally (I think). OK so this screenshot couldn't be more boring if I tried but it does demonstrate a larger view area and also illustrates the use of transparent tiles which just took me a few minutes to work out using SFML.

Behind the scenes I've also started adding additional tiles to the game. Basically I have one large image which holds all the 32x32 pixel tiles for the map, items and monsters and SFML can be told to use just a small portion of the image to make up each tile. Now that I'm up and running with coding the SFML side of things seems very easy to use.

Next thing is to setup different properties for tiles such as whether they are passable, water etc. I also need a more interesting map!

Thursday, 4 October 2007

Demon's Eye

As you may have seen in the previous screenshots my CRPG game is now provisionally known as Demon's Eye. This is based on an adventure game I started writing about five years back. Not a very original title but it's better than calling the project CRPG! Send me your suggestions if you've got a better title in mind.

A Simple Map - 4hrs

It's been a while since my last post so what have I been up to? After a slow start I've finally started to make a bit of progress. I'd decided to start my coding by putting together a very simple editor which would allow me to start creating maps and building up features as I went along such as item handling and encounters. I really like the idea of a combined editor/play environment so that I can build and test quickly.
So I built up a simple tile sheet which would be displayed at the side of the screen and would be used to select tiles with your left and right mouse buttons. The rest of the screen would be taken up with a large viewport onto the current map. You would be able to scroll around quickly and use the mouse buttons to place tiles onto the map. This seemed like a sensible place to start and not too difficult or time consuming to code. That was the theory anyway.
I failed to account for my inexperience of using SFML and the time it would take me to get into the swing of starting a new project. It took me a number of hours to sort out various bugs in my display code and work out how to do various simple display tasks properly in SFML. As I started making myself more comfortable with SFML and getting back into coding, the focus shifted away from the editor to just getting a simple map format setup and a tiled map view displayed on the screen. This was frustrating as the code is short and straightforward but you have to remember that I'm not much of a programmer. Anyway eventually I got my simple view onto the screen using the Ultima IV tileset and a map of the town of Moonglow (also from Ultima IV).

This simple example lets you move around the map using the cursor keys and sets up map boundaries. In the example I used an 11x11 map window like Ultima IV but I'll be making this much larger so you'll see a much larger portion of the map at one time. It was satisfying to finally see something vaguely game-like on the screen even if there is currently nothing to do. I'm currently thinking through the possibilities for the rest of the display. This will most likely feature character and inventory information on the right hand side in a column with a rectangular message window running along the bottom of the screen . At a resolution of 800x600 that should still leave plenty of space for the tiled map.

Tuesday, 18 September 2007

Simple Tile Test

Here's a screenshot of my first play around with displaying some tiles using SFML. Took me a few minutes to update the SFML libraries and includes (as SFML 1.1 is now out) and soon had some tiles drawn on the screen. It's a start!

The Map Editor

First thing I'm planning to work on is putting together a simple map editor. This will allow me to outline some of the main data structures in the game - maps, tiles, items and monsters. It will also give me some hands on experience of working with SFML. I'm intentionally going to keep the game and editor designs and layouts very similar to minimise creating different sets of code for very similar functions. I quite like the idea of building the editor and game engine as a single program so that I can switch between designing and playing with a couple of key presses, hopefully speeding up game development. Editor features will likely include:
  • Variable map sizes (max. 256x256) - plenty big enough in my opinion
  • On-screen tile display for tile selection
  • Map links - link overworld to towns etc
  • Load, Save, Play options
  • Small tile versions available for overview mode
  • Properties for tiles?
I'm in two minds as to whether tile/object properties should be editable through the editor - this might be too much work for me. I'll have a think about it anyway. Game data will be stored in simple text files for the time being - probably comma separated.

Monday, 17 September 2007

CPRG Outline

Before I start attempting to code this I thought it was worth listing the type of features and stylistic elements that I'd like my Ultima-style game to have. I'm sure some of these features will change over time but here's a rough outline to begin with:
  • Single player character rather than party (this may change)
  • Individual maps for overworld, towns and dungeons (as opposed to the Ultima 6, all one scale/one map model)
  • Detailed, non-generic maps that aren't too big
  • Combat on current map rather than separate "combat" maps
  • Simple to use interface (both keyboard and mouse ideally)
  • Player character and encounter inventories
  • Quest journal to keep track of current tasks and quests etc
  • Graphical inventory
  • Tile graphics (using David Gervais excellent tiles)
There are loads of other features that I'm wanting to include but these should give you a rough idea of what sort of design I'm aiming for.

Sunday, 16 September 2007

Ultima-style CRPG

For many years I've been a big fan of the Ultima games and have always wanted to create a game of my own in a similar style. A couple of recent events have finally made me decide to actually start coding one of my own. The first was the release of the Simple and Fast Multimedia Library (SFML) which I think will be ideal for the sort of games I'm trying to create. The second was reading this article on Retro Remakes. The article is about writing an Ultima style game in a fixed 40 hour timescale. The game is called Inaria and further details can be found here.

I've always had a preference for the earlier Ultimas such as IV, V and VI. For some reason I've never really got into VII which is generally considered to be the best. With my own game I'll be looking to incorporate what I think are the best features from the various ultimas along with ideas from more recent commercial RPGS and home brew roguelikes. I've always liked the style of these games which are usually characterised by simple 2D tiled graphics, a large world map and numerous towns and dungeons to explore. Other similar games include Wasteland, Phantasie and Questron.

Saturday, 18 August 2007

Simple and Fast Multimedia Library 1.0

I've been having a look at the Simple and Fast Multimedia Library (SFML) and it seems quite interesting. You can find out more about it at:

http://sfml.sourceforge.net/

To quote from the website:
SFML is a portable and easy to use multimedia API written in C++. You can see it
as a modern, object-oriented alternative to SDL.SFML is composed of several
packages to perfectly suit your needs. You can use SFML as a minimal windowing
system to interface with OpenGL, or as a fully-featured multimedia library for
building games or interactive programs.

I'll keep my eye on this one as it looks very promising and has some nice built in features. I've been looking for something that offers a balance between the low level of SDL and the higher level of say Allegro and SFML looks about the right balance for me.

Wednesday, 1 August 2007

Rogue's Gallery



Spent some time at the weekend collecting more Encounter images and preparing them for use in the current release. My method for capturing these is pretty tedious but doesn't take too long as there aren't too many different encounter graphics and some are reused for different types of encounter. I basically save screenshots from within the Atari800Win emulator, cut out the encounter image, double it's size to fit a 64x128 pixel OpenGL texture and then remove any unwanted background. In future I'll need to capture the additional animation frames that many encounters have but for now encounters aren't animated.


I also had a play with some of the Eye of the Beholder graphics I've used previously but I think I've decided not to use these as they are limited in number leaving many AR encounters without updated graphics. Here are a couple of examples anyway.

Currently I'm creating black and white masks for each encounter image but I'm hoping that I might be able to do away with this possibly by using OpenGL's display lists. The AR font is drawn using this method and seems to work fine and doesn't require any manually created masks. Browsing round the web I found a program called GraphicsGale Free Edition which is a sprite editor that might be useful for hand editing of the original AR encounter graphics.

I'll need to set aside a lot of time if I end up hand editing all these original images...

Saturday, 21 July 2007

Gate Sequence Fixed


Finally managed to get the counters appearing in the right place on the gate sequence. Basically there are a number of different counters spinning round at different speeds. Pressing a key freezes the numbers and these become your character stats within the game. It also determines how much silver you start the game with.
It didn't take very long to fix once I managed to understand the code - that's the problem with using my old code from a few years back. I also tweaked the random numbers for the stats as they seemed a bit low and added in the "You are now joined." message. Added in the original sound effects for this sequence. I will come back to this part of the game in the future but now feel that I can move onto something else.

Thursday, 19 July 2007

Development Tools


I've recently made the switch from the freeware Dev C++ environment to Microsoft Visual Studio 2005. Dev C++ has served me well during the time that I've been playing around with this AR project but I decided to give Visual Studio a try and it seems to have worked well so far. I was really only using a bit of the functionality of Dev C++ but one feature that it didn't seem to have was an option for "folding" bits of code that you're not working on. Visual Studio also seems to be creating dramatically smaller executables. However these larger exe sizes in Dev C++ might have just been down to the compilation defaults which I didn't play with much. Visual Studio also seems to have caught a number of errors which went unnoticed by Dev C++. Again possibly down to different configurations. I'm still barely using any of the facilities within Visual Studio. An experienced programmer could probably show me lots of things I should be using to make life easier. Still not sat down and tried to familiarise myself with the debugger. I still think Dev C++ is very good and would recommend it to anyone looking for a free, easy to use option for programming. Dev C++ also has stacks of pre-packaged libraries called devpacks that can be downloaded for things like SDL, OpenGL etc. You can download these from here.

I'm not a programmer by trade though I've done bits of programming since I got my first computer back in the 1980s (a Commodore 64 which I wanted because it had 64k of memory which seemed to more than the alternatives at the time). I've also done bits of programming through study and work but nothing substantial. I did hold the job title "Programmer" for a few months but moved into a different area that I preferred. Most of the AR project code is probably not very well written. I'm planning to release the source code and VS2005 project files with the next release so if anybody wants to suggest any improvements or ways of making things easier or simpler feel free! I'm planning to spend some time tidying up the code before then. The display code in particular could probably be tidied up a lot and needs some fixes to stop ghostly arches appearing through supposedly solid walls. I know what the problem is here so can hopefully fix it without too many problems.

I've done some more work on the character creation gate sequence but I think it will take me a while to get it to the stage where I can say it's completed. As you can see in the screenshot the counters are roughly in the right place but don't look right yet.

The next thing I would like to look at is setting up "zones" on the Dungeon map. The zones will identify rectangular areas on the map where different graphic wall sets should be used. I believe this is how the original game worked. If you're unfamiliar with the original different areas had different graphics to identify them - Egyptian hieroglyphs in the Hall of the Adept, ice walls in the Crystal Caverns and so on. I'd also like to setup different light levels for different zones as this should be relatively easy to do as I'm using OpenGL. These light levels could then be adjusted if you're carrying a torch or wearing a Helm of Light or one of the countless other light sources in the game. Currently the demo lacks atmosphere as all the corridors and rooms have the same wall textures. I also plan to use the various zones to determine which monster encounter table should be used. A few years back Ken Jordan (one of the original programmers of The Dungeon) posted some information, maps and data files for the Dungeon and he said these contained the zone information. I've not decoded these but if anybody has I'd be grateful if you'd let me know - I like to use the original game data where possible.

Tuesday, 17 July 2007

Next steps

It's been a while since I've released any updated versions of the demo so I've been thinking about what features I'd like to add next. I drew up a list but as it has a few dozen items on it I won't repeat it here just now - too depressing!

One of the features of the original game that I hark on about all the time is the wide variety of objects you could find. There are large numbers of weapons, magical trump cards, scrolls, wands etc - certainly more than any other CRPG of the time that I can think of. Since version 0.4 I've added in support for dealing with the numerous objects in the Dungeon. So far I've added in some basic support for weapons. This means that you can now pick up any weapons dropped during encounters, equip them, swap them from primary to secondary and also use torches as weapons (they do both blunt and fire type damage). Different weapons have different effects during encounters E.g. don't fight a Flame Demon with a Flamesword as it makes them stronger!

There are a lot of "specials" in the original game where you stumble across a special, one of a kind item. I'd like to add some of the weapons shortly. It will take me a fair bit more work to add in all the objects and their different effects. Some of the objects are quite complex providing special bonuses or unforeseen side effects. I've yet to decode the macro language used in the original game in order to understand how these objects work. I'm using the real object data from the original game and hope to be able to add all the objects in one go.

I still can't help playing around with various graphics. The really difficult ones are the encounter graphics and shop interiors. My sensible side says use the original graphics for now and concentrate on replicating the game functionality but I'm also keen to try and update the look of the game a bit. The problem with graphics is that they are very time consuming to produce, especially if like me you don't have any artistic skill. Ideally I was hoping a skilled artist might be interested in updating them but no luck so far. Eventually I'll have a go myself. There seems to be no shortage of tutorials on the web! I'd also like someone to smooth out the AR font as I've doubled its original size making it look a bit blocky. If you're interested in helping out let me know.

The other thing I've been working on is the portal room with spinning counters. I had this working nicely under my original SDL demo back in the mists of time but still don't have the counters appearing in the right place since I've moved to SDL with OpenGL for graphics and increased the window size from 320x240 to 640x480. I know I should really sort something out with different window sizes and scalers but I'm leaving this for the time being. Currently the counters scroll out of sight - just need to spend a bit of time getting the coordinates right. Trial and error.

Friday, 13 July 2007

Welcome


Welcome to my Game Development Blog. Alternate Reality (AR) was a series of computer role playing games (CRPG) games back in the mid 1980s. The Alternate Reality games were originally intended as a series of seven scenarios - The City, The Dungeon, The Arena, The Palace, The Wilderness, Revelation and Destiny. Only the first 2 games in the series were ever completed, though plans for the Arena scenario were outlined.

Alternate Reality: The City was designed and programmed for the Atari 8bit by Philip Price with music by Gary Gilbertson and graphics by Craig Skinner. This original installment was intended to include the content of both The City and The Dungeon but was split into 2 games at the request of the original publisher. Numerous 8bit and 16bit versions exist, some better than others. The original Atari 8bit version is widely thought to be the best version.

Alternate Reality: The Dungeon was designed and programmed by Ken Jordan and Dan Pinal who worked for Datasoft with design notes left by Philip Price. 70% complete 16bit versions of the Dungeon for the PC and Amiga were in progress but were eventually cancelled. Versions exist for the Atari 8bit, Commodore 64 and Apple II. All copyrights for Alternate Reality have now returned to Philip Price.

Though not as well known as say the Ultima series of CRPGs, AR still has a small but dedicated following of fans who are keen to see the series revised. There is an AR mailing list which is still active and sometimes has the original series' developers posting to the list. There have been various attempts from fans and the original developers to redevelop the series for modern systems but unfortunately none of these have come to fruition.
Originally I started playing the Commodore 64 version of The Dungeon whilst I was still at school and it's remained one of my favourite games ever since. I've been interested in producing my own modernised version of the game for a number of years and a few years ago produced a simple C++ and SDL demo version which allowed you to explore a level of the Dungeon map and fight a few monsters. I eventually gave up after struggling to make progress with the 3D engine.

Over the last year or so I've started from scratch this time still using SDL for sound, music and input but also using the OpenGL library for graphics. This has allowed me to progress further and produce a more flexible display than my previous efforts, though the 3D view is still very basic.

My intention here is to record my progress on the development of the remake as well as give those who are interested in it the opportunity to comment and assist with the development of this project.