Polygon Skirmish

Free download at: tylergriffin.me
Link: http://tylergriffin.me/PolygonSkirmish.jar

http://tylergriffin.me/PolygonSkirmishScreenshot.png

A fast-paced 2D shooter I’ve been working on in Java. I’ve done some things to eliminate all external asset files, so the game is fairly small on disk. The audio is synthesized on startup, and the polygon information for the characters is built into the source code. I created their shapes in Blender 2.63, exported them as .obj files, then used a program I wrote to grab the points out of the .obj files and print out useable Java source code (just big array declarations).

I hope to continue working on this project. I want to add more advanced AI and more weapons, enemies and effects. I may be posting the source code on tylergriffin.me in the not-too-distant future.

Any feedback, technical or not, is appreciated. :slight_smile:

Is there any reason to include the data in java files? You know its quite easy to load a file that is in the jar right?

Each to his own.

Cas :slight_smile:

Yes. I’ve pulled assets from the .jar in other projects. Putting the polygon data into the java source really only saves the space that would have been taken up by IO code. The way I’ve done audio really saves a lot more space. I generate the audio programmatically through functions, so instead of a kilobytes-long audio file, I have just a few lines of code per sound.

It’s quite neat and works smooth here. I found controlling the ship somewhat hard, since I’m more used to a wasd=forward/rotate left/rotate right/backward scheme. But in a way that makes it a nice challenge for coordination, since I’ve got to adapt. Its a neat little game and I really have not much to suggest, other than possibly a little variety in enemies.

However, the simplicity has got charm, so maybe just leave it as it is ;D

Thank you so much for your feedback! I agree that it could do with some new baddies. Call this one “Version 1.0”. More baddies to come.

I played one game of this. I like the mechanics and the particle effects!

The only complaint I have for a version 1 is that the enemies can spawn on you! This makes for a very unfair death IMO.

A Tip that might make the bullets look better.
It’s very late and I’m not thinking clearly any more but I think this is right…

Calculate the forward velocity by running Math.atan2(yvel, xvel) * 180/Math.PI and add this to the bullet’s velocity.

Also: I got a random crash after about 40 kills…it seems to be a recurring crash (I’m not getting any kind of error log)

i get this error when running

Exception in thread “main” java.lang.UnsupportedClassVersionError: Window : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)

im on a mac osx 10.7.4 and i use java se 6