7

This is most intuitive way that I can think of.


2

As long as they don't differ too vastly, the ratio of sizes between the two cell types is largely irrelevant to me. I'd also happily use several rows of transitional tiles if their borders can be procedurally determined. I also have no inherent preference for up-point or side-point hexes... This paragraph made me think of another, more universal solution: ...


2

For keyboard inputs, a simple but effective implementation is to have a set of keys that when repeatably pressed, change the player's orientation by rotating through the surrounding tiles in a clockwise or counter-wise direction. So you could set the 'A' and left arrow keys to cycle through adjacent cells in a counter-clockwise direction and the 'D' and ...


1

Sure there is! If you have a grid you do not need a collider. By definition grid works instead of collider. What you need to do is: Store (and retrieve) each tile address into (from) data structure (hashtable, dictionary or array, list). So now when you select (or do something) with one tile you can immediately access its neighbors! For simplicity lets ...


1

TL;DR: WebGL Demo & UnityPackage Download Recursive Nodes In the past I have tackled a similar problem by attaching a node component to each grid object. Each node component in turn keeps track of its neighbor nodes in a what could be described as a recursive manner. In my experience this approach works with thousands of nodes in a game world in a WebGL ...


1

You can achieve the desired result (if I interpreted your picture correctly) by replacing your point_distance function with something like this. The function determines the number of steps that are required to go from hexagon (x1,y1) to hexagon (x2,y2). This works by first determining the number of diagonal steps (which decrease the X and Y distance ...


1

You can create a hexagonal pattern with square tiles by creating each logical tile from 2x2 technical tiles and then arranging them in a staggered pattern like this: This might, however, require quite a lot of transition tiles. But if your engine allows tiles which are larger than the technical grid size, then you can design tiles like this: The ...


Only top voted, non community-wiki answers of a minimum length are eligible