0 votes

Hi,

i'm making a tile-based game and the tiles have a propertie calles TileType. I inherited the Tileset class and added an array that can map tile id to TileType, so i can set the Tiletype for every tile and Tileset and save it to the Tileset resource. At the moment, a script for the TileMap node creates a Dictionary that maps tile coordinate -> TileType, so the TileType are easy to access for every tile and if i change the map, every tile has the corresponding TileType automatically.

Here is my Question:
Is it possible to create a recourse when the game is run in the editor or build? I could create a resource for every TileMap that holds the Dictionary so it doesn't need to be calculated every time the map is loaded in run-time?

Thanks for your help!

Godot version 3.2.2
in Engine by (14 points)

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.