Closed josephwegner closed 5 years ago
As a note, some preliminary work has started here. I am using cube coordinates to calculate neighbors for fills: https://github.com/josephwegner/hexamagon/commit/91fd7f6ad31b9b9b311f346b38368825105e0774#diff-c21d4984f1216f95c91cdeb77d0880e4R147
Right now we use a single-dimensional array to store all of the grid elements, and simply rely on the index of the item to determine where on the map that element exists. This is a simple structure, and works reasonably well, but it introduces quite a bit of complexity:
null
s that we must iterate through regularlyThere are a number of options for better grid systems. I would suggest we implement some sort of coordinate based hash (
x,y
orx,y,z
) and use that as a key in a JSON object.