Sunday, 16 October 2016

Alternate Reality X - Release 0.8, Items and Inventory

Following the release of 0.75 of my Alternate Reality X (ARX) project I have been working on the next release. As this will be a big release and add a lot of content (item wise) this is likely to be the 0.8 release. The main focus here is to complete a lot of the remaining programming around items and the player inventory in the game with a particular focus around Dungeon items. If you look at my existing code for ARX a significant portion of it focuses on inventory and item handling. A lot of what makes Alternate Reality a great series for me is the excitement of what items you might find after a successful encounter or in the case of the Dungeon a special unique item at a certain location (E.g. Sword of the Adept, Robin's Hood).

The existing ARX item code is probably the area of development that was most time consuming to develop to date and cuts across so many different areas of the two scenarios. AR had a very sophisticated system of inventory and items compared to other games of the time but this makes it much more of a challenge for someone like me to recreate for a remake :) I had planned to make some very major changes to the item and inventory system, very closely mirroring the internal representation used by the Dungeon.

Why change it you might ask? It seems to be working ok? The current system does work ok but it lacks the ability to allow for items to be truly unique or modified in game easily. A good example of this are the clothes items in the City shops. These are currently limited to a subset of the original games options. In the original City these items were made up of a handful of randomised attributes which meant that the City could have dozens if not hundreds of different variations of clothing. My current system doesn't allow for this. The other key areas which I can't implement with the item system in 0.75 are the enchanted weapons from the Weapon Enchantress where she will (for a hefty price) add a number of enchantments to your items. modifying their existing attributes and the Dwarven Smithy who I also believe will create varying qualities of weapon depending on how well you pay him.

Some of the goodies you can find in the Dungeon for release 0.80

In the original Dungeon a block of binary data was used to represent all "active" items in the game. These included items on the ground, carried items, curses, diseases, spells and monster corpses. I was planning to recreate this system in ARX but I've now come to the conclusion that you probably wouldn't see the next release until 2017 and I'm not even sure people would really see or recognise the benefits! The key things for me are to be able to obtain the flexibility of the original system above, minimise the amount of changes I'm having to make just now and be able to make full use of the original binary data (which I've done successfully with the monster data).

I've already written code to read all the original item data into ARX for release 0.8 so that part has gone well. I've extracted all the item names and addresses so it's relatively straightforward now to pull out additional information for items as required. I'll also be able to use this code to extract all the weapon data for the Dwarven Smithy items as well which will save a lot of time and messing around with text files to represent objects which I'm moving away from with the last few releases.

My original item / inventory system used a similar premise to the Dungeon with a single "Item Buffer" type array which holds all the active items in the game including what I call "volume items" (E.g. gold, silver, torches, compasses) that are effectively represented in the player structure as a single numeric value. The only issue with the current system is that it doesn't directly hold lots of the attribute data representing items directly instead pointing to a fixed representation of the item - this need changing.  I've decided to expand and build on this existing system rather than directly copy the Dungeon internal system. This should save me a LOT of time changing existing code and systems that work well already. The existing system probably addresses about 70-80% of the item requirements for AR so it doesn't seem like a good use of my time to rewrite lots of code for that extra 20% of functionality.

The "Item Buffer" in use showing carried items as well as "volume items" on the Dungeon floor

I've thought of another way to expand the item system to allow for the dynamic items such as enchanted weapons so these features will still be in the game, just using a different internal representation to the original Dungeon. The current system will still be able to access all that new binary item data that I've read into ARX as well so item effects for special items will still be accessible within the game.

Sunday, 25 September 2016

Alternate Reality X - Release 0.75 - Changes

With the public release of Alternate Reality X 0.75 looming for the end of September 2016 I thought I would talk a little bit about what you can expect to see, what I didn't manage to add and my general approach to have the completed 1.0 release in your hands before the end of the year.

I had planned for this release to complete ALL the elements of the City and the Dungeon that I see as combat and encounter related. I didn't achieve that for a number of good reasons but I did make some very significant steps that put the project in a much stronger position than it was in before. One of the big changes was to add all the remaining Dungeon monsters as to date only the Well Lit Area and Fixed Encounters had been added and to animate them all.

One major change which I had not committed myself to making was using the original 8bit Dungeon monster data directly from the binary files. I was previously using simple text files which whilst easy to update had numerous errors, lacked a lot of information from the real data and were prone to spoiling of the game / opportunity for cheating from players. In addition to this I had built up similar text files for weapons in the game - an amalgamation of weapons the player could buy, monster weapons and unique items you could stumble across (e.g. the Sword of the Adept).

One of the great features of Alternate Reality (the Dungeon at least) was that it had a very flexible system for customising monsters and items in the game. Many games at the time would have had fixed object sizes with no opportunity to modify those objects in game. The Dungeon in contrast allowed very rich items and monsters which contained a mixture of attribute data (name, bonus to hit, sharp damage) with effects (curses, give off light) and directly included 6502 (the processor used by the Atari 800, Commodore 64 and others) code. In game objects could also be dynamically created in game (clothing in the City) or modified through player actions (weapons having enchantments added at the Weapon Enchantress).

So after a lot of thought I made the decision to use the original binary data. Using some great information provided by Brian Herlihy a few years back, I replaced the original monster loader and also added in support for loading in all their weapons and attacks. These are stored as part of the monster data. This was a lot of work for me but once I had these changes working I felt it made an immediate improvement to the feel of the game as well as adding all those additional Dungeon monsters - about 50 in total. Thanks to Brian for this information without which these changes wouldn't have been possible.

Another major change in this release was the introduction of properly timed / processor speed independent encounter animation. I had information on encounter animation from old emails from Jim Norris - thanks Jim! - so I used these to hopefully produce a fairly accurate recreation of the Dungeon encounter animations. As part of this work I totally rewrote the main encounter loop and the way that monster and player "turns" are taken during combat and how multiple opponents are dealt with. Monster attacks now use the proper attack descriptions (whomps, slashes, chokes etc), can hit multiple player body parts and can also knock the player to the ground.

Behind the scenes I re-organised some of the game code, introducing more source files to try and better segment and compartmentalise different code areas (e.g the actor source files refer to encounters, load in the binary data, create their weapons and attacks etc). All these changes meant a lot of knock on changes - some foreseen, others not. These took time to sort out. I've probably not caught all of these issues yet.

With the introduction of all the new Dungeon monsters and only limited new encounter art I took the decision to temporarily disable the new media options - these will be back in a future version. I also disabled the W command to force an encounter as it seemed to be a source of problems and encounter frequency checking has been re-written in this release to check regularly for new encounters. I had to tone this down a bit as encounters seemed to be happening back to back!

The other feature missing from this release is the ability to pick up monster weapons after combat. There was a very practical reason for this, namely that all monster weapons are now stored in a new format and location whilst the player inventory / object buffer in the game uses a totally different system. In order to allow for the custom weapons of the Dwarven Smithy and enchanted weapons from the Enchantress this system will need to be updated and this in turn will impact on all the existing shops where weapons, armour and clothing can be bought. This work will be the focus of the next release with addition of adding in the original item binary data from the Dungeon to introduce all those special objects into Alternate Reality X such as Trump Cards, Eyes, Wands and Horns. Trying to add these into release 0.75 would have added a lot longer to the development time and I was keen to have a release out before then.

In order to have the 1.0 release ready for the end of the year I have had to focus tightly on what needs to be finished and priority on the gaps that need the most work and will add the most to the game. This may mean that some of the extras will go on the back burner for the time being but I think it will be well worth it to have a complete, integrated City and Dungeon Alternate Reality world to explore! Hopefully these decisions make sense but as always I'd love to hear your thoughts. Watch out for release 0.75 coming very soon. Thanks.

Friday, 26 August 2016

Alternate Reality X - August 2016 Dev Update

Here's a new video providing a glimpse of the new encounter animations and further plans for development.

Friday, 24 June 2016

Alternate Reality X - The Final Stretch

Following my announcement that I'm planning to complete release 1.0 of Alternate Reality X (ARX) for Monday 5th December 2016, the final stretch of development work has begun! It's great to have that clear goal in sight. I'm pleased with progress since the announcement but there is still a lot to complete before December to get all the features added so I'll need to push myself hard and stay focused. I'll be devoting the majority of my free time to making sure I meet my target, chipping away at small issues when I have a bit of free time and maximising the time I spend on development. I want everyone to be able to play a complete, fully integrated City and Dungeon for Christmas 2016! Visualising that goal tells me it will be a great personal achievement for me - and hopefully players will enjoy the results too!

As I go into this final stretch any assistance people can provide through donations to the project, however small would be particularly helpful. This support helps in a few different ways - it allows me to better justify the (very considerable) time that I spend on coding ARX to my family, helps cover some of my small development costs such as webspace and small hardware/software purchases and permits me to spend more time focused on development. The PayPal and Patreon details can be found at the support page here.

If you've donated in the past either through PayPal or Patreon then you have my sincerest thanks - it makes a big difference to me and has really helped me to keep developing ARX - probably more so than people realise. Alternate Reality X would not have been possible for me without your support. I've been thinking about ways to better convey my thanks once the project is completed and I have a few ideas which I think players would like.

My main focus for development is ensuring that 100% of the original City / Dungeon content and features are implemented for the 1.0 release in December. I've temporarily disabled some of the alternative graphics and music options to allow me to focus solely on ensuring the original games are completely re-implemented. Hopefully everyone is ok with that as a temporary measure - for me it makes managing the project easier and allows me to focus better on the key features which aren't in place or fully completed yet.

I've worked exclusively on encounters and combat recently. I've rewritten the main loop that deals with combat so that ARX now has a sensible turn structure with the player and opponents taking turns as well as adding in options for surprising characters, deciding whose "turn" it is first. One of the main reasons for rewriting this was so that animation effects for encounters as well as backgrounds (rain and other weather effects) could be added. I've added the encounter animations now which I think makes a big difference to making the game feel more complete. I'm now working on adding more encounter features. Release 0.75 will focus solely on encounters as there has been a lot more work involved in rewriting this part of ARX than I anticipated. I'll also be adding all the additional encounter weapons that opponents can carry such as Unholy swords, flaming pitchforks and diamond daggers among many others.

Release 0.76 will focus on all the other items and treasures that you can find in Alternate Reality (horns, eyes, tarot cards). I'll have more updates and possibly a video shortly once I sort out my screen capture software. It's going to be a bit longer before I have the next release out as I'd like to add more new encounter features first. Thanks for your support and interest in ARX.

Saturday, 21 May 2016

Alternate Reality X - Release 1.0 - Target Release Date!

Time to draw a line in the sand. I first started the current form of my Alternate Reality: The City & Alternate Reality:The Dungeon remake project back in 2009 - A long, long time ago. I think I even still had a full head of hair back then! Alternate Reality X (ARX) as it's now known has come a long way since that 0.1 release back in 2009 and I've found myself diverted or distracted on occasion but the project is now well and truly back on track and developing on a daily basis.

Based on the solid progress I've made with development of ARX during 2016 I now feel that I can confidently announce a target release date for release 1.0 of the game. I have always envisaged 1.0 as completing my original vision for my Alternate Reality remake project - a full recreation of both The City and The Dungeon in a single, easy to use, seamless game for modern systems.

At the beginning of 2016 the game was still a confused mangle of code which I'd built up steadily between 2009 and 2015. It was full of workarounds, hacks and was very difficult to expand and add new features to. I've spent a lot of time reacquainting myself with some of my earliest code during the last few months which was a big challenge. I kept asking myself "Why did I do that????" Back then the main problem was that I was learning a lot about game programming for the first time and at the same time trying to develop the game. This often led to me making short sighted decisions without realising their longer term consequences. Later I would then struggle to bolt on a new feature to an increasingly precarious code base.

I'm pleased to say I'm now a lot more confident in my programming and game development skills and I've managed to gradually start to restructure my ARX code into a more sensible project. I've learned and read a lot about programming, C++, SFML and game development so I'm a lot better equipped to complete the project. I still have more work to do (and plenty to learn) but I expect to have a complete, well organised and (easily) expandable game by the end of 2016.

There is still a lot of work to do and features to complete before then but I feel really confident and excited that this is achievable and realistic. I can't think of any area or feature that I'm particularly daunted by. I know that completing the game will be hard work, challenging but also extremely satisfying. If the 1.0 release is well received then I can look to really expand on the Alternate Reality universe during 2017 with additional scenarios and other enhancements to the City and the Dungeon.

As you can see from some of the screenshots here I've finally set up Alternate Reality X so that you can finally encounter some of the more exotic Dungeon encounters that haunted the corridors and halls of the original game. I'm also continuing to add in the special behaviours and actions for each encounter type.

So, without further delay I'm pleased to announce that my target release date for Release 1.0 of Alternate Reality X is:

 Monday 5th December 2016 

It's a date I'll be putting in my calendar! Hopefully something of an early Christmas present for some people. This is likely to be Microsoft Windows only initially and will focus on completing 100% of the original features from The City and The Dungeon. You will also be able to complete all the Dungeon quests and complete that scenario.

I just want to take this opportunity to say a big thank you to those people who have supported me through Paypal, Patreon, the AR forums, Facebook or by sending me personal emails of support and encouragement through the life of the project. It has made a big difference to me personally that you've had faith in what I've been working on and continued to support the project. If you have questions about this release or how I plan to achieve it then please post them here, on Facebook, the forums or send me a private message / email.

I'm not announcing this release date lightly - I take it very seriously. It's not only a commitment to those who've supported the development of the game - some from the early years - It's also a big commitment that I'm making on a personal level to myself. I think for me setting this release date will only strengthen my resolve to complete the game and help me focus on reaching my development targets. Regular releases of the game will continue to appear leading up to the final 1.0 release. Release 0.75 will focus on numerous improvements around City and Dungeon encounters. Thanks for your patience and support.

Thursday, 19 May 2016

Alternate Reality X - Encounter Update, May 2016

As mentioned previously the encounter code in ARX had a lot of issues and really needed some serious work if I was ever to make it complete and feel authentic to the original Alternate Reality combat. I've basically taken apart most of the encounter code before refactoring it and putting it back together again. This has taken me a lot time and a lot of hours but I feel I've made a lot of progress.

The encounter code is now much more sensibly organised and structured and it is much easier to add in additional encounter features. The code is hopefully a lot more readable now, not only saving me a lot of time when I add to it but also meaning that others will be able to understand it a lot more easily should they want to.

I'd crammed a lot of only vaguely related code into the encounter module including the character and monster encounters themselves as well as their weapons so it was desirable to split these into their own source files. My plan is to gradually make these much more object oriented with player and opponent objects sharing a lot of code and functions for much better consistency.

I've been adding in new encounter features that were previously missing in ARX such as the player surprising encounters (or in turn being surprised) or being stunned and missing a turn. I'm still doing a bit of testing of the original game to understand exactly ow waylay and snatch should work but it's good to have them in the game finally. You can see these illustrated here. The next change will be to add the Dungeon style combat messages and implement different body parts for the player which aren't fully active at the moment.

It shouldn't be too long before the next release is out. This will be focused on completing the remaining encounter features. I feel this will make ARX feel a lot more playable and authentic and will herald a big step forward for the project. Thanks for your support and patience as always.