This week I have fixed a lot of bugs and added optimisation some of the map were almost the same so I have decided to merge them. I have also tested SDL 2.03 and done a benchmark SDL2 / SFML2.
I have chosen SFML because when the project begins SDL2 was not yet stable and SDL1.2 was very old with his software rendering. So I have kept working with SFML but now it’s different, SDL2 is stable and all major bugs are fixed, and SDL is supported by most platforms including IOS / Android. So in the long run SDL will be more optimised than SFML there is no doubt. I prefer C++ but a C library is not really a problem, to do the same thing with SDL you need more lines of code, but that’s pretty much all the drawbacks.
Maybe one more things annoying is adding all the extensions SDL_Image, SDL_ttf, SDL_mixer, SDL_gfx to have something similar to SFML (without the network part).
So I have started to port the game to SDL because I think it will make the game more stable, I don’t want to have a bug when it’s is the library’s fault and not mine.
This week I have compiled the game for Linux and MacOS X configuring and compiling libraries can take time. For example rapidxml do not compile on Xcode, I compile on GCC and visual studio. I have fixed a lot of bugs and I am working on releasing a demo. So I have also implemented a function to cipher the data (images and XML files). I have added a new option where the user can see the hitboxes of the objects.
I have done some work on the graphics, I tried to use pictures for the trees but it takes a lot of time to make the background transparent, so I am searching for a software to remove the background, but the problem is the background is not one color but many shades of blue.
Photoshop have some tolerance parameter for the selection but it also select some of the leaves so I have to pick a low value for tolerance and after that I need to clean the image by hand.
This week I have finished the second level which is shorter than the first level. Now I have started to find bugs in the game. Now I am trying to setting up a virtual machine running linux. I have tried debian Jessie 8.2 32bits but codeblocks is not available, and KDevelop crash after creating a project. I have tried to eclipse CDT which is too heavy for my taste. So I have decided to create another VM this time with Ubuntu 15.2 Vivid Vervet 64bits. I have also moved all of my projects into google drive because git is not very useful for one developer.
Good news everyone! The first level is finished and I am already working on the next level, this level is short in term of maps so I hope to finish it next week. Here is an unfinished drawing of a forest for the next level.