Fix pill level getting negative
This commit is contained in:
parent
ca1dc68f38
commit
efb88dbb48
@ -54,7 +54,8 @@ func _ready() -> void:
|
||||
|
||||
func _process(delta: float) -> void:
|
||||
# Gradually decrease the level by the decrease per second
|
||||
_level = _level - _decrease_per_second * delta
|
||||
_set_level(_level - _decrease_per_second * delta)
|
||||
|
||||
if _prev_level > LEVELS.VERY_LOW and _level < LEVELS.VERY_LOW:
|
||||
Logger.info("very low pill level")
|
||||
emit_signal("very_low_pill_level")
|
||||
|
Loading…
x
Reference in New Issue
Block a user