P0-P-172: Part 71: Procedural City Generator
I am continuing with my Procedural City Generator. The collision issues are still causing problems. I have also had to rethink the core concept of the feature.
Normally, a system like this would be created by specifying an origin point, and then using an algorithm to create the city around, or beginning from, that origin point, using raycasts to align the objects to the ground.
However, with my virtual world, or virtual universe, concept, this won’t work. I will need to have the ability to create cities without the player being anywhere near the city’s location. I will need to basically simulate the city in code, and only render it when the player gets close.
What I have decided to do is to create the city on the server, using an origin point that will (eventually, I am hardcoding it for now) be based on the radius of the planet. I can then simulate the development of a civilisation, launching and landing of ships, creation and destruction of buildings, etc, without having to render the city at all. This will work perfectly for a persistent world game such as the one that I am creating.
When the user gets close enough to the city for it’s buildings to be visible, I can then render them, and use raycasting to align them to the terrain. This concept likely needs work, (I need to make sure the city isn’t in the middle of an ocean, or at the top of a mountain) but it should succeed.
I have completed most of the code for this, I just need to create a system that automatically pages the objects in and out of the scene as the users distance changes.

14/12/2016 , 05:42:40 AM
Unity Personal (64bit) – P0Main.unity – New Unity Project – PC, Mac & Linux Standalone

13/12/2016 , 11:52:44 PM
Unity Personal (64bit) – P0Main.unity – New Unity Project – PC, Mac & Linux Standalone

13/12/2016 , 10:44:51 PM
Unity Personal (64bit) – P0Main.unity – New Unity Project – PC, Mac & Linux Standalone
