My Lord -2- Build phases

Building a building
I have rewritten most of the GUI code to the new GUI system that has been available since Unity 4.6. The construction menu is now fully working and 100% dynamic. This means I can easily add new buildings and building categories in the editor without having to position them manually in the scene. We can place these building in the scene, where first a 'construction' is being activated.



Build phases
A building is divided in so called 'Build phases'. A building has 1 or more build phases. The first build phase becomes active as soon as the player has placed the construction site, displaying a very basic foundation of the building. In the image below you can see the first build phase of a (placeholder) woodcutter building.



The villagers that are building at the construction site add health to the Health component. The construction checks the amount of progress. Based on the progress it activates new build phases, causing the building to further complete. Once the maximum health is reached, the final build phase is activated. The construction is now complete. At this point the Construction Component along with the Construction GUI Component are being removed from the gameobject.