1. Computing

Empire Tutorial Six Published

By February 2, 2013

Follow me on:

Empire Screenshot

This time, in the Empire tutorial I've included SDL_draw a 3rd party library for drawing shapes, e.g. rectangles with curved corners (unused yet but it will be) and others, as well as a splash screen and general bitmap drawing control and started reorganizing for starting the game.

Full source code provided as usual as well as a binaries with all the graphics etc in so it should run. There's an interesting bug in debug mode. This is probably related to the code that loads the map from the text file. That well go away next time when I integrate the map generator in and no longer use text files for saving the map from the generator then reload it.

The bug relates to the globally defined struct sdllabel * nplabel; variable in empire.c. This has a valid value when initialized in the startpanel() function but when accessed in setplayers(), it has been completely changed.

Comments
Comments are closed for this post.
Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

©2014 About.com. All rights reserved.