Search Results

Search found 2 results on 1 pages for 'harmen'.

Page 1/1 | 1 

  • Most efficient way to save tile data of an isometric game

    - by Harmen
    Hello, I'm working on an isometric game for fast browsers that support <canvas>, which is great fun. To save information of each tile, I use a two-dimensional array which contains numbers representing a tile ID, like: var level = [[1, 1, 1, 2, 1, 0], [0, 1, 1, 2, 0, 1], [0, 1, 1, 2, 1, 1]]; var tiles = [ {name: 'grass', color: 'green'}, {name: 'water', color: 'blue'}, {name: 'forest', color: 'ForestGreen'} ]; So far it works great, but now I want to work with heights and slopes like in this picture: For each tile I need to save it's tile ID, height and information about which corners are turned upward. I came up with a simple idea about a bitwise representation of all four corners, like this: 1011 // top, bottom and left corner turned up My question is: what is the most efficient way to save these three values for each cell? Is it possible to save these three values as one integer?

    Read the article

  • What font do you use for your code editor?

    - by Harmen
    For a long time I used Courier New as default font for my code editor, until I got more into typography and found this new fixed-width font called Triskweline: The font is beautiful, but unfortunately it works only at size 10pt. This made me wonder: what (custom) font do you use for your code editor?

    Read the article

1