Month: May 2010

Planitia Update 40: Feel the Source!

Gettin' back to basics.

All right, people, here it is. The current source code to Planitia, along with the cut-down, more retro-styled resources. (The previous animated sprites not only didn’t look that good, but they ballooned the project size to over a hundred megs – what the hell was I thinking?!)

Click here to download the latest playable version of Planitia!

Click here to download the source code and resources necessary to get the project running!

Now, having clicked that link, your work here is not done. You will read to the end of this entry before you start asking questions about how to get this working. Okay?

That zip file is going to extract into two directories – one called “Planitia” and one called “Framework”. That’s right kiddies! As a bonus, you get the framework I use to make all my games nowadays.

Here’s what you’ll need to do to get this project working.

Install Visual C++ Express 2008. Yes, I know, Microsoft just released Visual C++ Express 2010 but I haven’t tested with it yet.

Install FMOD EX.

Install a version of the DirectX 9 SDK.

Alter the include and library paths in both the Framework and Planitia projects to point at the local versions of FMOD and DirectX.

Alter the include paths in Planitia to point to the Framework source.

Check Project Dependencies for Planitia and make sure it’s dependent on Framework.

The working folder for Planitia is “Redist”. You’ll probably have to put your versions of fmod.dll and the directx redistributable in there to get your particular compilation working.

I’m sorry I couldn’t make this any simpler, but it shouldn’t be that hard to get running (under Windows, at least).

If you have any questions (that aren’t covered in the above instructions), please feel free to either leave a comment or email me at anthony.salter@gmail.com.

Good luck with the source! And don’t worry, just because I’m releasing the current source doesn’t mean I’m done with Planitia.

EDIT: I have been asked what license this software is being released under. I am releasing it under the Simplified BSD (or FreeBSD License). The upshot is that I retain copyright, but you are free to do anything you wish with this source code (up to and including developing a commercial project with it) as long as you attribute the original source to me. This source is being provided “as-is” and I take no responsibility for any problems you may have with it.

The complete text of the license follows.

Copyright 2010 Anthony Salter. All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY ANTHONY SALTER ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ANTHONY SALTER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

The views and conclusions contained in the software and documentation are those of the authors and should not be interpreted as representing official policies, either expressed or implied, of Anthony Salter.


Fixing Bad Colors in Older Games on Vista and Windows 7

Okay, I’d been getting this a fair amount after getting a Windows 7 box. I’d install an older game, like Dungeon Keeper or Populous: The Beginning and I’d get very strange colors, sometimes just in the menus but sometimes in the game itself. Annoying, but hey, they’re older games.

Then I reinstalled Starcraft, and the same thing happened.

Now, Starcraft is probably the most reliable piece of software ever written, and watching it come up in psychedelia was painful. I knew there had to be a solution. And there is.

In Vista, right-click your desktop and choose “Personalize” from the resulting menu. In Windows 7, right-click your desktop and choose “Screen Resolution”.

Don’t do anything in these screens; just leave them up.

Run your game. Your colors will be fixed.


Planitia Update 39: Begin Again

Planitia? Really?!

Yes, really.

Back when it was current, I routinely checked out the Image of the Day from Flipcode.com. Most of the efforts were amateurish, until I got to this one.

The screenshot doesn’t do it justice. TopcaT (whoever he was) had created a basic RTS game engine with a ton of functionality, including texture blending based on terrain slope, importing of 3D models and procedurally animating them, a particle system for doing combat effects, A* pathfinding for the units, and an impressive LOD system using octrees.

And he was giving the source away. Honestly I couldn’t understand it – that demo could easily have gotten a job in game development; why did he give up on it?

Not only did he give up on it but he soon fell off the internet entirely (seriously, I’ve been looking for him for years). I’m very, very glad that I kept the source to his engine; it would have been horribly wrong for something with such potential to just disappear.

(I still have it, of course, you can download it here.)

But as I untangled the source code in an effort to figure out his tricks and replicate them I finally figured out why he’d given up. Basically the source was so chaotic that he just couldn’t add anything to it any more. He had fought code entropy and lost.

Just like I did with Planitia. To my credit, I got much closer to “game” than he did (even if it didn’t look nearly as technically proficient as his did). But in the end, it got to the point where the code was so awful I didn’t even want to look at it.

But why? Why had this happened? In the end, the terrain is a heightfield and the units are billboards…it’s an inherently simple concept. How had I stuffed it up?

Graphics, of course. For someone in my position, doing the whole game myself, graphics are evil.

Daniel succeeded with Hero Core because he kept the graphics within the realm of what he was capable of; I failed because I did not.

The truth is that I should never have gone down that path. Trying to make Planitia look like a commercial product (which, let’s face it, is what I was doing) was simply outside my capabilities as a programmer and an artist. Using the better-looking terrain tiles drew me into six months of terrain rendering, and while I learned a lot none of it contributed to getting the game done.

Then I didn’t like how the non-animating sprites looked on th nice-looking terrain and so I added the animated sprites I got from Reiner. This was was just a terrible move – animations on the same character had different dimensions for each frame and the “easiest” way to handle the entire procedure was to cut out and load each animation frame individually. The results were pretty impressive…but just not impressive enough, and the amount of work was just stupid for the result. And none of it got the game closer to being finished!

Then I had yet another request for the Planitia source code. I’ve been loathe to give it up, not just because I feel it’s substandard but also because of the hundreds of megs of associated resources currently necessary to get the project to run.

And then I thought about the article I just wrote about Hero Core, and how I praised Daniel Remar for designing the game around the art he could do.

Epiphany.

While I know a lot of people may not like the direction I’m taking Planitia, I feel it’s necessary to actually complete the project. Planitia’s native resolution will drop from 800×600 to 512×384. The pretty tiles will go away, replaced by more retro-styled and functional terrain. Lighting will stay, but alpha-blending and smooth shading will not.

Units will become based on the units from Powermonger. They’re simple, they were made specifically for this kind of game, and they work. But they wouldn’t look right placed on top of a more modern style of terrain, which is why I’m knocking it back (that and it’ll make the terrain so much easier to maintain).

Basically, Planitia is about to start looking a lot more like the games that inspired it, specifically so that I can focus on the gameplay and AI and get the darn game finished.

But I won’t wait until its “done” to start source releases. The first source release should be by the end of this week, as soon as the changes to the units and terrain are finished.


Galactic Civilizations Ultimate for $10

Right here. You no longer have any excuse.


More on Hero Core

I’m going to talk about Hero Core a little more. Because I wanna.

There’s a lot to like about Hero Core. It may be the most perfect one-man band game I’ve ever played (although technically it’s two men because the music was done by Brother Android). It’s a perfect study in overcoming the limits of your own abilities to produce greatness.

Can’t do great art? Design your game so that you don’t have to. Hero Core runs in 320×240 and is in black and white (not monochrome, mind you – black and white are the only two colors used). Almost everything that moves is a particle of some kind, and they are almost all made of simple geometric shapes. The actual levels are made up of square tiles – no attempt to soften or round them was made. The main character doesn’t even have any frames of animation! While the word “retro” is horribly overworked, this game literally looks like it was made in the mid- to late-Eighties for the ZX Spectrum. Practically anyone can do art at this level, and it’s effective. Contrast this with Daniel’s previous game Iji, where the art is by far the weakest part of the game because Daniel isn’t that great at drawing and animating humanoid figures.

The game’s design strikes a perfect balance between challenge and accessibility. Death has practically no sting – all that happens is get warped back to your last save point. And these save points are everywhere, fully refill your health when you use them and allow you to teleport between them. That last bit is the really brilliant part – Daniel Remar has made a Metroidvania that doesn’t have any tedious backtracking in it.

The end result is that Daniel can make the individual rooms (or a sequence of rooms) difficult without making the game frustrating, since all you have to do is make it to the next save point – or teleport elsewhere if you really think you’re not ready yet. And while it’s not quite NES hard, it gets very challenging towards the end and veers into bullet hell territory on the higher difficulties. But practically anyone can finish the game because you don’t need an impossible level of skill; you just need a moderate level of skill and some perseverance. I’ve said it before and I’ll say it again – allow the player to trade time for skill.

So, to sum up, great design, effective art, excellent music and it didn’t take him four years this time. Bravo, Daniel. Bravo.


Hero Core

Okay, this isn’t Zeta, but it’s got a lot of the feel that I would have been going for with Zeta. And it’s darn fun, so you should try it out. It’s called Hero Core.

It’s done by Daniel Remar of Remar Games, who also did the excellent Iji.