Rework game over logic and game initialization
This commit is contained in:
@@ -91,8 +91,8 @@ public class EffectService
|
||||
if (currentRoom is not MonsterRoom)
|
||||
return;
|
||||
|
||||
currentRoom.EnemiesInRoom.ForEach(e => e.HealthComponent.SetHealth(e.HealthComponent.MaximumHP.Value));
|
||||
_player.HealthComponent.SetHealth(_player.HealthComponent.MaximumHP.Value);
|
||||
currentRoom.EnemiesInRoom.ForEach(e => e.HealthComponent.SetCurrentHealth(e.HealthComponent.MaximumHP.Value));
|
||||
_player.HealthComponent.SetCurrentHealth(_player.HealthComponent.MaximumHP.Value);
|
||||
}
|
||||
|
||||
public void AbsorbHPFromAllEnemiesInRoom()
|
||||
@@ -134,7 +134,7 @@ public class EffectService
|
||||
var oldHp = _player.HealthComponent.CurrentHP.Value;
|
||||
var oldVt = _player.VTComponent.CurrentVT.Value;
|
||||
|
||||
_player.HealthComponent.SetHealth(oldVt);
|
||||
_player.HealthComponent.SetCurrentHealth(oldVt);
|
||||
_player.VTComponent.SetVT(oldHp);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user