Thursday, June 21, 2007

Mojo

Around the time of my last blog I was struggling. Things were moving slowly and coding the game was tough. I felt like I was wrestling with a hefty gorilla, rather than the playful chimp it normally is. I'd lost my mojo. I was out of the zone. I needed something. A spark of some kind.

And then it happened. I scored a goal. Sure, the game engine is far from complete and my players are just rectangular blocks and but I scored a goal of such simplicity, of such elegance that immediately my spirits were lifted. Let me describe it for you.

Having won the ball about 25 yards from goal I looked up and saw a chance to shoot. I let fly with my imaginary right foot (the players don't have legs yet, remember!) and the ball flew goalwards. To my dismay it cannoned back off the left post and a quick thinking defender hoofed it away, up towards the half way line. After a scramble in the midfield the ball breaks loose and finds its way to my strike partner about 30 yards out. I'm standing to the left of the centre backs, slightly behind them but still onside thanks to the slow reactions of one of the fullbacks. A quick tap of the call button and my team mate feeds the ball between the centre backs and I rush forwards to control it. Taking it in my stride I realise that no-one is going to catch me and I'm one on one with the goalie. Despite lacking any real AI, the keeper rushes out to tackle me nonetheless. I quickly assess my options. A quick tap of the shoot button will drive a shot, but the keeper will have a good chance of blocking it. I could attempt a cheeky chip, but the last time I tried that it didn't work at all (note to self - fix the chip shots). I decide to dribble it around him.

So as he closes in, around the penalty spot, I tap the sprint button and knock the ball away to the left of the keeper. His momentum carries him past me so I easily retrieve control of it before he can react. Now though I'm nearing the byline and well wide of the goal. No matter! Keeping a cool head I direct a soft low shot back across the goalmouth and into the far corner from the tightest of angles. The crowd roars (well it would do if i'd programmed any sound yet) and I wheel away to celebrate with my delirious, blocky team mates.

I quickly pressed the replay button only for a message to pop up, "you have attempted to access a null object". Damn. The save replay feature isn't working again. Oh well. The replay itself wasn't important, it was all about the moment. As I said, a simple goal, the kind of goal that is scored week-in week-out all over the world. But that's what made it special. The game is starting to immitate real football and suddenly I was re-invigorated. I can't help but think that this is gonna be one helluva game. I was back in the zone, mojo restored and the boistrous gorrilla is behaving again.

Monday, June 18, 2007

Stop the world

Wow. Time moves too fast, doesn't it? I can't believe it's mid-June already. Week after week is flicking by relentlessly and I edge ever closer to the predicted release date of Autumn 2007. I hate to say it but I'm starting to doubt that I'm going to fulfil that goal. In fact I am almost positive of it. As it stands the game is roughly 50% complete and with just a handful of months until the Autumn I don't see how I can get everything finished and tested by then. It's very disappointing, as much for me as for anyone else but it is vitally important that I maintain the level of quality that I hope I have produced so far. One of the benefits of being an indie developer is that the game isn't released until I say it's ready. I have no official deadline to work to, so if it takes until Christmas then so be it. Rest assured though, I will be striving every day to complete the game sooner rather than later. And just prove that I haven't been twiddling my thumbs for the past 10 months, here's a run-down of where we're at with New Star Soccer 4.

I like to break the game world down into 3 parts. Foundations, Match Engine and Life Style...

Foundations
The foundations of the game consist primarily of the database and the code that makes that database come to life; the progression of time, competitions taking place, the transfer market, players growing old and so on. I am very pleased with what I have done so far but there is still a fair bit to do. I still need to implement club continental competitions such as the Champions League and fix a few issues with various awkward competitions that don't fit the norm. I need to ensure that fixture clashes are avoided either by arranging dates correctly at the start of a season or by re-arranging dates as clashes develop midway through the season.

I need to build a realistic transfer market where every club constantly strives to improve their squad which means they have to target players that might realistically sign for them, and then a process of negotiation ensues. One thing I won't allow is for superstar players to transfer to lower league clubs, or indeed super clubs buying hopeless players.

What I have left to do on the game foundations aren't really major tasks, they're just boring and require a lot of testing. I did hope that the foundations would be in place before development started on anything else but alas I was sucked into the exciting world of the 3D match engine or to give it it's official title:

Sensational Engine 2.0
This section of the game has been consuming most of my time lately and progress is good. As you know from previous blogs players move in formation and they can dribble, pass and shoot. Well now they have a "field of view" which is determined by their 'vision' attribute. Basically the higher a player's vision stat the further he can see and the wider his peripheral vision. Imagine an invisible cone stretching out from the player's eyes, and anything that falls within that cone is visible to him. (If you've ever played Metal Gear Solid you'll know what I mean, although NSS players won't be quite so short sighted as those idiot guards.) Thus a player's range of passing is dependent on his vision, and shooting will require a clear sight of goal.

I've also been working on 3D stadiums with a forum member called "Scrumble". We're pinning down the basic size, the level of detail allowed, and making sure everything looks right. Here's a shot of a very basic stadium.

Not that impressive, I know, but at the moment we're just trying to lay down some rules for future stadium designers. We'll start experimenting with textures soon which should make them much more exciting to look at. I'm hoping that some eager forum members will take up the challenge of designing all the major stadiums from around the world.

Back to the football itself. Basic set-pieces are now in place, so it's possible to have throw-ins, goal-kicks, corners etc. I still need to fix a few positional problems (making sure everyone is in the right place during set-pieces) but that shouldn't be too hard. After that it will be possible to start feeding the match data back from the sensational engine into the game world. This will be a major step forward as it will mean that during development we can actually play out the fixtures and the relevent match stats will be updated in the game world.

One major aspect of the match engine yet to be tackled is player animation. This will come once the underlying gameplay and match rules are all in place, although I think goalkeeper AI might have to wait until I have jumping and diving animations for him to perform.

Another part of the Sensational Engine I will need to implement is the new training challenges. I have some good ideas for new challenges but player skills now range from 0 to 100 so I can't possibly have 100 different tests for every skill. Therefore training will be an altogether different experience from that of NSS3. Expect more details on this in the future.

Life Style
This part of the game covers everything that is not strictly football related. In other words, relationships, incidents, shopping, gambling etc. The stuff that adds colour to the game and provides a distraction from purely playing football. This is the one area of the game that I have yet to make a start on. I'm hoping it will be the easiest section of all to program and it is certainly the least important right now, because without the foundations or the match engine there is no game at all. For these reasons I am leaving it until last, but I expect to enjoy it the most as it will be great fun giving the player a life, with all the pitfalls that entails, and of course, this section of development will be the downhill slope.

So that's where we are right now. Let's hope that by the time I next blog we can tick off another couple of major game elements so that maybe I can stop cursing the fact that the sun sets far too regularly. :D