Once I decided I wanted to make a hexagon grid game I decided that I needed to make something that can generate a flexible hexagon grid for me. So, I began working out how I should generate this grid.

The first bit I did was to work out how far apart the tiles should be to form the grid. I did this by simply placing the tiles in the editor to work out how close they should be. Once I established how far away the tiles must be from each other, I then worked out how I would spawn the first 6 tiles. I did this by using the centre tile and then adding the difference to the position of each 6 tiles that surround the centre tile.

Once I had accurately generated the first layer of the grid, I then looked at expanding the grid. I did this by expanding upon the first layer by creating tiles in a line from the six tiles that surround the centre. This created a web shape grid.

Once I had this web shaped grid, I then had to fill in the holes around the grid. I did this by working out how much space is between the two closest tiles in the layer (that are already spawned). I then worked out how many tiles should go there and then instantiated tiles into correct positions to fill these gaps.