mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-23 15:37:51 -08:00
Add Damage Control
This commit is contained in:
@@ -12,9 +12,14 @@ namespace SuperStarTrek.Systems
|
||||
}
|
||||
|
||||
public string Name { get; }
|
||||
public double Condition { get; }
|
||||
public double Condition { get; private set; }
|
||||
public bool IsDamaged => Condition < 0;
|
||||
public Command Command { get; }
|
||||
|
||||
public abstract void ExecuteCommand(Quadrant quadrant);
|
||||
public void Repair()
|
||||
{
|
||||
if (Condition < 0) { Condition = 0; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user