My First Game (Uncompleted)

Hi

This is the start of my very first game, it is not by any means complete, but I am stumped as to what I should do next, and how nicely it is coded so far. Any suggests, comments or criticisms would be greatly appreciated. It is available for download from http://www.btinternet.com/~stustill/GravityWars.zip. The source code is provided (but not commented), and the main class is GravityWars.class. I hope no one thinks it is too bad and can come up with some suggestions for how I continue.

The buttons are the arrow keys, left and right for rotation and up for thrust. Exit quits the current game, and it doesn’t detect collisions or anything, the second ship is not controllable (yet).

Please note: Only select death match, nothing else works at the moment.

I hope you enjoy what I have so far :slight_smile:

Stuart

Well, there’s not much to enjoy yet, because there’s nothing to do :wink:
I’d suggest adding some game content 1st, I want to shoot things! ;D
Maybe walls you can crash into and some computer controlled enemies…
Maybe players should be able to shoot up the those walls as well.
Maybe a limited amount of fuel and a refuelling point…

Just some ideas.

As for the code, I didn’t read it much (maybe you should comment it first before expecting other people to read it), but one little thing I noticed: I would merge GravityWarsConstants with GravityWars. I don’t think there’s any point in having a separate class for only a few constants. But this is just a minor detail…

Oh, and make it Web Start enabled.

Greetings,
Erik

Thanks!

I have been trying to implement collision detection but haven’t gotten very far with it at all. I am worried that when implementing collision detection, because the ship is drawn on the fly, whether or not creating a bitmask is going to slow the game down. I suppose it only really needs to generate a bitmask when it is close to the walls, so it might not be a big concern.

When I get the basic game going, I am going to start producing levels and programming different modes for the game. One thing that I am unsure on is whether or not the way I am implement the levels is a good idea (ie each level is a class that implements GravityWarsLevel) or whether I should have large gifs /pngs for the levels?

Regards

Stuart

Regarding collision detection, you could implement it using a collision radius, and when something is within that radius, do pixel-perfect collision detection.
I’m not the most experienced in that area so there might be better solutions…

I would make a level system with a base ‘Level’ class, regardless of how you draw it (images or not).

Oh, and did I already suggest to make it Web Start enabled? ;D

Erik

NOT WORKING YET

I have added Web Start support :slight_smile:

http://www.btinternet.com/~stustill/GravityWars.jnlp

That should work I haven’t tested yet

Stuart

I don’t think btinternet.com supports the mime type for jnlp, so I cannot get web start working, can anyone suggest some where I can get free web space that supports this?

Thanks in advance

Stuart

Yahoo geocities supports it.

Geocities it is then (and I swore YEARS ago I would never use geocities :frowning: )

Thanks,

Stu

Stupid thing won’t let me upload my jnlp file, says it is an invalid file. Anyone got any ideas?

Stuart

try
www.mycgiserver.com
but get ready for lots of ‘free host weirdness’ and downtime.