mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-23 03:16:35 +00:00
Revert "fixed negative effect durations when level tick rate is > 1"
This reverts commit 3614711a027c55df1723eefae36b4a79397e6e95.
This commit is contained in:
parent
bf55f03a3e
commit
7f0d0c9d63
@ -544,12 +544,9 @@ abstract class Living extends Entity implements Damageable{
|
|||||||
if($effect->canTick()){
|
if($effect->canTick()){
|
||||||
$effect->applyEffect($this);
|
$effect->applyEffect($this);
|
||||||
}
|
}
|
||||||
|
$effect->setDuration($effect->getDuration() - $tickDiff);
|
||||||
$duration = $effect->getDuration() - $tickDiff;
|
if($effect->getDuration() <= 0){
|
||||||
if($duration <= 0){
|
|
||||||
$this->removeEffect($effect->getId());
|
$this->removeEffect($effect->getId());
|
||||||
}else{
|
|
||||||
$effect->setDuration($duration);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user