mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-06-08 04:37:13 +08:00
feat: 更新UI组件,添加能量条和颜色条,优化能量管理逻辑
This commit is contained in:
@@ -5,7 +5,7 @@ class_name EntityStateBar
|
||||
|
||||
@onready var healthBar: ColorBar = $"%health"
|
||||
|
||||
func _process(_delta):
|
||||
func _physics_process(_delta):
|
||||
if is_instance_valid(entity):
|
||||
healthBar.maxValue = entity.fields.get(FieldStore.Entity.MAX_HEALTH)
|
||||
healthBar.setCurrent(entity.health)
|
||||
|
||||
Reference in New Issue
Block a user