fix entity alive time calculation to account for resurrections better
This commit is contained in:
parent
30b193b463
commit
5087460cca
|
@ -74,8 +74,11 @@
|
||||||
:from at)
|
:from at)
|
||||||
|
|
||||||
; first state change we find is a death
|
; first state change we find is a death
|
||||||
(and (nil? current-status)
|
; OR, this is a death after one or more previous state changes and they were alive up til now
|
||||||
|
(or (and (nil? current-status)
|
||||||
(= :dead status))
|
(= :dead status))
|
||||||
|
(and (= :alive current-status)
|
||||||
|
(= :dead status)))
|
||||||
(assoc result
|
(assoc result
|
||||||
:current-status :dead
|
:current-status :dead
|
||||||
:from at
|
:from at
|
||||||
|
|
Reference in a new issue