The Forest Keeper

When Mike and I were talking about The Lords of Midnight remake, one of the things we were going to do, was start the game earlier.

The Novella starts with Luxor and Morkin at the Forest Keeper’s hut. They are on their way to The Tower of the Moon in order to be part of the Council of the Wise.

The Novella is effectively all exposition. It’s about giving you the player, the information you need to know, in order to continue on and immerse yourself with the game.

This came to mind the other day because I was asked about remaking The Lords of Midnight, again. It is something I would love to do. I’m just not fully sure anymore what it would mean. However, there was one thing that I remembered that we did want to do, and that was change the Novella into a Animated Graphic Novel, and split it up with the initial game play which would then start from the Forest Keeper’s hut.

The game would place in you a restricted map, inside of the Forest of the Moon, and you need to find your way to the Tower. This would allow for the Narrative to be blended with the tutorial, and thus, by the time the game starts proper, at the start of the Solstice, you would have all the information you needed without having to read any manuals.

Once you start to increase the production values, then maybe there is something that could be for a larger audience.

I’ve already had some conversations about the audio. About how to score the game.

And visually, we have an idea of how it would look. Most of you already have an idea from Jure’s art that was non-original style for The Lords of Midnight and Doomdark’s Revenge. But I place a gallery at the end of this post. But if you then take into account this image the Jure sent me the other day when were were discussing how we would make the game look…

A Vision of Midnight

The real issues comes down to the interface and the gameplay. What would we need to change in the actual game. The main thing is to stay in the narrative. Every decision we make must be based on the story, and staying in story. We would probably need to make a few slight changes to the original just to give it some breathing space.
And all that text… it’s problematic but it’s also the charm of the original, you wouldn’t want to get rid of it, but should some of it be lost? I really don’t know the answer to that yet. What if it was all spoken?

Now, if I could just find some money to allow me and Jure to work on it full time… or almost full time…

We ride to tear the Frozen Empire asunder!

doomdark_site_indexAfter hastily announcing that I will be releasing Doomdark’s Revenge on the 7th I can now confirm that the actual release date will be the Monday 17th Feb.

The main reason for this change is purely logistics. I have to get the website ready to go, PR and Press Packs, Screenshots, Video, submit all versions, and create the store for direct selling.

However, the other reason that I hadn’t taken into account until thinking about submission congestion, is that, during the week of the 17th, it would have been Mike Singleton’s 63rd birthday. So it feels appropriate.

The iOS version is ready to go, and I intend to submit to Apple tonight. Apple usually take 7 days to approve a new submission. If there are any problems, then I would likely miss the 7th. The real area of concern is that from Feb 1st, Apple are insisting that all submissions are done using XCode5 and target iOS7 as the build SDK. In theory this shouldn’t be a problem, however in order to guaranty this, I need to build with the latest version of the Marmalade SDK 7.1.1 and as this version is only BETA at the moment I have slight concerns. I am currently not able to submit to MAC Appstore because of a Marmalade issue, and that affects my confidence in it.

The Android version appears to be ready. The first initial sweep has been done and a few small visual bugs stamped out. The game UI now seems stable across resolutions so I would suspect that supported devices will be the same as with The Lords of Midnight. I don’t foresee any issues moving forward. The turn around time on Google Play is such that I still have plenty of time to fix anything that crops up.

I have done a Blackberry build, and it all seems to be running in the simulator without issue. I need to perform an actual device test but again I don’t foresee any issues. There were some initial problems with the Q10 720×720 resolution but they have been ironed out. BTW: this version will allow the Q10 to rotate and I will include this fix in The Lords of Midnight ASAP.

Samsung and Amazon builds are just packaging. So again, I don’t foresee any issues.

Windows and OSX builds should be good, as this is how I develop. I expect to hand over a master to Fastspring and GoG.com early next week.

The only issue with the OSX version is that it is unlikely to be available in the MAC Appstore for a while. This is due to the aforementioned issue with the Marmalade SDK and OSX Mavericks. If the issue is not fixed soon, and I have a window of opportunity before the 17th ( preferably by the 10th ), I will install an OSX Mountain Lion machine and attempt to build the app. The OSX version will however be available direct or through GoG.com, where I don’t need to release a signed app.

Once the release is out there, I intend to revisit Windows Phone 8 version of both Doomdark’s Revenge and The Lords of Midnight.

Shading the night sky…

One thing that got carried over from the original Midnight Engine was the shading of the landscape depending on the time of day. The original Lords of Midnight, has a different colour for night which is basically that all the white becomes black, but the blue remains the same.

In TME and therefore the remake, I have a tint colour for each time of the day, and the images are tinted toward that colour. That colour is generally a shade of grey and it is used to darken the dawn, brighten up to normal colours around midday, and then dark off fully to night. In reality, this is one area of the remake that I left in that I don’t like. Only because, it doesn’t really look like the original. The night view has a very distinctive look, and as you can see though, the remake doesn’t look the same. It’s fine as things goes, but I would have much rather made it look more like the original.

Doomdark’s Revenge however has a completely different approach. There is a dawn visual, and day visual, and a night visual.

I knew therefore that when I got around to releasing Doomdark’s Revenge, I was going to have to deal with this issue. The tinting method just didn’t cut it. Because I could tint to red, or tint to yellow, but not combine them.

To give you a little background. The colour changing was relatively easy on the ZX Spectrum. Partly because the images were very simple and were constructed, but also because of the way that the spectrum only had two colours in a 8×8 grid – known as the paper and ink. So all the effects were done by just changing the paper and the ink. These colours were not stored with the bitmap either, it was a different memory area. So in fact, what Lords of Midnight does is, clear the screen with paper and ink both white, draw all the pixels to the screen, which you can’t see, and then fills in the paper and ink colours which makes the screen appear.

Now, the choice I made when porting the game was to use full 24bit alpha’d bitmap images. I can discuss the merits, and the whys, and possibly the mistakes, of this decision. But, it’s not been one I can change easily.

The upshot is: changing colours on the fly isn’t easy. It’s much easier with 8bit palletised images. But believe it or not, despite the fact that the terrain images only use two colours, they actually use at least 255 colours in order to get smooth edges, as well as being alpha’d. Changing to palletised images just made it look awful.

Once solution that I knew could work would be to write a custom shader. Shaders are dark voodoo magic that happen on the graphics card. And I’ve never written one in my life. Had Mike been around, he would have knocked one out very quickly. But obviously he wasn’t, and as I was heading toward the original release of The Lords of Midnight, I didn’t have time to look into them.

Now however, I couldn’t ignore it any longer. With the latest update of The Lords of Midnight sat awaiting approval from the platform holders, I turned my attention back to Doomdark’s Revenge, and the next thing to address, was making the dawn landscape look proper. I was going to have to learn to write shaders. And that’s what I spent yesterday doing.

The end result is that I now create all my terrain images as being black and white. These two colours will be replaced by the shader as the image is being drawn to screen. However, I can’t just replace the two colours, I need to make sure that I where the two colours meet they get blended.

mountain_fragmentIf you click on the Mountain fragment you will see a blow up of the image, and see how this would work. Affectively the image can be considered thus; all black, all white, mixed. The mixed part always being where the two meet. So if we consider that we will replace all black (0,0,0) with new colour_a and replace all white (255,255,255) with new colour_b, the other colours will be a shade of grey from (1,1,1) to (254,254,254). What we actually do is  use the value of one of the colour components to work out the mix of our two new colours. so 0 is 100% colour_a and 255 is 100% colour_b. A value of 153 for example would be 40% colour_a and 60% colour_b.

Now, it’s not rocket surgery, there’s nothing particularly clever going on here, but for me I had to turn this into a shader, and that was new territory.  However, working within the Marmalade SDK and using the OpenGL ES shader reference manual, and a little bit of google… the process turned out a little easier than I expected.

Here is the landscape without the shader active.

Screen Shot 2013-10-27 at 02.07.47

 

But with the shader active, and the two colours adjusted depending on the time of day, we  get the following.

And, if we now revisit The Lords of Midnight, we get the resulting night landscape that I always wanted.

Screen Shot 2013-10-27 at 01.10.33

 

Not sure when this will make it back into the current release, probably after Doomdark’s Revenge is released and I’ve been able to fully test the shader across multiple platforms. But it will make it back.