Your browser (Internet Explorer 6) is out of date. It has known security flaws and may not display all features of this and other websites. Learn how to update your browser.
X
Video

Video of City Generation Progress

Here is the progress I’m making on the city generator. The building shells and egresses have been created and basic level of distance is in place. About 500 buildings are modelled in about 6 seconds so there’s some work to be done reducing this time and improving the quality of the models. The grey buildings in the background are serving as eye candy only.

Images

On Architecture

On Architecture

So when building a city, architecture is a very big question. I’ve always been an admirer of it, ask me when I was 5 what I wanted to do, and the response would have been ‘an Architect’. So when it comes to choosing a style that fits the scope, scale and style of the game, I had to do a bit of research…

One key point to make is that all buildings with have explorable interiors. Every floor, lift, stairwell and room will be generated. This is a departure from most city generators that concentrate on creating exterior content. This is also another reason why all my buildings will be convex rectangles to keep calculations simple and fast. My work so far is the basic creation of a building, there is a lot more to do to the externals to make them more interesting.

            

The city is going to have three styles of architecture; The Chicago School, Le Corbusier and the International Style. These all fit within the simple squared building that will occupy the Redacted world. Their structures are easy to produce procedurally compared to say Postmodern or Art Deco. The sharp angles and lines also increase the sense of order. A large theme in redacted is the nature of reality and what can we trust. The player will view the world reconstructed by his drone pilot program and a lot of information will be redacted for security purposes. I remember the set designers on the Matrix motion picture used a lot of right angles and squares in the Matrix world to reinforce the sense of artificial construction. These styles are also quite cold and functional, adding to the sense that the world is like this and you’re on your own.

 

Images

Building Plot Subdivision

Building Plot Subdivision

In most cities, a plot of land isn’t always occupied by a single building. Large buildings may do this – but a city won’t include many large buildings. So i need to divide some plots and into smaller pieces of land. I looked into many methods to do this and implemented a couple, settling on one in the end. There are three goals it needed to achieve. It must produce decent results that look real enough and produce only rectangles. Again, I kept this simple by avoiding irregular and non convex shapes. It must also do subdivide the plot quickly; in a city of hundreds of buildings, I couldn’t afford this algorithm to take it’s sweet time.

The method of room subdivision in this paper caught my eye. It would be very flexible, ensuring all plots had a road as I could grow the plots only from points where it met a road. It would also produce some nice irregular building shapes (as irregular as rectangles can be). So I set about implementing it to see some results. The hardest part of it was ensuring that the plot grown was a rectangle. This method was geared to creating irregular and concave plots. I realised quite quickly though, that this growing process was very expensive. I stupidly thought I should grow it metre by metre, not thinking that a small 20 by 20 plot would need at least 400 iterations, let alone a 100 by 100 metre plot. I was also never happy with the methods of ensuring it remained a rectangle. I ditched it.

I went back to the drawing board (thinking board?). This is too complex and i need to simplify the problem to get my result. In the end I settled for something far simpler and very quick. I would only divide a plot three times at a maximum and I would basically cut it at a random point through the length in a straight line. It was far simpler and quicker. The algorithm selects a plot big enough to be split and splits it a number of times either horizontally or vertically. I was happy with the results but a key improvement would include ensuring that cuts would not strand plots from roads as we can see in the above example.

Images

L-System based road generation

L-System based road generation

The first thing I started building was a city generator. After studying papers online, watching many videos and how Introversion software went about it, I built up an idea of what was needed and what I would avoid. I’m just one guy and my surname isn’t Delay so I kept it real simple. The road system is set to a grid so there are no curves or even diagonals in the city. Keeps all the maths simple.

There are many systems for producing a road system and many factors you can take into account. I ignored most of them mainly to keep the scope small and to keep complexity down. I settled on an incredibly simple algorithm to generate the road structure. It would essentially draw snake roads changing direction perpendicularly based on a seeded random generator. It would spend a lot of time retracing it’s steps to create city blocks. The outcome was pretty good with such a simple system and resembled something of a city.

Modifications to this included using multiple road iterations instead of just one so the road system flowed from the center. Otherwise there was a tendency to create linear city. I also randomly removed roads and modified others to make them alleys to keep it interesting. One final thing to implement will be to remove dead ends to improve gameplay later on. Dead ends are always frustrating unless you want to build a maze.