I just finished to implement a better version of path finding for my cthulhu game.

The basis is still based on A* but i add some additional steps to make the path used by hostile smoother and clever: I describe my enhancements in drawings below:

  1. The first drawing explain the real situation: you have one hostile located at point A. This hostile is modelized as a rectange (the collision area); The hostile need to reach point B behind a wall.
  2. The second drawing explains a path finding result using A*. A* is based on tiled so you will have a tiled vision of the path to used to reach point B. But remember, our hostile is a rectangle on a map with x,y coordinates and not integer tile indices.
  3. My first enhancement take A* tile path result and remove unecessary tiles (see third drawing) to keep only turn points.
  4. Then i do some additional process to compute real points (x,y coordinates) which takes care of hostile collision area and mnimizes the path regarding turn points.

The result in action:

Few weeks ago, “followers” feature was implemented in my next game project “Cthulhu”. The code is still under development to be perfect but this video give an idea of the result.

I have not post to much on this blog but i have a good reason: I have move from France to Montréal, Canada for a new life ! New job and new city 🙂
I will try to post some artwork for my new game soon. So keep in touch !

blocks gameplayOne years ago, i just released my first android game on Google store. At a first sight, Blocks looks like a Tetris or a Bejeweled clone but the gameplay is indeed more complicated if you want to reach high scores.

As i explained in the game description, the goal is to group four blocks or more with the same color. If these blocks have only one color, they disappear. Otherwise the external color fade and the block is now made of one color. Seems pretty simple and you are right. But if you just play the game without trying to do chains, you score will remain low. So you will have to think about how to group block together and then drop the final block which will make all other dissapear in a row.
Game ends when the game area is full of blocks.

I just port my game to LibGDX to solve many issues and release as a 2.0 version. The game is free on google store, so please, enjoy ! 🙂 Blocks on Google Play!



Tiled map is a really good tool to create a classical 2D game. Everything already exists from editor to rendering. You just need to produce some tilesets, create a map with a tool like Tile map editor and with some few lines of code from libgdx, you have a 2D area game. You can find tons of tutorials explaining how to do this, including the official libgdx wiki.

Sadly nothing exists to render a fake perspective:BNyonmNCYAA6JYY if you put a wall tile on the map and use a sprite for a character behind the wall, the sprite will not be hidden because all tiles form the map are drawn before sprites.

After a discusion with @_TylerChurchill on twitter, I have implemented a solution using 2 different layers in my map, one for all the basic stuff (floor, walls, objects) and one for all elements that should hide all things drawn before – the “perspective”.

My standard map definition looks like the screenshot below:


I just added a new layer named “perspective”


And isolate all perspective elements in this layer:


In order to use this trick, I create a new TiledMapRenderer class from libgdx to ignore the “perspective” layer when the method #render() is called and add a new method to call to render it at the end of my drawing iteration process.

In my game initialization method,  I have initialized my new TileMapRenderer specifying that the layer to ignore is named “perspective”

In the rendering iteration process, i have called the #render() method from the map renderer, then i drew all sprites and then i have called the new #renderPerspective() method. Notice that you need to order all sprites using their “y” coordinates from the farest to the closest in order to keep a correct perspective for sprites.

The result: BOwerG0CEAAtsML

  • always add a padding between tiles to  avoid texture glitch. Texture smoothing could take adjacent pixel in consideration. A gap between tiles will avoid this problem.
  • consider using only one atlas image to render all the scene: switching between images on graphics processor take a lot of time.
  • using atlas help you manage only power of two size images even if content has not power of two size (open gl 1.x).
  • merge all animations for a sprite in one atlas image.
  • if you are using libgdx, the library propose a class which create automatically atlas image when called.

Like the post i did about tools i used, here the list of web sites which can help you to make a game. Some web site are talking about general development, not relative to any specific framework,  some are more relative to libgdx, and to finish some usefull links concerning graphics design:

Every developer has its own favorite tools but i think it’s always usefull to know what other people are using. Maybe someone will find the tool he was looking for since days. I found my pixel editor thanks to a post from an indy dev on twitter.
So here my list:
* IDEA intellij community edition : prefer the original comparing to android official IDE
* tortoise GIT because i prefer to have an external commit tool to manage images and other stuff not handled by IDE
* bitbucket free source code hosting. Some tools to manage the todo list
* inkscape to start graphic design before pixelize it
* pyxeledit the best pixel editor
* paint.net to edit image: simpler comparing to gimp
* libgdx to develop the game
* Tiled map editor to create map usable by libgdx
* BM Font to generate bitmap font
* as3sfxr for sounds

That’s all