mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-28 06:51:54 +08:00
feat: 更新饲料和物品显示逻辑,添加香蕉饲料场景,重构字段显示功能
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
@tool
|
||||
extends HBoxContainer
|
||||
class_name ItemShow
|
||||
|
||||
@export var type: ItemStore.ItemType = ItemStore.ItemType.BASEBALL
|
||||
@export var count: int = 0
|
||||
@@ -7,6 +8,6 @@ extends HBoxContainer
|
||||
@onready var avatarTexture: TextureRect = $"%avatar"
|
||||
@onready var countLabel: Label = $"%count"
|
||||
|
||||
func _process(_delta):
|
||||
func _ready():
|
||||
avatarTexture.texture = load("res://resources/items/%s.svg" % ItemStore.idMap[type])
|
||||
countLabel.text = str(count)
|
||||
|
||||
Reference in New Issue
Block a user