July 31, 2012

You've got to be skidding

Well here we are again to look at some of the latest progress in SuperTuxKart development. Without further ado, let's get on with the news.

Nolok doing a Gnunapping
Some more work on the first story cutscene has been made, especially fixing problems related to the camera and adding Nolok's spaceship, abducting Gnu. Also added is the capacity to show subtitles in cutscenes, and animated sound effects and particle emissions. Still to be done is getting a couple vocal effects and tweaking a couple things related to the animation.

Stephen has done a few nice changes to stkaddons.net, most of which are not immediately obvious to users. But among other things: direct URLs to individual addons now looks nicer, and a management panel for moderators and admins has been added. Older revisions will now be automatically deleted after a while with the exception of the newest one (obviously), or if it is the last supported one for a specific STK version, so it will never delete critical revisions of an add-on.

Debug view of skidding AI
In other news, the AI (artificial intelligence, or otherwise known as "computer player" in some games) has been improved to determine if it can use skidding or if it needs to brake during a turn in order to follow the drivelines. Pretty nifty, and makes it look quite a bit smarter (with the exception of some tracks, where it has problems due to losing ground contact due to elevation). It still needs a few tweaks, and is therefore not enabled by default yet. So whenever the AI gets the ability to seek out nitro and item boxes by themselves, I predict people may have to get better at driving smart and use the new skidding bonus to keep up. Of course, AI will be AI and most likely will have a few weaknesses still, and will also depend on the difficulty chosen, so I doubt we'll get an AI which is nearly impossible for humans to follow. So any improvement to the AI is a good improvement, and this is most certainly a good start.

Another nice addition to the game is the ability for it to save the current window position, so if you restart the game and it's in windowed mode it will start where you left its window last. This sounds superfluous, but for multi-monitor setups this means you can have it always start in one screen while you have other stuff on the other screen, without having to move it there manually every time.
We also received a few patches from nathanm32292394 (phew) fixing a few memory leaks and improving support for graphics drivers that don't support non-square and/or texture sizes which aren't power-of-two.

I think that's about it; if you think I've missed anything just yell, and also if there's other things I could do in order to make the blog better. See you next time, and until then: goodnight out there, WHATever you are!

June 27, 2012

STK Can Haz Community?

Hi y'all! Short time no see. I just thought it would be nice to bring attention to our forums and IRC channel, where a lot of the discussions about SuperTuxKart are going on. The forums now have over 10 000 posts spread across over 700 topics, which goes to show they are fairly active. The developers take an active part in discussions, so if you want to become involved or just come with constructive suggestions the forums are perfect for this. Recently one of our community members started a leaderboard topic where people can post their Time Trial times along with screenshot or video proof. So if you want to have some competition, that would be a nice way to do it while we wait for networking support to come within a few SuperTuxKart releases.

Okay, you may think, there are developers on that forum whom I don't identify with due to not being a programmer myself, and there are the other users who probably just fool around with leaderboards (they can do so much more than that! True story). What if I don't care for highscores, and I can't program or do 3D modeling and thus contribute to the game and by extension the community? Whatever should I join the forum for? I'm glad you asked.

There are actually quite a few things most people could give a shot and contribute to STK in a meaningful way. The new story mode will feature voice acting for its cutscenes, and possibly all standard karts in races may get some cheers and boo samples, depending on the amount of contributions. Now beware: voice acting is not as easy as some may believe, and is primarily about acting, so keep in mind that we want the end result to be good. Bad voice acting could potentially make the game seem less polished, and we don't want that and as such we can't accept everything. But this could be an interesting way for people to contribute, especially for actors, comedians, singers, or anybody with some degree of live performance experience. You don't have to have such experience or come with any sort of resume though; just try recording some lines/noises with the best available microphone you have at your disposal and upload it to the forum. Maybe this sounds intimidating, but just give it a try! Remember: even though you might not be the next Mel Blanc or June Foray, your contributions could very well be good enough for this game.

Maybe the above isn't your thing, but you still want to help out. The story mode will also feature an overworld where you can complete challenges in the difficulty of your choice. Perhaps one challenge is too hard for you, and you really don't want to spend too much time on it. Then you can just choose to drive that particular challenge with medium or easy difficulty, and otherwise settle for driving in 'Hard'. Previously, there was just one difficulty for the challenges. Either you made it, or you didn't. Now, with the new system, there is a high demand for people to playtest and tweak challenges on each difficulty level so we get reasonable results, allowing both new and experienced players to have fun with unlocking features. If you would be interested in this, please register on our forum and engage in discussions and upload suggestions for challenge requirements. This would be a huge help and possibly make version 0.8 both more polished and released more quickly.


Still don't find anything you fancy? Why not take a look at our forums, read through a few topics and see if you find anything you feel strongly enough about to register and poke fun at our bad suggestions, faulty logic and otherwise mesmerizing bad writing skills (which this blog post is a stellar example of)? Er, maybe you could skip that. As long as people keep things constructive, anyone can join in on the fun! :)

June 22, 2012

The plot thickens

It's been a while. Way too long actually. But instead of coming with my usual lame excuses on the silence, I'll just get on with it. There's been a heap of interesting stuff to watch, not the least a few which will need some more time to reach its full potential. So the 0.8 release is still a way off, though hopefully we will have a release out before the year is over.

New version of XR591
As usual, we'll start with the more visual changes. Behold the new version of XR591 by our regular track guru samuncle. If you think it looks pretty much the same, that's correct; it will mainly be less resource-hungry and with a few other changes here and there. It's still a work in progress, but it will hopefully be ready to roll out alongside the 0.8 release.
 
Other tracks have been updated to support driving them in reverse, thanks to various community members, and Wardje (Ward Muylaert) has added support for driving Grand Prix tournaments in reverse as well. He also added the option to give up a normal and Time Trial races, but still get an estimated time with penalty time added. You will always end up last, but at least get a result. And now penalty time is only given if you accelerate while "Set" is shown, so any accidental acceleration during "Ready" will not penalize you.

Intro animation for story mode
When it comes to the story mode, work has been started on animating the intro cutscene. Indeed, the plot thickens! There is still quite a lot more to be done when it comes to cutscenes, but to drum up excitement I thought I'd post this screenshot. If there are any animation experts out there willing to help, please contact us - this would free up a lot of time for Auria that would go into making the game better in other ways.

A cannon-like teleporter has been in the works as well, where the goal is that a track designer may place a special object in a track, and karts when they reach that point will fly to the end point without any user interaction. This is also a work in progress, and may or may not be ready in time for 0.8.
Speaking of teleportation, I thought I'd quickly mention that in the Overworld you can now click on the map and you'll get teleported nearby that challenge orb. That'll save some driving back and forth.

More WIP work: demo mode, where after a certain amount of idle time AI will start to race, like you often see for games in real arcade machines. When this will be ready to be used as a default is left to be seen.
Also, there's been quite a bit of AI work done lately, with efforts to both bring the AI up to speed when it comes to the new skidding behavior, and also to make it more intelligent and avoid bad things while collecting good things. The latter part has been started by a new contributor, JskiJ, which we hope will help us further with giving the AI a much needed intelligence boost.

In other news, SuperTuxKart now has a default resolution of 1024x768 unless your screen is too small. Then it will revert back to 800x600. This decision was made due to the increasing challenge of keeping the interface small enough to fit 800x600 pixels, and also since most computers have screens capable of at least 1024x768.
Meanwhile, the game now supports Arabic, which will hopefully make the game more accessible to many people.

There's been a few other miscellaneous changes as well, but unless I am mistaken I've listed the highlights since last regular development update. Take care and as always, we welcome contributions both on a one-off and on a regular basis. :)

April 27, 2012

Using Blender as a 3d map editor, rather than programming your own from scratch

From Blender to the game: a significant step


One issue that needs to be solved during game development is how to get the art from the modeling tool into the game.
The answer might seem to be trivial: "Just export the model in a file format that can be read by the graphics engine!" Unfortunately this is not as simple, even when both the modeling software and your graphics engine support the same file format.

Content, content, metadata

Many non-graphical pieces of information (metadata) need to be provided. In our racing game SuperTuxKart (STK) for example, map models need further detail:
  • Kart starting positions.
  • Mesh of the driveway.
  • Position of items boxes (powerups) and bananas (traps).
  • Type of track (arena or racing).
  • Name of the map designer.
  • Can the map be driven in reverse?
  • What music should be played?
  • How to handle animated objects?
  • What graphical effects (particles, animated textures, snow) and what sounds should be used and where?
  • Optimizations like backface culling.

Re-inventing the wheel... not!

Usualy, the answer to these questions is to create a separate editor which allows 3D modeling and exports the additional data necessary to actually use a level or object (or kart) in the game.
Creating and maintaining such a piece of content pipleline requires resources and can slow down or even halt other development, depending on the team size. With the three free-time programmers on our team, we couldn't afford this investment.
A track editor has been developed by a community member years ago, but it was never even close to being able to design track of sufficient quality and eventually was abandoned. Instead of restarting such an effort, we chose a slightly different approach.

Extending the modelling tool

We extended the existing modeling tool commonly used for creating tracks: Blender (a tool used for example by the renowned indie game creators Wolfire), so that the necessary options can be set in Blender's GUI. Our scripts for exporting tracks and karts make these options available in game.
This method reduces development time and allowed a tool, that is already known to many artists out there and has tons of documentation available, to create content that is perfectly fit four our game. We only need to document our specific extensions.

SuperTuxKart map and extended panels in Blender


The magic behind the scene that makes it possible to take a map in Blender and run it in SuperTuxKart is made up by several Python plugins. The first plugin, which can be seen in the screenshot, is the “Panel” plugin. Once this plugin is added to Blender, a few game-specific panels appear in the properties view (one for object properties, one for scene properties, one for material properties).
With a few clicks in the properties panel, you can change the sky, make it snow or rain, add fog, make a water surface animated or specify that particles or sound effects are emitted from a point!
Models
There is first the track export script, which reads these properties and exports them to XML files for the game core to read (which includes support for moving/animated objects). The “B3D” script also exports the mesh to the B3D file format (which also supports skeletal animation, as well as vertex colors and multiple UV maps for lightmaps and normal maps).
None of this would have been possible had Blender not been so scriptable. Our panel script can serve as example documentation for anyone who wants to make a custom Blender panel. The scripts actually load the description of the contents of the panel from declarative XML files, making it easy to change the contents of the panel. Interested? All of our scripts are open-source and available for both private and commercial use under the GNU GPL license.
Materials
The materials panel automatically lists all textures in the blend file, and allows specifying several properties, for example:
  • Surface properties, when player is in contact with it:
    • Is a particle or sound effect emitted?
    • Does it slow down or speed up the player or have a non-standard tire grip?
    • Do players pass right through it?
  • Viewable texture properties
    • Transparency/opaque value
    • Transparency effect (Alpha Testing, Alpha To Coverage or Alpha Blending)
    • Shaders (for example normal maps, splatting, water reflections, lightmaps, sphere mapping)
Powerups and traps (goodies and baddies)
It's nice to have the static model, but after all this is a game so we need to give the player some goodies and baddies! Fortunately there is an easy way to add them : our plugins extend the global "Add" menu of blender with new object types specific to SuperTuxKart, like gift boxes, nitro or bananas.
Drivelines and checklines
Finally, how does the AI know where to drive, and how do we check that human players do not cheat? We chose to use a set of simple meshes, called drivelines, to indicate where players may drive.

Driveline mesh in Blender


These simple meshes are then processed by the exporter into something that is easy to import in the game and to follow by AIs. Checklines are added in addition to that to prevent cheating.
As a bonus, drivelines do not need to be linear, but may be exported as a graph, allowing for quite complex structures to be constructed directly inside Blender.

Conclusion

While the Python API documentation is not always optimal, and while a few API changes broke everything and made us swear loudly in the past, Blender's Python API is very flexible and powerful and a vital part of our game development workflow, which will hopefully inspire others to design their tools with it.

Always on the lookout for content creators

We are always looking for modellers to help us improve our older, less impressive worlds. :) If you have experience in modelling and you feel like helping, you will be warmly welcomed on our forum, mailing list and IRC channel!
Further details of our map-making process can be found in the Track Maker's Guide.
This post was written as a collaborative effort by Arthur, Auria, hiker and qubodup.

April 1, 2012

[April's Fools Joke] New version numbering scheme

The SuperTuxKart development team has decided to change version numbering to keep up with the times and make it easier for people to know if they are using the latest version or not. So the upcoming 0.8 release will not be named 0.8. Inspired by Mozilla, we'll simply call it 8. But inspiration comes seldom alone, so since Ubuntu's version scheme makes it easy to know when the latest release got out, we'll adopt it as well and call it 8 followed by year and month. So for example 8.12.08. Then it dawned upon us: why not include revision number? Then there will be no doubt as to what version you're using, especially if we release a newer version in the same month. So the upcoming version will be named something like 8.12.08.13337. You get to choose what number you want to refer; either you say you're using version 8, 12.08 or 13337, or you might choose any combination of two or more of those.

We also like the idea of giving names to releases. So next version will be nicknamed SuperTuxKart Gutsy Gnu, or maybe Nasty Nolok or Silly Suzanne, we're not sure yet

We look forward to the release of version 8.12.something.something, and hope you'll find it easier to get the right version number when reporting bugs or otherwise talking about the game.