loading words...

May 26, 2019 17:38:33

Unity - Procedural Map Generation Using Isometric Tilemaps

by @valentino | 204 words | 60🔥 | 358💌

Valentino Urbano

Current day streak: 60🔥
Total posts: 358💌
Total words: 170604 (682 pages 📄)

Unity has added great support for isometric tilemaps in recent years. You can work on tiles of your own dimensions over different layers.

This article is based on multiple components taken from the example Unity project on tilemaps including the pixel-perfect camera and the isometric character controller. You can find both in the example project.

Tilemap Layers

You can take the different layers from Unity's example isometric game as a solid starting point:

- Ground Layer

The layer where the player walks on. Most of your levels will usually be made of ground tiles.

- Ground Detail Layer

The obstacles and decorations related to the ground layer, a car for example.

- Level 1 layer

The "First floor" of the map. It's the layer the player walks on after having walked on a ramp and reached the "first floor" of the map.

- Level 1 Detail Layer

The obstacles and decorations related to the "first floor".

- Collider Layer

The only layer where automatic collision detection takes place. Used for both non-walking areas and obstacles.

Unity uses these layers to figure out what to draw on top or behind every single item in your scene since isometric is 2.5D: a 2D environment that gives the illusion of 3D.

[Part 2 coming tomorrow]

contact: email - twitter / Terms / Privacy