I'm now spending most of my time developing C# applications so I haven't had much free time to work on my "Dave" game. Shown below is the latest video showing how far the game has developed. I hit a few problems with the collision detection mainly due to the diagonal movement of the "grannies". I decided to just let them move in the more normal left, right and up, down style. I had always thought that in the finished game they would probably not just stay in the current screen but actually walk around the whole map, going into the shops and houses etc. This more linear movement should work better and also allows me to get on with the rest of the game rather than hitting my head on the desk due to diagonal collision problems. The areas that Dave can walk are defined by rectangles and you will see in the video that Dave can walk up to the door. The code just checks that Dave is in (or is moving into) one of the defined rectangles. In the debug mode the rectangles are drawn on the screen which allows me to check that all is as it should be. The last thing that I have added it to allow Dave to throw bones at people (well he is a dog). This works quite nicely but has brought to my attention a small problem that I need to address. At the moment the collision detection is based on the bottom of the bones rectangle in relationship to the other sprites. It should be based on the initial position of Dave's feet (ie, it needs an off set value). It shouldn't be too hard to fix this as long as I can find some time to do it. The next job will be to enable the exits so that I can write the flip screen code. I will probably then look to add the collectable objects and maybe some street furniture and general obstacles. The movement of the sprites in the video isn't very smooth due to my capture program. in "real" life, they move very nicely, even when the screen is windowed rather than full screen.
Friday, 7 November 2008
Wednesday, 1 October 2008
Attack of the grannies !
Having found a few spare minutes, I've been able to work on a couple of key features of my Dave the Dog game. I've started defining the game map as an XML document. This file defines the areas of each screen that Dave and the citizens of Dave's town can walk around. It also defines which citizens appear on each screen and their starting location and direction. There is also loads of other details that are yet to be implemented. To show the current state of the game I've put together another short video. It may seem that the game is running a little slow but I turned down the speed so that my screen capture program did a better job of capturing the animation. You will also be able to see that I haven't implemented collision detection or z-ordering. These will be worked on when I next get a bit of time. For now, enjoy the site of Dave trying to avoid those annoying grannies.
Thursday, 11 September 2008
What a great summer !
Work has been a bit busy recently so Dave the Dog has not really progressed much further. In the few spare minutes before work I've been able to design the XML that describes Dave's village. I have added a couple of simple screen descriptions so that I can work on the next major area which is the code that will import the data and create a screen and all its elements. These elements define the exit points and the areas that Dave and the other villagers can walk. Any objects that can be collected or interacted with are also held in this XML. I wasn't going to use XML but it makes life so much easier to add extra data as my ideas change. This file will only be loaded when the game starts so there will be no performance problems once the XML is read in and screen objects created. As Dave leaves a screen the code just gets the next appropriate block of pre processed data from the list. It's this screen manager and list code that I'm working on at the moment. I hope that over the next few weeks I'll be able to walk between a couple of screens and be restricted to areas of the screen defined by the XML.
I feel a lot fresher after my summer holiday. For a change I didn't spend anytime thinking about programming. Instead I went kayaking on the sea and photographed steam trains and waterfalls. Unfortunately the English summer also showed why most people go abroad for their holidays. Shown below is a picture of Sidmouth (Devon) in the middle of August. Please note that I did not go out in a kayak whilst the weather was doing this.
I feel a lot fresher after my summer holiday. For a change I didn't spend anytime thinking about programming. Instead I went kayaking on the sea and photographed steam trains and waterfalls. Unfortunately the English summer also showed why most people go abroad for their holidays. Shown below is a picture of Sidmouth (Devon) in the middle of August. Please note that I did not go out in a kayak whilst the weather was doing this.
Thursday, 24 July 2008
Into the world of Dave
Coding has taken a bit of a back seat whilst I worked on some graphics. I needed to produce something to code against so that I can check the animation etc. Shown below is a mocked-up screen showing what has been produced so far. Now that I have produced some sprites I need to get back to writing the code. Hopefully I'll have another short video soon of Dave walking about his town (need to think up a good name for it).
Wednesday, 9 July 2008
Dave the Dog lives...
I've been a bit quiet recently as the day job has sapped all my time. To make matters worse I got a virus that was so bad I had to format my drive and re-install Windows ! I lost some code as well as time which was depressing. To try to cheer myself up I had a quick look at my "Dave the dog" game and even found time to create a short video of the basics. I resized the "granny" sprite as the last post showed her a little too small (or was Dave too big?). Anyway, this video shows Dave walking about under the control of the keyboard and the granny is controlled by the computer. If I'd captured more video you would have seen that she bounces off the sides of the screen and changes direction. [NB: This video has now been removed. See the more up to date video in a more recent blog entry.] Currently this is written in Delphi but I am very tempted to produce an XNA version using C#. I may well develop both simultaneously just to see if I can fry my brain. From now on I'll be storing my code in different places so that if I get another virus I won't loose my data.
Friday, 6 June 2008
Its Dave the dog
A few months ago a private joke amongst my family and friends got me thinking about a game I started for the Amstrad over 20 years ago. It was based on a dog walking around a town doing jobs etc. This reawakening of a distant memory has inspired me to start it again but this time for the PC. Once its completed I'd like to write it for the Amstrad and Spectrum computers. The main character is called "Dave the dog". He is based on the dog that appears in the first (and possibly the second) Jack the nipper game.
By using my game library code I quickly got Dave controllable and a mad granny bouncing off the edges of the screen. I have created a map of locations and have a reasonably good idea for the story line. I just need some help with the graphics and plenty of time to get it done. I'll post more screenshots as I progress.
Cavern Fighter 2 is on hold for the moment as I was finding it difficult to get motivated with it. I'll revisit the code in the future.
By using my game library code I quickly got Dave controllable and a mad granny bouncing off the edges of the screen. I have created a map of locations and have a reasonably good idea for the story line. I just need some help with the graphics and plenty of time to get it done. I'll post more screenshots as I progress.
Cavern Fighter 2 is on hold for the moment as I was finding it difficult to get motivated with it. I'll revisit the code in the future.
Thursday, 20 March 2008
DevWeek 2008
I've recently got back from this years DevWeek held in London (www.devweek.com). This event was biased towards Microsoft products so wasn't really relevant to any Delphi programmers. Obviously as most of it was .net related I guess you could implement some of the technology using Delphi for .net. Now that I'm back at work and no longer have the "fun" of standing on a train as it meanders its way in to Liverpool street station, I can get back to some fun stuff. Over the next few weeks I'll have less spare time as new work projects will take up all my time. The company I work for will be concentrating their efforts using the new MS products. So it'll be less Delphi and more C# along with Silverlight and AJAX. All interesting stuff but I'll still be looking at my games as a break from managed code.
Subscribe to:
Posts (Atom)