Previous Techie Article: I. Of Birds and Herds
The Making Of Feudums
II. "Here Be Dragons"
As we intend to give you insight into the project, Derek has just started a somewhat technical topic about The Making of FEUDUMS. If you're interested to learn about techie black magic and fascinating technical dilemmas, you may want to follow it!
Trivia: "Here be dragons" (Lat. HIC SUNT DRACONES) means dangerous or unexplored territories, in imitation of the medieval practice of putting mythological creatures in uncharted areas of maps.
Today I'm trying to shed some light on the maps of the world of FEUDUMS.
Every Feudums' map has cells and these cells are hexagons. It might seem tricky but is not a big deal. The whole map is apprehensible as a two dimensional rectangular matrix, though we have to be careful when a unique cell wants to know its neighbours - they are shifted up or down with a half and there are six of them. Beyond that we can use a normal X, Y coordinate to describe the position of a cell.
An other question is the size of the map. As the Feudums is an MMO game we can expect a few thousands parallel players on one map, so the dimensions must be huge. That would be suicidal to build up the scene and keep the whole map in the memory. Even generating a few thousands game objects in the Unity would take too much time and obviously we could not let this happen.
The solution we implemented is building up just a segment of the whole map and using a cell decorator to refurbish the existing game objects on the fly. The camera is moving over the 2D plane and as it is moving the game engine removes the unnecessary cells and move over to the next necessary position while redecorate it depending on the required state.
Although there is no technical limitation regarding the size of the map, we introduced a 1000 x 1000 upper limit which was calculated based on the maximum number of players on a world and the average size of a feudum. With this size we have to manage a million cells if a player explores the whole map. Even in the case the bottle neck is not here but on the server side where we have to throw the command queues in and get back the new state in the shortest possible time.
The Feudums offers private maps along with the open maps, where the world owner can decide the size of the map and also whether the map is traversable or bordered. In case of a traversable map the player can walk through the whole map in one direction and every cell has the same environment, there are no borders around.
We are very curious how the players can make advantage from one setting or the other, but that is sure, the unlimited number of parallel worlds will give us enough possibility to try out any scenario.
You may also like these articles!
11 Substantial Features of FEUDUMS
The Anatomy of an MMO TBS
Birds and Herds
Creating a Map