mirror of
https://github.com/2revoemag/PSF-BotServer.git
synced 2026-07-13 23:44:40 +00:00
Update EffectTarget.scala
Set back to findLast after review
This commit is contained in:
parent
537417f880
commit
9e76fcc42a
1 changed files with 1 additions and 1 deletions
|
|
@ -85,7 +85,7 @@ object EffectTarget {
|
||||||
|
|
||||||
private def CommonRepairConditions(v: Vehicle): Boolean = {
|
private def CommonRepairConditions(v: Vehicle): Boolean = {
|
||||||
v.Health > 0 && v.Health < v.MaxHealth &&
|
v.Health > 0 && v.Health < v.MaxHealth &&
|
||||||
(v.History.find { entry => entry.isInstanceOf[DamagingActivity] } match {
|
(v.History.findLast { entry => entry.isInstanceOf[DamagingActivity] } match {
|
||||||
case Some(entry) if System.currentTimeMillis() - entry.time < 5000L => false
|
case Some(entry) if System.currentTimeMillis() - entry.time < 5000L => false
|
||||||
case _ => true
|
case _ => true
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue