BlockLeftTop, PRELOAD BlockLeftBottom, PRELOAD BlockLeftStretch, PRELOAD BlockTop, PRELOAD BlockBottom, PRELOAD BlockStretch, PRELOAD BlockRightTop, PRELOAD BlockRightBottom, PRELOAD BlockRightStretch, PRELOAD
DeltaEngine

Lost Squadron, Day 14: Effects and Game Unit Testing

by Benjamin Nitschke 24. December 2004 09:43
First of all: Merry christmas to everyone and thanks for reading all this stuff, my page views increased a lot since I do this daily series.

I spend the last couple of hours trying to get Unit Testing on the engine level to work and I finally got now everything up and running. This is really one of the greatest things ever in Game Development IMO! Normally I would spend a lot of time changing code to just test stuff or even write small test application only to check the behaviour and graphical output of effects, newly imported textures or models or new game features. Now I can just write a VERY short Unit Test for that INSIDE my project, no more extra projects, no more messing around in the code.

Just to make this clear: This is not a usual Unit Test like in other parts of the engine, like when checking file input/output, internal methods or some logic issues. These Game Unit Tests (thats how I will call them from now on, or just GUT, which is german for good ^^) give you all the features and easy testing possibilities like normal unit tests, but you can initialize the whole engine, see visually whats going on and shut down everything automatically or by user input. Let me give you an example how this looks:


Note: This code uses .NET 2.0, if you want to read about Anonymous Methods click here.

Same thing is of course possible with a couple of lines more code when not using Anonymous Methods (using Events or just duplicating the code in TestInitEngine). This code will create all the stuff required for the game engine, then execute the initialization code to create the effectManager. Then it will proceed to the game loop and execute the render code each loop there, everything will be shut down if the user quits the form, presses some key or if we set a timeout to quit automatically. There is a lot of hidden code behind all that, but this is exactly the code executed when just running the game and testing that is always good :-)

In the next 2 days I will not code much (visiting family, chrismas, etc.), but I will to read 2 nice book from Steve McConnell: Code Complete 2 and Rapid Development. I already read a couple of pages of Rapid Development and it is really written good and very interessting.

The next Lost Squadron screenshot will be posted presumably in 2 days.


Day 14:
The game itself did only get some minor improvements today, I spend most of the time on the engine. As you can see on the screenshot, there are now effects like that explosion effect (there are already over 20 effect types), but the EffectManager isn't complete yet. Additionally to the road it is now possible to set railroads and I imported some new objects and new graphics into the editor (not on the screenshot).

Comments


12/27/2004 8:08:48 AM #

Dein erster Eintrag aus Korea Smile
Gruss vom Flughafen auf dem Weg nach Sydney !

karsten | Reply



8/29/2006 11:36:29 AM #

I agree

recombinant | Reply



3/21/2010 5:59:37 PM #

Pretty good post. I just stumbled upon your blog and wanted to say that I have really enjoyed reading your blog posts.Any way Ill be subscribing to your feed and I hope you post again soon

Car Servicing | Reply



4/18/2010 5:34:34 PM #

Great post! Thanks for the information

us | Reply



4/28/2010 3:48:46 AM #

I\'m happy I found this blog, I couldnt discover any info on this subject matter prior to. I also run a site and if you want to ever serious in a little bit of guest writing for me if possible feel free to let me know, i\'m always look for people to check out my site. Please stop by and leave a comment sometime!

Rapidshare | Reply



5/4/2010 9:38:05 PM #


First of all: Merry christmas to everyone and thanks for reading all this stuff, my page views increased a lot since I do this daily series.

I spend the last couple of hours trying to get Unit Testing on the engine level to work and I finally got now everything up and running.  This is really one of the greatest things ever in Game Development IMO! Normally I would spend a lot of time changing code to just test stuff or even write small test application only to check the behaviour and graphical output of effects, newly imported textures or models or new game features.

Rapidshare Search engine | Reply


Add comment




biuquote
  • Comment
  • Preview
Loading



Disclaimer: The opinions expressed in this blog are own personal opinions and do not represent the companies view.
© 2000-2011 exDream GmbH & MobileBits GmbH. All rights reserved. Legal/Impressum

Poll

Which platform should Soulcraft be released on next?











Show Results Poll Archive

Recent Games

Soulcraft

Fireburst

Jobs @ exDream

Calendar

<<  February 2012  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
2728291234
567891011