Friday, March 17, 2006

Embedded scriptable 3D game engine

The 3Impact game engine is really fun to play with. I wanted a couple of things from it in order to use it for a game, though.
  1. I'd like to have a mini version of my games that would be playable right on the web in the users's web browser. A lot of people on the web want this, even if they have to download an ActiveX control to make it happen. If they don't want to download the control they can always download the full version of the game.

  2. I want to be able to script it with JavaScript. This would allow quick prototyping, scripted AI and even the potential of writing an entire game in Javascript if the code requirements are low enough not to slow the game too much.
So Thursday morning at Starbucks I decided to whip this out. I'm probably one of the last COM / ActiveX hold outs but I'm pretty good at it. I've got quite a bit of experience hosting the Microsoft JScript engine and having worked on the Internet Explorer team in a previous life (IE 5.0), I have pretty good experience developing for Internet Explorer. I had to jump through a few hurdles but managed to get a working prototype.

I created a video of it running in my browser below. I've exposed several of the 3Impact types as scriptable objects but need to do several more. The most important thing I need to finish is the ability to stream down your game content over http (models, textures etc.).

My goal is to have all of the 3Impact demos running inside the browser. They pretty much use all the APIs in the engine so should prove to be a pretty good test.

I don't know about you but I'm pretty impressed. I showed it to my wife. She clearly wasn't impressed but she's a tough audience. :)

Note: Flash video requires the FLV movie to be on the same domain as the HTML page you are viewing. SWF does not appear to have that restriction. Sooooo... since the move is actually hosted on my personal domain site, head on over to have a look.

http://www.chriscowherd.com/2006/03/3impact-activex-control.html

0 comments: