Finding adjacent cells in an hex map – part 2

In the Finding adjacent cells in an hex map post I showed you how to find adjacent cells in horizontal hex maps.

Now it’s time to find adjacent cells in vertical hex maps.

Here it is:

This is the last uncommented step, during next one we will discuss about the method used to determine adjacent cells.

Download and enjoy!!

  • Nathan

    First comment! This is really cool, your tutorials are awesome.

  • JDog

    Second comment, Gratz ! looking great, what are you planning ?

  • Pingback: Bookmarks for March 9th from 11:18 to 11:19 « what i say // jon burger()

  • dahgapflilalf

    just looked through the topic! great work.

  • Jose Marin


    Another great tutorial!

    But this works if the 0,0 coordinates are top left but in my game (for Android) I have to use 0,0 at bottom left.

    What changes must I do in the function to work?

    Specially on the part that checks is a hexagon was touched, isn’t working for me.

    I´ve tried to change them myself, but isn’t working.

    Thanks a lot!