Game Design, Programming and running a one-man games business…

Fixing the AI orders (again)

Some cunning GSB players noticed that the orders were not working correctly in terms of attacking certain classes of ship. If you deleted the ‘attack fighters’ order, the desired behaviour was that the ship ignored fighters until there were only fighters left.

This bit of code was broken and basically needed re-doing. Now you might think it’s an easy algorithm that goes like this:

Go through each intact enemy ship
Pick the optimum one out of the classes we should shoot at
If you still have no target...
Go through each intact enemy ship
Pick the optimum one ignoring class.

Leaving aside the inefficiency of parsing the 300 enemy ships twice each time, this isn’t as simple as it looks, because a lot of the time a ship will fail to find a target within range. Thats because all of the ships its ordered to fight are across the map. Ideally the ship trundles over and shoots them. So the criteria for actually picking a target differs from the criteria for establishing whether or not there are any valid targets. Plus, the idea that once all the frigates and cruisers are dead, that EVERY TIME I look for a target I have to do a dummy run through with invalid orders is just untidy and slooow slooow…

So I ended up coding a convoluted complex system which (as convoluted complex systems often are) is way faster than that. Basically Fleets keep track of if they have any ships of each class. Whenever new ships show up (survival mode) or a ship dies, the fleet recalculates that data. if the data has changed, it tells each intact ship in the fleet. Those ships then compare this against their orders, and deduce whether or not the orders still stand. If they don’t, they tell all their turret AI’s to ignore class-based orders from now on. This involves practically no overhead during a  typical target-acquisition call (which are very frequent)

That took a lot longer to code, debug and test than it did to type here :D

In other news, I fixed some dodgy server-side code that prevented challenges being deleted. I’m amazed more people did not whine at me that the ‘delete’ button on a challenge basically did sod all. It now works :D

How complex?

How complex should a game be? Obviously it’s a huge question dependent heavily on genre. Most simulation games are pretty complex. Turn based strategy can be uber complex, MMOs too. Flash games are often very simple and iphone games can be simpler still. Is it a question you can even attempt an answer to?

I think an interesting take on it, is “what are you asking?”. Too complex can mean two things:

“This game is too complex to enjoy”

“This game looks too complex. I’ll pass”

Similarly:

“This game is very simple”

“This game is too simple to be worth buying”

There are loads of games out there I might find fun, that I would not buy. There are also games out there that look awesome, and incredible, and wonderful, and I would not buy them either, and it comes down to complexity.

Take a game where you make a single mouse click to time a guy swinging a bat to hit a ball (there are many, some involve penguins). As a web-based flash game, this can be fun. You might even waste a whole lunchtime on it. But ultimately it’s throwaway disposable fun that we all know someone coded in a weekend. It’s very unlikley you would pay more than $0.99 for it at the very very very most.

Now, Take Eve online, or any of those Hex Based wargames. Or, take Empire: Total War. These are all great, awesome games, with TONS of stuff to do, incredible depth and complexity, but tbh, life is just too short for me to play them. I played eve for years, playing an hour a day or more, and never more than scratched the surface. I never got far into 0.0 space. In E:TW, I played ONE campaign game a third of the way through, then gave up. It was taking ages, and there was too much to do.

The weird thing, is not only are games like that more complex than they need to be in order to get a sale from me, their complexity actually has a negative impact on my chances of buying. Even though I know it’s irrational, I am put off buying them because I’d actually resent having paid for content I’ll never see or use. (ironically I do own E:TW anyway, but I’m aware of my own niggling feeling about it).

I’m probably not alone. I think almost everyone has a ‘complexity’ curve for games that influences their purchase decision. We all regard some games as too trivial or simplistic to buy, and some are too overcomplex and involved to buy. Obviously mass market games need to be in the sweet spot at the top of the aggregate curve. Niche developers like me can cater to the other extremes, and GSB possibly heads slightly towards ‘too complex’ rather than the opposite.

What I find a lot of game devs forget is that a game can be fun, enjoyable, playable and cool, and well made, and addictive and generally excellent, but a LOT of people will play the demo and never buy it, because they resent buying a game that seems like it’s too simple in form.

Are you one of those people, or is it just me?

Minimum Reqs. We just pull it from out of somewhere

Have you ever bought a game based upon the minimum reqs, and found out it doesn’t run? or it’s a slideshow? have you ever pheared the min reqs, but bought it anyway, and be surprised how well it runs?

Here is the inside track:

WE  (the devs) HAVE NO IDEA. WE MAKE IT UP.

Now obviously as an indie dev, I have less ability than Actiblizzard to tell you if the game will run on a 1 Gig RAM, 64 MB video card rig, because quite frankly, I don’t own one. I currently own 3 working PC’s, 1 Sony vaio laptop, 1 ultracheap dell netbook, and my main Mesh uber-dev PC.  That’s it.

Now when I release a game, I check it on all 3, then on my mates PC, my brothers PC, and a few other peoples PC’s. (other indie devs mainly). Then I take a rough guess, and we call it the min req. You might be thinking that this means it’s just me making it up, and that big publishers have 100 different PC’s and they can be scientific about it. I call bullshit.

Lets laughably assume there are only 10 different video cards on earth, and that there are only 5 different drivers for each of them. lets assume there are 5 different sizes of RAM, and 10 different hard disks, 10 different processors and 5 different flavours of windows. That gives us:
5 X 10 X 10 X 5 = 2,500 combinations. Now lets assume 10 types of soundcard and 10 different configurations of other software running (p2p clients, messenger clients, CD burning stuff, antivirus, firewalls, rootkits, viruses and other malware). Thats 250,000 setups even with these stupidly conservative estimates.

When people ask me if GSB will run on their PC (A very understandable question right now, as there is no demo), I give as honest an answer as I can, and here it is:

“My dev PC is a core 2 Duo 6600 2.40ghz with 2 gig of RAM running Vista on an 8800 GTS video card. The game runs silky smooth at 1920×1200 res with all options at Max. If you have a PC that in any way gets close to my spec, it’s a no brainer. The game also ‘runs’ on my sony vaio which has an intel onboard chip, but I have to disable the shaders for it to look right. It also runs well on lots of people’s PC’s with a lower spec, but if you have on-board video and a maximum screen res height of under 768 I really would wait for a demo”.

I’ve heard some surprisingly good things about GSB performance on MACs running emulators, even under WINE, and on very low-spec PCs, but I honestly have no real idea of min spec. So here, as a service to people on the fence considering the pre-order, if you have bought and played GSB, feel free to post your specs, and the games performance in the comments. (Note that its frame-locked to 60FPS so you won’t see it go faster. It uses any spare ‘headroom’ to do a few fancier effects if it has time)

The metagame

Gratuitous Space Battles right now is probably best thought of as a very complex, expanded and pretty versions of the space battle segments of a 4X game.

In other words, these are just battles, fought out between similar fleets with similar objectives, in the same way. It’s kind of like chess. In chess, the map never changes, the pieces are set in stone.

It takes a loooong time to perfectly design and balance the ‘sandbox’ that allows games like this to remain fun over a long period, nd its definitely my aim to get to that point. Howver, I’d also like to introduce a lot more variety and options to keep things interesting. I can always describe more ideas than I have time to implement but here are a few:

1) More unlocks, and modules in general. Although I sympathise with those people who dislike the whole unlock concept, I think there is some good middle ground. People who are very good at the game have lots of spare honor, and as long as there is nothing too game-brekaing, I think some extra, expensive modules might be a good idea

2) Scenario variety. Right now the ‘terrain’ options are quite limited. They aren’t really major in terms of changing tactics (25% range reduction isn’t really earth-shattering), and there are many more possibilities. Maybe a nebula where plasma weapons just do not work? or one where radiation levels mean that no fighters can survive?

3) Modding. There has been little in the way of formal mod support so far. I have some very primitive tools, instructions and general information on how to do stuff like add ship hulls. I should write this up and make it available.

That’s what I’m currently thinking of, and hope to add to the game. So if you think the missions are a bit samey and the ship design options too limited, this will change. If people have similar suggestions, please throw them out there. I love hearing peoples ideas.

Patch 1.08, ratable challenges

I’m just uploading version 1.08 now. It fixes a numebr of bugs and minor issues, but the two big things in terms of gameplay and usability are these:
Firstly all of the variables associated with ship modules now have fairly extensive tooltips which explain their gameplay significance a bit more. This was needed because a lot of people just Escaped out of the tutorial windows, didn’t spot there was a manual and thus had no idea how ship design worked or the components interacted. Hopefully this improves that a bit, and I also stuck a big button on the main menu to launch the manual, although if you for some reason have no PDF reader on your PC, that will seem like it just quits the game. Almost all PC’s now come bundled with the bloated crapware that is Adobe reader (try this instead), and people who self-build their PC’s know about PDF readers anyway.

The second change of note is the introduction of ratable challenges. Basically I stuffed some more data in the challenge database, and you can now sort challenges by map (only for new uploaded ones sadly) and by difficulty or enjoyment. Once you finish playing a challenge you can rate it out of five for these two variables, and the average score is presented in the slightly nicer challenge browser. There is also no longer any ‘auto’ challenges, which were crap anyway, and you can instead now filter to see just your posted challenges, to see how many people have beaten your fleets :D

This is what it looks like:

I’m aiming to work today on configurable ship orders for each ship design, to make laying out those big fleets much less of a chore.