8 lines
226 B
GDScript
8 lines
226 B
GDScript
extends Item
|
|
@export var heal_amount = 1
|
|
@export var max_health_increase = 1
|
|
|
|
func collect() -> bool:
|
|
player.max_hp += max_health_increase
|
|
player.current_hp = min(player.max_hp, player.current_hp + heal_amount)
|
|
return true
|