
Description
Duck Hunt
For the past while, I have been working on porting my engine over to JavaScript WebGL. I decided to take what features I implemented so far and built a game with it. The result is Duck Hunt, a WebGL based game where you shoot down as many ducks as you can before they escape. You have 6 shots per clip before you must reload. The game gets faster and more difficult the more you shoot. Submit your score online and see how well you rank against others in the top 10 list.
Click here to play Duck Hunt.
Known Issues
The game was tested on Firefox 4.0.1 and Chrome 11.0.696.68. The game requires a computer with a WebGL compatible video card and drivers. There are some audio playback issues in both Chrome and Firefox. Chrome seems to have complications when you attempt to reset the audio position back to the beginning. It also doesn't handle multiple sounds very well. Firefox is almost flawless, except that it sometimes runs into a network issue and cannot load the game music, throwing a 404 error without an actual server response (say what?!).
Tech Stuff
The core Nutty WebGL Engine currently features:
1. High level OGL ES 2.0 classes to manage VBOs, FBOs, shaders, and rendering.
2. Particle emitters with support for injecting custom particle modifiers, making it really easy to experiment with various particle effects.
3. UI system with controls such as buttons, progress bars, images, lists, window frames, etc.
4. Loads resources and UI controls via XML files with support for custom elements.
5. Supports keyframe animations and storyboards, as well as sprite animations.
6. Various math routines, matrix and vector transformation classes, intersection testing, etc.
Next Steps
Skeletal animation is one of the last remaining features to be ported over. Following that, I'd like to build a couple more games and see how things go.
About WebGL
My development experience with WebGL has been a pleasant one so far. If you come from a background of OpenGL, you will find WebGL to be quite familiar and easy. If you don't have any experience, it makes for an excellent platform to learn from. For a good intro to WebGL, check out Leaning WebGL.













