kotcity4 / kotcity.data / CityMap / build

build

fun build(building: Building, block: BlockCoordinate, updateBuildingIndex: Boolean = true): Unit

Plops the given Building at the given BlockCoordinate. Note the coordinate is the top-left of the building. We do check for collisions, hopefully preventing overlaps.

Parameters

building - Building to put

block - BlockCoordinate of that building

updateBuildingIndex - if true, update the spatial index. We MAY not want to do this in a bulk scenario like map loading