Designing Data-Driven Dungeons

Learn how to create the data that describes our dungeon denizens using data-driven design.

Our game’s entities have much in common. For example, they all have a name, starting position, render information, and game stats. Rather than use a custom spawn function for every entity in the game, we’ll instead create a common spawn function that reads the game’s data file and adds components using the values found in that file. First, we need a data file and an appropriate format.

This course will use Rusty Object Notation (RON) files to store our game definition. RON is similar to JSON and other structured data formats, but it’s designed to look like Rust.

Create a new file named resources/template.ron and add the following game definition to it:

Get hands-on with 1200+ tech skills courses.