oldEffect = $oldEffect; } /** * Returns whether the effect addition will replace an existing effect already applied to the entity. * * @return bool */ public function willModify() : bool{ return $this->hasOldEffect(); } /** * @return bool */ public function hasOldEffect() : bool{ return $this->oldEffect instanceof EffectInstance; } /** * @return EffectInstance|null */ public function getOldEffect() : ?EffectInstance{ return $this->oldEffect; } }