From e5cee8d20c739ee466ec12722993814ed65c8219 Mon Sep 17 00:00:00 2001 From: Triple Cubes <113813506+TripleCubes@users.noreply.github.com> Date: Thu, 6 Jun 2024 02:21:28 +0700 Subject: [PATCH] Fix status are carried between fights (#106) * Fix status being carried between fights --- Entity/Components/StatusComponent.gd | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Entity/Components/StatusComponent.gd b/Entity/Components/StatusComponent.gd index 768a70f8..c1d2430a 100644 --- a/Entity/Components/StatusComponent.gd +++ b/Entity/Components/StatusComponent.gd @@ -11,6 +11,10 @@ class_name StatusComponent var current_status: Array[StatusBase] = [] +func _ready() -> void: + PhaseManager.on_event_win.connect(remove_all_status) + + ## Add a new status to the entity [br] ## The status caster is the one applying the status. [br] ## If the target entity already has the status, the duration of the new status is added to the existing one. [br]