Editorial - July 2007

Issue 54 cover

When I started publishing the newsletter, my greatest fear was lack of content. This month the hardest job has been telling people that their news, articles and achievements will have to wait another month. The amount of quality work being produced with TGC products right now is phenomenal, and I can tell you that next month will have yet more high calibre commercial products to report about, some of which are quite literally out of this world. But right now, you can concentrate your efforts on delving into more X10 previews and videos, product updates, tutorials and resources. We also have news of a new 2D Plugin Kit for DarkBASIC Professional, and an exclusive Aiko comic strip from Xplosys.

As a student, I was highly uncultured and rebelled against the classical curriculum of English Literature. I passed, but that was due to the nurturing of my speed-reading skills and analysis of my teacher's subjective marking system. In spite of this, I recently found myself watching the 2006 film of George Orwell's classic novel, Animal Farm. It's an ingenious plot that explores the potential outcomes of starting a new utopianist society, using a humble farm as the setting, and the animals as the new society to overthrow the humans.

Animal FarmAs I watched the film, I saw a fantastic storyline unfold that any budding games-writer would be proud of. It contains so many elements seen in games today, with a plot that is not particularly original, but is extremely well orchestrated. It's something we could all study and use to our advantage. Take a real-life situation from history or the present day, and change the setting. Remove the characters and introduce a new race or extra-terrestrial population. Study the driving force behind the conflict and assimilate it with something more suited to your new environment. With a little effort, you have the framework in which to introduce your gameplay. Get writing, and good luck!

Until next time,

Steve Vink


(1) FPSC X10 (2) DBPro (3) FPSC News (4) DGDK (5) DGDK.net Tutorial (6) 2D Plugin (7) Ageia Compo (8) DBPro Fundamentals (9) Lee's Tip of the Month (10) PlayBasic (11) From the Forums (12) Winner (13) Outro

FPS Creator X10 Update


Sneak Peek Video

x10_July.jpgHave you wondered what FPSC X10 might look like with dozens of enemies, huge explosions throwing crates everywhere, shattering glass and ragdoll bodies falling around you? If so, wonder no more. The Game Creators have uploaded footage of the latest features to MSN Soapbox and YouTube for your perusal.

You can view the high quality version here on Soapbox (You'll need an MSN Live account), or the lower quality version here on YouTube.

Lee Bamber's X10 update

The focus this month has been on the speed of the engine, and the fluid performance of the games created. We performed extensive tests on all aspects of the engine, under as many conditions as the level editor would allow. We identified some key areas where speed could be increased, and bottlenecks widened.

One of the most common delays when using FPS Creator was the build-time, and the time it takes to construct, lightmap, load and populate the elements of the game. We determined that a good deal of level editing is simply moving dynamic entities around and changing properties, with the construction and lightmapping of the scene being a redundant re-processing of the same static data. This month we added what we called the 'universe construction skip', which compares the current build with the last build, and if the static parts of the scene have not been changed, it entirely skips this part of the build process and reuses the last scene. The performance gain is significant, turning a 2 minute build into a 20 second build! What's more, we have back-engineered this change into the current FPSC product.

The first major speed drain in the engine itself was the number of 3D sound effects being used when many characters were in play. The human ear simply cannot determine the complexity of this, and so we did not need to rely on so many unique 3D spot sounds. By creating a pool of fewer 3D sounds, and drawing from them only when needed based on the players location, a dramatic speed-up has been gained in this area.

Rendering, which was thought to be a significant draw on resources turned out to be quite reasonable compared to other areas of the engine. The raw speed of the new G8800 cards has not failed to impress, even after six months developing with them! We did find that instancing objects has a certain overhead, and the engine now automatically selects the fastest rendering mode based on the number of duplicate characters to render.

Keeping ragdoll characters lingering in the scene was also another cause for incremental performance drain. Being able to push corpses around is fun, but fifty of them vegetating all over the level created a terrible performance hit. The new approach moves the ragdoll until it comes to rest, and then bakes it into the scene, or fades it out after a number of seconds.

FPSC X10 screenshotAnother performance gain was achieved by replacing the ray casting code used by many of the characters, with a lighter faster version taken from our lightmapping technology. We also found ways to reduce the number of times we needed to call this function as well. For example, characters only need to perform a ground check if they encounter a vertical obstruction such as a ramp or staircase. The new AI system keeps characters on the regular floors, and the old ray casting requirements had become redundant.

As is common in development, a success in part one can often become at a cost in part two. The new AI system relied on the creation of obstacles, and for very large complex levels the AI had to traverse hundreds of obstacles, causing a brand new speed drain. We found a way to generate far fewer obstacles, streamlining the AI. We are currently looking at moving the entire AI work onto a separate CPU to gain even more speed on multi-core systems.

By far the most important speed work has been with the concept of a 50 character battle in a confined area of the level. This was our benchmark for X10, and one that we take seriously. If we can place the player in the firing line of 50 armed nasties, and allow a close quarter's battle to ensue, without loss of gameplay performance, then we will have achieved our goal. Our current tests show that we are close, and the final stages of AI optimization will bring the game up to a comfortable 60fps.

DarkBASIC Professional Round-up

DarkBASIC Professional

This month, we have a varied selection of articles, from new commercial games to innovative solutions and designs. 


The Game Creator's website has always had a codebase; it's a place to put your nifty, shifty or downright-clever snippets that are worthy of sharing with the community. When it was first created, I don't believe anyone could have envisaged just how popular and well-stocked it would become.

Nicholas Thompson, regular contributor to the forums, has taken Codebase to the next level. Taking advantage of the functionality of Drupal, the new off-site version allows various methods of promoting, approving and supporting the code snippets. Tags allow the author to categorise the entries, other users can comment and suggest improvements or alternatives. Ratings are easily added, code is syntax-highlighted, and the search facilities are second to none.

If you are looking for that elusive solution to a problem, or have recently discovered some previously untapped functionality, then you would be well-advised to take a look at the Codebase. It can be found at http://codebase.dbp-site.com, and don't forget that the legacy of the original Codebase will live on, with it's volumes of archived contributions.

Vector Animado

Vector Animado is a Games Studio, based in Spain. They currently have three commercial titles developed and published for the Spanish market, all of which have very different target audiences. Read on to see just how innovative some of these products are.

Onae - The Adventures of Zoe 

OnaeOnae is a 3D game, set in a make-believe world that is discovered when a mine collapses and sends Zoe and her assistant robot BuBot tumbling into the chasm. What makes Onae different is the fact that it is designed to be played by sight-impaired users. using a fully-integrated 3D sound system, it's possible to travel through the game and understand the surroundings and tasks. The game is also fully narrated, telling the story of Zoe, his companion and the characters they meet. The game is completed by solving various puzzles and tasks in order to return to the surface.


Piopa is "like a turtle without shell, an enormous head but no tail, with big, clear eyes and tentacles that hang from his head like ponytails. And a sweet, very sweet stare"


Aimed at school children, this is a beautifully presented adventure, in which you must return to human form by completing many and varied tasks. But the game is also much more than just the non-violent, child-friendly production that it appears to be. It is in fact a psychology tool, aimed at identifying harrassment and bullying. By presenting various psychological tests in game format, the results of which are evident in the solutions to the tasks, the primary barrier of person-to-person discussions is removed.

This tool is created solely for qualified professionals, and used in controlled environments in the interests of the children involved.

Text Compo

Last year saw the first-ever Text Adventure Competition, organised by Matt Rock. This year it's happening all over again, this time with modified rules and multiple award categories. In this competition, you'll be tasked to create the best text adventure your brain can muster, and you'll be pitting it against other aspiring game designers who are vying for the same great prizes. Along the way, we're hoping your project will help you learn new things about writing great stories, and push you to develop your good ideas into fantastic ones.

Prizes are provided by TGC, Underware Design and also by Matt Rock on behalf of MISoft Studios:

In addition, there are Kudos prizes, the full details of which are in the dedicated forum thread. For each kudos award we hand out this year, there will be a copy of Eternal Equinox, and an extra copy of PlayBASIC for the technical design Kudos award.

For more information regarding the competition, the official thread can be found here: http://forum.thegamecreators.com/?m=forum_view&t=107727&b=19&p=0


TTD is the acronym standing for T.Ed to DarkBASIC Professional Exporter. The product does exactly what it says on the tin, taking the exported file from T.Ed and converting it to usable DB Pro code. As well as generating the terrain, it supports the following features:

Full details can be found on the Edge Graphics website.


Call Of The Dragon continues...

COTDThird place in the NVIDIA competition was a nicely styled game named Call Of The Dragon. It was described by the judges as "the most playable game in the whole competition". Dienye Boham contacted us this month to let us know that work continues on this title.

"We've made a whole lot of updates to the game since the competition," writes Dienye, "adding more special moves, refining the combat system, and tweaking the gameplay based on feedback to get it just right"

You can get the updated version and keep up with progress here on the forums.


 Galactic Catastrophes

Galactic Catastrophes, when I was first introduced to it, was somewhat understated. Once played, Galactic Catastrophes - Click for larger viewmy impressions were raised immensely. This title has all of the components you expect in the genre, controlling a clan of differently-skilled characters, gathering resources of different types, and fighting the enemy with various strengths and weaponry. It also has more than one would expect from even a Triple A publication. For example, there is a fully-fledged day/night cycle with limited vision, and a weather system which is rather keen on rain!

You can download the game from the Veron website - http://www.verongames.com/download_id=gcd1.html



Most of us have owned a Lego set at one point in our lives. If you haven't, have children just so blockcad.jpgthat you have an excuse to go buy some. Block Cad is a freeware product for making Lego-style models in a CAD environment. Paul Frischknecht has taken the concept several steps further, and integrated the output with DarkBASIC Professional and Dark Physics. The importer allows the predefined structures to be brought in to the game, and physics is automatically applied.

Preview VideoThere is a great demo video on Youtube of complex structures being razed to the ground - Click to view 

Paul is looking for help in fine-tuning the physics interactions, you join the discussion here on the forums.

Horror Music Pack

Horror PackDaz Dicks has recently released a Horror Music Pack, with the TGC Community in mind. It consists of 16 tracks for a single fee of £12. The tracks have been developed specifically for the hobbyist game maker, hence the matching price tag.

You can try before you buy, with a medley of samples (click here to listen). If you like what you hear, then the pack is available directly from Junkrock Records 

News from the World of FPS Creator

 FPS Creator News

FPSC Update 1.06

We have released a new update for FPS Creator called V106, which you can find on the update download page on the FPSC website. Below is a summary of the fixes, and thanks goes out to the members of the community who helped us test it.

FPSC Video Tutorials - Update

In June we brought you dozens of FPSC video tutorials. These cover every aspect of the development of a game, from the absolute basics through to advanced scripting, lighting and effects. The same suite of videos have been uploaded to YouTube for more convenient access. The links are available alongside the original Soapbox versions - //www.thegamecreators.com/?m=view_product&id=2001&page=VideoTutorials

Model Pack 7

Model Pack 7FPS Creator Model Pack 7 is now available to pre-order! This pack contains 109 new assets for your games.

Expand the default sci-fi and world war II libraries with this segment pack. After installation you have extra mesh segments available that provide exciting new possibilities. Create broken walkways, curved ledges, varying angled ramps - your level designs expand with this new set of building blocks.

The new segments are all available in "concrete", "Hollow", "Ice", "Iron", "Metal", "Moon Floor", "Carpet", "Grass", "Lava", "Marble", "Stone" and "Wood" designs.

Angled walls can also be created using the new "Diagonal" wall overlays, available in all the standard default room styles. "Sloped" walls give you more options in your level design.

Model Pack 7 contains 109 new segment pieces and all for a very low price. Enhance your levels and make them stand out from the rest!

Model Pack 7 for FPS Creator will be released by July 8th 2007 and is available to pre-order now.

FPSC Hints & Tips

Andy Nicholas (NickyDude) has compiled the best of the FPSC forums and created a downloadable PDF guidebook. The guide started as a simple collection of answered questions like "How do I stop the weapons / ammo from floating", and made up a simple reference text file.

FPSC Tips"As I asked for assistance, and gathered more and more questions I thought other people could benefit from this 'text file'", explains Andy. "This was a great success and encouraged me to continue it with a better design, while more and more people allowed me to add their tutorials. It has now got to the point where I'll ask someone if I can include their tutorial in the guide and they're like 'Wow! I'm gonna be in the guide? I didn't think my stuff was good enough', and that's something I never expected!"

"I'd like to take this opportunity to thank all members of the FPSC forum for their help, guidance and support to keep the guide going and who knows, there could be a FPSC Hints and Tips Guide for FPSC x10 in the foreseeable future!"

Publication of Version 7 of the guide is set to be be released today. You can download it here - http://www.madladdesigns.co.uk/fpsc/fpschintsntips.pdf


Klan Warfare

The FPSC Multiplayer Club is up and running, and scheduling the first round of hosted games. Not only can you take advantage of the club to team up with other FPSC users, but you can also influence the maps being played. The forums are open to vote for your favourite scenarios.

The club is hosted at http://www.klanwarfare.com/. You can also join the TGC Forum chat



Anderson & the Legacy of Cthulhu is a playable Horror Novel containing shooter and adventure elements. It takes the Protagonist Robert D. Anderson, last descendant of a Count's dynasty, from New York to Germany around 1940, where he finds himself in the middle of the impending World War. Following his obscure and dire family history, he discovers a huge underground system of cages and caverns beneath his ancestors' castle. There the legendary "Order of the black sun" jeopardises life as it exists with dark blasphemous rituals.

Created using FPS Creator, the game has been ingenioulsy scripted to ensure the feel is of an adventure game rather than a shooter. So standard scripts for opening doors, for example, are combined with the players current inventory as in any other adventure game, requiring keys and the correct objects to progress.

To understand the scale of this publication, it's important to realise the number of people involved. Aside from the core team of 6 developers, there was a 12-strong film production team and up to 20 more hired hands as and when they were required. The entire production evolved through a 9 month project. For anyone playing the game and feeling like they already have an affinity with Anderson, the voiceover is in fact the same actor who brought Max Payne to life.

Click to see larger view  Click to see larger view  Click to see larger view  Click to see larger view  

The commercial release of  Anderson & the Legacy of Cthulhu is imminent.

Aiko in Action

Everybody knows Aiko. She's been around since the beginning of FPSC. Now you can see just how she got to the position she's in today, thanks to Brian Lizotte (Xploysys).

Aiko Cartoon

If you like this, you'll want to read the rest of Brian's work in the forums, take a look at the From the Forums section later in the newsletter.

DGDK Highlights


DarkGDK is a great addition to any professional developers tool set. See here how one developer used it to recreate the game of his child hood in only 3 months!

Lionheart Remake by Byron 3D Games Studio


2D side scrollers have been a popular format for many years, and have a certain appeal to them. Pierre-Alexandre is a childhood fan of the genre, and has taken his loyalty to this genre to the point of remaking the first game he ever played at the age of five. Using Dark GDK and C++, this has developed into a fully-fledged game with 9 full levels. It has been 3 months in development and is now available to download as freeware.

LionheartLionheart is everything you'd expect, and this rendition is faithful to the original. It includes collectibles, power-ups, enemies, obstacles, and of course the inevitable boss characters at the end of each level. The attention to detail is worthy of mention, and it is nicely finished with a fantastic soundtrack.


You can discover more about the game and it's development, along with downloads, screenshots and videos at the Byron 3D Game Studio website

Getting started with DarkGDK.net

Thiago Bessa is the creator of LightEngine, a full OOP DarkGDK.NET plugin. This month he introduces us to the basics of DarkGDK.net with the use of a simple bouncing ball program.

For those who don't know about DGDK.NET, it is a complete product based on the powerful DarkBasic Professional engine (just as DarkGDK), but it enables the use of the engine on the powerful .NET Framework. It's the power of the DBPro engine with the full OOP of .NET Languages.

In this first tutorial we will create a "bouncing ball". It is a very simple example so anyone with the minimum knowledge can understand it. So let's get started.

  Download the project

The first thing to be done is to create a new project in your language of choice (VB.NET or C#, we will be using VB.NET in this tutorial) and authenticate it. This process is fully explained in the documentation that comes with DGDK.NET.

Now we will start using some DGDK.NET commands. If we're going to have a bouncing ball, we should create it first. Our ball will be the object number 1 in our code. Write the following command just after InitDarkGDK("")

'Creates a Sphere object with a radius of 2
oDB3D.MakeObjectSphereB(1, 2) 

Our ball is created. But before we compile the program we need to add a new command in the main loop. Write this:

'Syncs everything and refresh the screen

The Sync command will handle the screen refreshing and it is considered mandatory in any DGDK.NET main loop. Don't forget it!

You can now run the program and see the ball we've created. It looks a little bit large at the moment. Instead of making it smaller, we will move the camera farther away. We do it with this command:

'Moves the camera away from the initial position

Run the program again. Now the ball is smaller, but it's still static. Some movement please!

Let's create two variables of type Single to store the amount of movement in each direction. We will add them to the code and initialize them with a positive move of 0.5.  Put these before the sphere creation command.

'Variables for the amount of movement
Dim ballMoveX As Single = 0.5
Dim ballMoveY As Single = 0.5

The movement will be achieved with two commands, one to move the ball horizontally and other vertically. These should be inserted at the beginning of the main loop, before oDBCore.Sync(). Here they are:

'Move the ball horizontally, with the amount in the variable
oDB3D.MoveObjectRight(1, ballMoveX)
'Move the ball vertically, with the ammount in the variable
oDB3D.MoveObjectUp(1, ballMoveY)

We could use only one command, oDB3D.Position(x,y,z), but I've used these two for simplicity. With Position we would have to calculate it's new location by getting the current position and adding the amount of movement. It would be the best choice for three dimensional movement, but as we're only going to move it in two axes, let's keep the code easy to understand.

Both commands specify a direction (Up and Right), but it doesn't mean it can only be used for that direction. What these commands do is move it along the axes, and axes have both negative and positive values. If we call MoveObjectRight with a negative value, it will move "Right in the opposite direction"; that means it will move to the Left. With MoveObjectUp, we can achieve the same thing.

With only these commands we have a ball that moves, but don't run it yet! We should insert some "bouncing code". What we should also do is make sure the ball doesn't get out of the screen, it should bounce as soon as it touches the limits of the window. But how do we know where the ball is on the screen? DGDK.NET provides two convenient functions that give the current object position on the screen: ObjectScreenX and ObjectScreenY.

Let's move on to our conditions. The ball Screen X position should not be less then 0 (where the window starts) and more than the window width (640 for the default window). If one of these conditions are met, we should change the direction of the ball. That can be accomplished by multiplying the value of movement by -1 to reverse the direction. Also, we should check if the ball is still going in that direction before changing it, or it could change direction again before it comes back. Here's the code:

'Checks if the ball is within the limits of the screen width
'Also check if ball is still going in that direction before changing the direction
If ((oDB3D.ObjectScreenX(1) <= 5 And ballMoveX < 0) Or _
(oDB3D.ObjectScreenX(1) >= 635 And ballMoveX > 0)) Then
   ballMoveX *= -1
End If 

As you can see, I've changed the minimum from 0 to 5 and maximum from 640 to 635, that's because of the size of the ball. We'll do the same things for the axis Y, only with updated values:

'Checks if the ball is within the limits of the screen height

'Also check if ball is still going in that direction before changing the direction

If ((oDB3D.ObjectScreenY(1) <= 5 And ballMoveY > 0) Or _
(oDB3D.ObjectScreenY(1) >= 475 And ballMoveY < 0)) Then
   ballMoveY *= -1
End If 

Run the program now. Voilá! The ball moves and bounces on the edges of the window, just as we planned. I recommend downloading the project at the start of this article, it comes with two versions of the code: one using DGDK.NET, as the code in here, and another using LightEngine (which makes things easier). Both come in C# and VB.NET versions.

Happy coding!
Thiago Bessa

For further help with this (or other things) you can find Thiago on the DarkGDK forum or on the official DGDK.NET IRC channel: #dgdk-net @ jd.devhat.com. He's happy to help with whatever he can.


The Odyssey-Creators 2D Plugin Kit


Last month we announced X-Quad Editor and PurePLUGIN from Odyssey Creators, 2 new products that have been added to the range of developer tools available from The Game Creators. This month we can announce the impending release of another impressive addition from the same source.

2D Plugin Kit

2D Plugin KIT is a DarkBASIC Professional plugin which adds more than 160 new commands entirely dedicated to 2D games development. The features are divided into four distinct areas; 2D Tiles, Layers, Lighting and Particles.


2D tiles are small graphics that can be pasted like any other image in DarkBASIC Professional.
The tile system, however, is designed to work in conjunction with the layers system. Each tile can be comprised of up to 3 images. The first image is the graphic itself. The second is a Black/White mask that is used for Sprite and Layer collisions, as well as shadow casting. The last image is a standard normal mapping (DOT3) image that can be used in conjunction with Virtual 2D lights to create more impressive and realistic lighting effects.


2D LayersLayers are tile planes that can be added to create multiple layer maps. This is more commonly known as Differential Scrolling, or Parallax Scrolling. This enables the creation of many layers, each with specific content to produce a very different final result. The plugin handles the scrolling, all you have to do is define which area from the main layer you want to display. Moreover, 2D Plugin KIT builds its own fast and perfect collision system reading directly from the tile images (graphic, mask and normal mapping images).


To produce more impressive results, the system integrates virtual lighting effects. Lights can be applied to any of the layers you create. The layer incorporates the lighting data to produce the desired effect. Four modes are availables for Virtual Lights.

All lighting effects are pre-calculated to give optimal frame rates when scrolling ingame.


2D ParticlesA primitive particles system dedicated to 2D environments is included in the functionality of this plugin. All sorts of effects are possible, including flames, fireballs, snow, rain, sparkles and starfields. Again, they are linked to layers and positioned accordingly. You can also use your own images to create custom linear particles for your games.


To show you what the system can do, Odyssey-Creators have set up a small shoot-em-up game using 5 layers, fake 2D lights, particles and custom Sprites Vs Playfield collision. This game demonstration can be downloaded from here. Full source code for the game is provided with the plugin.

Full details of the product release will be available soon.

Ageia Competition

Dark Physics

In recognition of the fine work and support developers have given to Ageia, they are sponsoring a contest to determine what creative, interesting, world changing applications and games are being developed using either the Ageia SDK or the SDK and hardware support with a PPU card. Naturally, this includes projects built using Dark Physics.

There are many exciting and potentially revolutionary applications and games being developed that they would like to comprehend more fully. To that end, Ageia is sponsoring a contest for the hottest, most imaginative, and creative business or science focused applications or games! To enter the contest, you simply have to to tell them how you are using the product in a short (1-page or less) essay.

Prizes and Rules

In return, they will award 3 prizes: $1000, $750, and $500 for the top three responses that Ageia deems really rocks the world! In addition, the first 250 entries will be entered into a pool from which a winner will be selected and will win a $500 prize.

Contest rules are simple. Entries must be received via email no later than July 30, 2007. Please use the following formats - Text or HTML email, Demo with written description, PowerPoint, MS Word, or PDF). Be sure to let them know how you are using the technology; what is unique about the game/application; and what the customer benefits are.

The address for your entry is SDK_Manager@ageia.com. Ageia will notify winners by email and post the results on the Ageia website by August 15, 2007.


DarkBASIC Professional Fundamentals

DBPro Fundamentals

As promised last month , this next installment of the fundamentals series deals with rotation. It's one of the main stumbling blocks of new programmers, and is worth looking at slowly and with great care.


Fundamentals Tutorial 7 - Rotation

Object rotation can be performed in different ways. It is important to understand the differences, as each method will have a major impact on your object orientation.

In this tutorial, the more complex commands will be covered first. This is simply because they provide a fuller explanation of how rotation works. This area is one of the more challenging, and so it is important to cover it in depth.

The first command to look at is that which rotates an object on all three axes simultaneously:

ROTATE OBJECT 1, 45,90,60

In this example, the command will rotate the object 45 degrees in the X axis, 90 degrees in the Y axis, and 60 degrees in the Z axis. The first important point to realise is this: in reality, each rotation takes place in turn. That is, the X rotation happens first, followed by the Y rotation and finally the Z rotation. The second important point is that the rotations are based on World Coordinates. An object has it's own coordinates, which change as the object rotates. But the World Coordinates remain static.

There are three further commands that isolate each axis, and allow the object to be rotated in one direction only. The example above can be written as three separate commands:


Again these are World Coordinates.

Rotating on one Axis

  Run the code! (Download the Project Files)

The first rotation example displays 3 objects rotating on just one axis each. Look at each cube, and see how X, Y and Z rotation affects them. You can imagine the axis as a spike stuck through the cube, and it is on this spike that it rotates. So the Y axis is a vertical spike, and the cube rotates around it, keeping it's base facing the floor. The Z axis "spike", which follows the axis into the distance, rotates the object rather like a clock hand.

Rotating on multiple Axes

Rotating on just one axis is very simple, as we have seen. Using the ROTATE OBJECT command, we can rotate on all 3 axes, and this is where caution must be exercised. As mentioned earlier, each rotation occurs in turn, on the World Axes. By default, the order is X, Y and then Z. Lets turn an object 90 degrees on each axis and see the result.

  Run the code!

In this second example, one object is rotated firstly on the X axis. Despite the object now lying on it's front, the second rotation still occurs around the World Y axis. And the third rotation happens around what we recognise as the static, World Z axis. Now let's see what happens if we rotate the object in a different order.

Try It: Modify the program so that the cube turns firstly in the Z axis, followed by the Y axis and finally the X axis. Here is the first of the three sections:

X# = 0
   INC X#, 0.05
UNTIL X# >= 90
UNTIL INKEY$() > "" 

Identify each section and use the Windows Cut and Paste functionality to reverse the order. Now compile and run the code again. Watch the object very carefully, and remember the order you have specified is Z, Y and then X.

You should have noticed that the direction of rotation is not what you might have expected. Recall that we stated earlier that rotations occur in the order X, Y, Z. Every time we update the object's orientation, the program actually resets it to 0,0,0 and then reapplies all 3 axes rotations. So in the final stage of our program, the Z and Y applications are applied after the X rotation! If you take a dice and perform these calculations in order manually, you will get the same end result, as long as you perform the rotations in order.

Turning, Pitching and Rolling

Working on individual objects in relation to World Coordinates can be confusing. There are also commands that work on local axes, and remove the need to perform complex calculations to orient the object:


Turning occurs on the Y axis. It is what you do when you walk down the street and turn a corner. If you were skiing down a steep hill, TURN OBJECT LEFT would keep you firmly rooted on the ground, and turn you on your own Y axis.

Pitching occurs on the X Axis. Pitching is what aircraft do to climb higher or lower their altitude, lifting or dropping the nose of the craft. The craft can be flying North, South, East or West and pitching would still raise and lower the nose, using it's own local coordinates.

Rolling occurs on the Z-Axis. Again, aircraft use this term to describe the lowering of one wing and the raising of the other. Rolling can occur at the same time as pitching, without one action affecting the angle of the other.

  Run the code!

Compile and run the third example. This is similar to the second example, but using the newly introduced Turn, Roll and Pitch commands. You can see that the rotations now occur on the object's own axes.

Try It: Change the amount of rotation from 45 degrees to something much higher or lower. You will see that no matter how far you turn the objects, the next rotation will not be affected by it's predecessor. It will still occur on the object's local axis.

Try It: The real test of this new concept is to reverse the order of the rotations. Using the new commands, the end result will be identical no matter which order we apply them in. Just as we changed the order of the blocks in example 2, apply the same cut and paste process to this source code too, and view the results.

There is one other significant difference between the 2 methods. When using the basic rotation commands, you explicitly specify the angle. An angle of 90 degrees on the Y axis is always the same direction. Consequently, we had to increment the angle each time in the example to reach the final angle we required. When Turning, Pitching and Rolling, the new angle is always relative to the current angle. In this third example, we kept applying the same increment each time to achieve the same result.

One final note on the topic of rotation is required. The order of basic rotations can be reversed using the following command:


Once applied, the rotations will be carried out in the order implied by the command.

It is advisable to experiment with the different types of rotation, in order to understand them better. Good luck, and happy coding!


Lee's Tip of the Month - Time saving FPS Creator advice

Lee Bamber Conehead!

I was running an example of FPS Creator, showing off some new segments. After a brief level editing session I found myself with a room full of entities I had to delete. To the surprise of my audience I selected the entities and deleted them with a single key press. If you are still deleting your entities one at a time, there is a way to get the job done a little quicker, allowing you to spend more time creating than destroying. Follow this process to see just how easy it is.

This trick only works if you only want to retain the basic segments. Segment overlays and entities cannot be restored in this way. Practise this with some sample levels before applying the technique to your current level designs. You may find your productivity increasing quite a bit!

PlayBasic News


PlayBasic - Round Up

by Kevin Picone

Programming is a lot like catching the flu sometimes; one day everything is moving forward nicely. Then the next moment, you're laid up in bed simulating a snot sprinkler, which sort of describes how things have been progressing the last couple of months. One moment we're blazing forward with PlaybasicV1.70 development then the next we're buried under a pile of catch-up tasks. As such, this month we've been focusing upon addressing some issues in the Demo & Retail updates, plus giving the FAQ's and documentation a good seeing to also.

Documentation Revision #7

Over the past few weeks we've been investing time improving the documentation and the building software. One of the key improvements to the builder - apart from updating the syntax highlighter - has been the addition of cross-linking support, which now allows keywords in command descriptions to be cross-linked. It's funny how such a simple addition makes browsing the help much more intuitive for the reader. Updating building software was the easy part, the time consuming element has been manually sifting through, re-writing, updating and linking all 1179 pages of documentation. The result is certainly worth it however. 

Live Updates In Your IDE

PlayBasic is updated frequently, and it's not uncommon for users to miss revisions between visits to our maintenance forum. To combat this, we're in the process of testing a live news/update awareness addition for the next IDE. From the user perspective it couldn't be simpler; each time you use the IDE, the editor will query UnderwareDesign.com for News/Update headline information directly. New updates (Compiler, IDE, Help, Libraries etc) can then be downloaded directly to your PC. The updater doesn't force you to install them, it just helps you stay in the loop.

PlayBasic V1.62b Demo Updated

Two months ago we re-released a demo of PlayBasic V1.62 with an extended 120 trial period. Unfortunately post-release a few hiccups were discovered. So this package has been reissued including the new documentation and should be available on our site to download by the time you read this.

PlayBasic V1.63g Retail Update

Not to be confused by the version numbers, we've also re-released the retail update of 1.63. This update addresses various key bugs discovered relating to the VM2 replacement file system, string and memory manager. The full announcement and details are available here on the TGC forums.

Competition In Progress - Ballistic Blasters

As announced in April, the Ballistic Blasters competition is still underway and runs until the deadline of July 30th, 2007. Full details, rules and game specification are available on the competition web page 

Over & Out!

From the Forums

The forums are thriving, here are some of the highlights...

Goga's HTTP Server and Downloader

Two new plugins from Sergey K allow you to set up a HTTP server, and to implement HTTP downloads in-game, with no game lock-up. There is also information in the thread on how to use the plugins in your DB Pro code

New FPSC X10 board

This board has been introduced specifically for talking (and asking questions) about FPS Creator X10. Some of the X10 related threads from other boards will be transferred into this new area, so don't be surprised if your thread vanishes.


FPSC Cartoons

As showcased earlier in the newsletter, Xplosys has created some rather witty cartoons based on FPSC and some of it's 'quirks'. You can view the rest of these in this thread, which Rick Vanner (FD) professes to find quite amusing.

Making DBP Plugins with Dev-C++

This is a detailed walkthrough of plugin creation using Dev-C++, the free compiler for C++. There's plenty of pictures to get the points across, and advice on every aspect you might come across.


This months Winner

Each month we pluck one lucky subscriber from the newsletter mailing list and award them a free copy of DarkBASIC Professional. The email address of this months winner is: bobgc@?????.go-plus.net  If this is you then send us an email to claim your prize.


Share your news with over 14,000 active games developers!

If you have something you'd like featured in a future issue then please get in touch and include as much information as possible (including where applicable: screen shots, URLs and zip files).
Issue 55 deadline - July 27th.