SPIGOT-3649: Backwards check in playEffect
By: md_5 <git@md-5.net>
This commit is contained in:
parent
52f9ea03cd
commit
660b7ed1b6
1 changed files with 1 additions and 1 deletions
|
@ -440,7 +440,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
|
||||||
public void playEffect(EntityEffect type) {
|
public void playEffect(EntityEffect type) {
|
||||||
Preconditions.checkArgument(type != null, "type");
|
Preconditions.checkArgument(type != null, "type");
|
||||||
|
|
||||||
if (this.getClass().isAssignableFrom(type.getApplicable())) {
|
if (type.getApplicable().isInstance(this)) {
|
||||||
this.getHandle().world.broadcastEntityEffect(getHandle(), type.getData());
|
this.getHandle().world.broadcastEntityEffect(getHandle(), type.getData());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue