While writing the SNTask utility I had to do some network programming. I have done a lot of network programming in the past mostly using C and Berkley sockets. It’s pretty simple to get basic communication going with that combination but anything more sophisticated requires much more design, debugging, and maintenance. Using Python instead of C helps but I still have to use sockets. SNTask is a utility which is supposed to aid our game development. It’s not supposed to spawn a development cycle of its own. I didn’t want another piece of software our team had to design, debug, and maintain. SNTask has a lot of requirements but its purpose is to quicken our development. Luckily there is a wonderful networking framework called Twisted which allows us to add all the features we want to SNTask while still keeping the workload to a minimum. Twisted is written in Python and released under the MIT licence. Twisted greatly simplifies the task of writing almost any kind of network application. When programming with raw sockets I would usually dig around my computer and find my old networking library. It’s a small library I wrote along time ago which can send and receive packets over UDP or TCP. I would then start creating the application using that same old library. Twisted replaces all that and allows me to immediately start creating the application. It supports TCP, UDP, SSL, IMAP, SSH, FTP, HTTP and much more. The Twisted Framework has already allowed us to reduce the development time for SNTask while boosting its feature set. I have only been using Twisted for a couple of days so I have only grazed the surface of what it can do. So far I am very impressed.
One part of our next milestone consists of extending our automated build system. We already use Buildbot to automate most of our builds and testing. Every time source code is checked into the repository it is compiled and all unit tests are run. If the compile or unit tests fail the entire team is notified via email.
Our next milestone requires us to take our automated build system one step further. Source code and game source assets will be automatically built and distributed for all to use when checked into the repository. Any changes to the source code or game assets will result in all developers automatically using the updated version. If bad source code is checked in (it doesn’t compile or fails a unit test) then the build will fail, the team is notified and the broken version is not automatically deployed. There are many other cool extras we get for free when using this system. For example the ability to automatically deploy any version of the repository. If something went horribly wrong with the latest checked in version we can instantly build and deploy any prior version of the repository and all developers will automatically be using that version. Developers can deploy and work on different versions of the repository at the same time. This can also extend to branches and tags. We can have one part of our team working on an unstable branch of the engine while the other part is working on the main trunk of the repository which is stable. Each team works on their own branch and any changes they make are automatically deployed to the others using that same branch. When the unstable branch becomes stable and is merged into the main trunk then the new changes are instantly deployed to the group working with the main trunk.
This will also be very useful for game assets. The artist never has to compile or generate game assets from their source assets and then check the generated game assets into the repository. They just check in their source assets which are then automatically built into game assets and deployed to all developers. To test the new automated build system we decided to make another small game. Gavin and I are going to do most of the modeling so we can become acquainted with Maya. The game is a simple target range where you can shoot at various objects. As a result I felt compelled to name our current milestone “Hogan’s Alley”.
We have been hard at work on our fourth milestone titled ‘Pub Crawl’. All of our major goals were finished by our deadline on Sunday. This included creating ScriptNodes, updating snTools, and creating a small game to test them. I went into the milestone with the idea of creating a hacky throw away game system which sole purpose was to test the ScriptNodes. The system turned out better then I thought and we began to gain some insight into how our actual game system might operate. Denrei has been working endlessly on modeling the pub and its characters. His apartment filled with water during the flood and I think he has been living off of Zebra Cakes and Chipotle as it’s all I have seen him eat. Our milestone most likely won’t be publicly available for a little bit because of our big move to the new apartment. A lot of our time this week will be spent packing and unpacking. Not to leave you hanging here is a development screenshot of Pub Crawl.

Crossblast was the result of our third milestone “Lord of Collisions”. The main goal of the milestone was to finish the engine’s collision system which included the maya exporter with bounding volume nodes. The original end result was supposed to be a simple level where the user walks around and collides with objects. The objects would then glow to show the collision. After the first week or so we had a simple sphere colliding demo. You could move around a sphere and bump other spheres. The collisions were being processed and passed to the python code. We realized that a much better test of the engine and tools was to create a simple game in 24 hours. We didn’t want to spend more time on it then we had to as it was not our original goal for the milestone. After designing a simple game Denrei realized we had thought of the game once before. A while back we were creating a simple test for our last engine. It was named “Crossblast: Struggle of a Lifetime!” It might have had more exclamation points but I can’t remember. That game never came to be but it did generate some artwork which was never used. Denrei quickly found the old artwork and it was reborn into the new Crossblast.
Creating the game in 24 hours seemed like a challenge. In actuality it wasn’t very hard to accomplish due to the stable state of the engine. There were no show stopping bugs to hinder progress on the game. Python is a great language for quickly prototyping things and then implementing them. This allowed me to quickly prototype an idea for the game and if it turned out to be good the work was mostly done. The same game code written in C or C++ would have taken at least twice as long to develop. The more I use python the more it becomes apparent how much quicker and easier software can be developed with it.
After finishing the game we had a double elimination tournament. The game was displayed on a large wall with a nice projector. I didn’t even place in the top 3 proving that I am the worst Crossblast player. After the dust had settled Denrei was the victor. I should have programmed in some cheats or something to give me an advantage. I think I may just retire and become a Crossblast coach. He’s good, but with my help, he could be the best.
One really hard task was testing Crossblast on a wide range of computers and operating systems. We don’t have a ton of spare computers lying around so we couldn’t do a thorough test on different video cards and systems. This means that crossblast was only tested on high end machines. It will most likely crash on other systems for very simple reasons which I can’t reproduce without more knowledge about the computer it crashed on. For the next release Stolen Notebook will be more prepared for this. We will be setting up a testing system which PXE boots. Upon PXE Boot it will load a menu from a TFTP server which has a selection of operating systems to install. This will quickly install a fresh ghost image of the selected OS. I will most likely write a more thorough blog on how to setup this configuration.
Crossblast isn’t a finished game. It’s only a milestone test. There were some memory leaks which I found after we released the milestone. I may create another version with the fixes but for all purposes the Crossblast milestone is done and we are moving on to the next milestone titled “Pub Crawl”.
While making our collision system we kept in mind the idea of someday implementing it with a collision detection library other then our own. As a result we designed the collision system to be easily implemented with any collision library. The changes to the implementation are invisible to the rest of the engine. I wrote an implementation for the collision system which included basic intersections between oriented bounding boxes, spheres, and rays. After finishing the initial implementation we decided to use the Open Dynamics Engine. ODE is a nice open-source physics library for simulating rigid body dynamics. Under the rigid body physics system it has a very simple and easy to use collision detection system. I was saddend to see my collision implementation go but its tragic death was not in vain. It allowed us to create a nice collision system which was not tied to or influenced by any existing collision library’s API. This made implementing the collision system with ODE a very straightforward task.
I finished most of the engine’s collision detection for the next milestone. It’s coming along nicely and fits well into the scene graph. My rusty math skills have come back to haunt me by slowing my progress some. I have mainly been doing network programming for the last couple of years so I needed a little review. I tried to obtain the knowledge by means of voodoo but I ended up burying Bill Pullman alive in my back yard. According to Hollywood that’s pretty much how a voodoo ceremony should go down. Yet, in the end, I had obtained no additional math skills. Finally, I realized there was no quick fix. I would have to buckle down and do it the old fashioned way. I hid behind a car outside the math building at my local university. When people walked out of the building I jumped out and yelled a quick question about trigonometry at them. This usually resulted in either them or me running away. It’s a sick world we live in.
I am currently working on the engine’s collision detection. The two books I ordered from Amazon.com showed up today. Does anybody care about this?