name; } /** * Returns a Color object representing this effect's particle colour. */ public function getColor() : Color{ return $this->color; } /** * Returns whether this effect is harmful. * TODO: implement inverse effect results for undead mobs */ public function isBad() : bool{ return $this->bad; } /** * Returns the default duration (in ticks) this effect will apply for if a duration is not specified. */ public function getDefaultDuration() : int{ return $this->defaultDuration; } /** * Returns whether this effect will give the subject potion bubbles. */ public function hasBubbles() : bool{ return $this->hasBubbles; } /** * Returns whether the effect will do something on the current tick. */ public function canTick(EffectInstance $instance) : bool{ return false; } /** * Applies effect results to an entity. This will not be called unless canTick() returns true. */ public function applyEffect(Living $entity, EffectInstance $instance, float $potency = 1.0, ?Entity $source = null) : void{ } /** * Applies effects to the entity when the effect is first added. */ public function add(Living $entity, EffectInstance $instance) : void{ } /** * Removes the effect from the entity, resetting any changed values back to their original defaults. */ public function remove(Living $entity, EffectInstance $instance) : void{ } }