freettrpg/scripts/content.gd
2024-06-18 18:58:47 +02:00

12 lines
357 B
GDScript

extends Node
# Variable to store the path from which JSON data is loaded
var loadPath
# Variable to store the loaded JSON data
var data
# Called when the node is added to the scene
func _ready():
loadPath = "res://content/stats.json" # Set the path to load JSON data from
data = Load.loadJSON(loadPath) # Load JSON data from the specified path