12 lines
230 B
GDScript
12 lines
230 B
GDScript
extends TextureRect
|
|
|
|
@onready var n: Label = $n
|
|
@onready var icon: TextureRect = $icon
|
|
|
|
var data:Dictionary
|
|
func set_data(_data:Dictionary):
|
|
data=_data
|
|
icon.texture=Database.get_texture(_data["icon"])
|
|
n.text=data["name"]
|
|
pass
|