min health = 0
This commit is contained in:
parent
68ef63210f
commit
f62787de04
1 changed files with 2 additions and 0 deletions
|
@ -65,6 +65,8 @@ public class Device {
|
|||
healthScore += delta;
|
||||
if (healthScore > 150)
|
||||
healthScore /= 10;
|
||||
} else {
|
||||
healthScore = 0;
|
||||
}
|
||||
messages.add(new DeviceEvent(id, owner, color, born, healthScore, Instant.now()));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue