Best method for procedural city generation

Hello,

I’m generating a city on a tiled block-by-block basis. The edge of each block meets in the centre of the surrounding road.

On block generation, would you advise using a RecastGraph? If so, would I have to manually connect each block with links?

The geometry is very simple (square buildings and streets) - but the area is very big (and will grow) so other suggestions are very welcome.

Thanks

Hi

Depends on:

  1. Is the world generation done during development or in real-time in the game.
  2. Do you have a single agent walking around or several.
    If several, are they always relatively close together?
  3. How big?

Hi,

  1. It’s done in real time - your bog-strandard noise based procedural system
  2. Lots of agents
  3. Haven’t thought about size limit yet, no doubt this will be down to performance. :slight_smile: The plan is to move AI/pathing to pure simulation when the player is far away.

Hm…
This is a hard problem.

Grid graphs might be too slow since the region was large.
See http://arongranberg.com/astar/webplayer?p=procedural for an example of what you can do with grid graphs.

Recast is most likely too slow to do full updates on, but it might be fast enough if your buildings are very simple and you can use navmesh cutting on them. See http://www.arongranberg.com/2013/08/navmesh-cutting/