CityGen Script – Progress Report #2


Just another quick report on my progress on the city generator. Things have gone pretty well so far with this work.

I’ve reverted away from the idea of creating blocks. Instead I’ve created a new function which spaces out the city as planned that works a little like this:

  • Step 1: Creates the inner row or core of the city, large towers etc.
  • Step 2: Creates a ring around the inner core, slightly smaller towers.
  • Step 3: Creates another ring around the last row…. etc etc

I’ve also added a variable that specifies how many rows of towers each “city row” has.

Here is a picture to help describe what it does….

City Generator Zoning Map

City Generator Zoomed Out

This works perfectly, and has made the city block function redundant. The next step involved creating a suburb area for the outsides, and a new office type building, so the towers would progress into offices and then into houses. This was a relatively simple process and was just a matter of working out what the buildings would look like. Currently the office buildings are very simple but I’ll add more detail later. I’ve also added in a chance to create a church in the suburbs.

City Generator Zoning

Following on from that, I’ve made sure the tower height ranges and different building chances are correct for each zone of the city. This is still work in progress and will probably change a lot. I’ve also added a function to create some basic tree shapes and then incorporated that into the park function.

Finally, I’ve added some print functions to the script that print out its progress as it goes as well as some city statistics at the end. This means when Maya appears to have crashed due to the amount of geometry that’s been created, you can see the progress of the city via looking at the terminal.

City Generator with Trees

City Generator Print Function in Terminal
The next steps I have planned are to add detail to the offices, create more building types, create grasslands around the outsides and finally create a GUI for the script. I also might add some quick shaders to the geometry given time.

+ There are no comments

Add yours