![]() Such a graph is planar for a simple Settlers of Catan board. For this, the plan was to have every object of the game board (tiles, edges, and corners) represented by nodes in the graph and then have the edges of the graph represent the connections. ![]() This approach could simplify some of the logic of having to deal with coordinates in a hexagonal grid while still keeping the computational complexity of getting the neighboring game objects constant. When thinking about how else to represent such a board I wanted to try to instead model it as a graph. ![]() JSettlers2, catan-randomizer, html5-settlers-of-catan, and AIsOfCatan also all use coordinates to represent the tiles. There are also some other methods of representing coordinates in a hexagonal grid, is a nice article explaining these. colonizers also uses lists for the edges, corners and, tiles, but instead uses the 2D coordinate of the center of the objects to locate these and then uses the distance between the different object to find the neighboring objects. P圜atan uses lists for the edges, corners, and tiles, has a coordinate attached to every object, and then uses these to calculate the neighboring objects. To represent such a board as a data structure multiple approaches have been used over time. ![]() Settlers of Catan is a well-known board game that has a board made up of hexagonal tiles with pieces placed at the corners and edges between these tiles. ![]()
0 Comments
Leave a Reply. |