mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-11-22 18:45:29 +01:00
Tempfix all the things
This commit is contained in:
parent
6db2fa9ca6
commit
ad31ba7221
@ -24,7 +24,8 @@ public class Powered extends Trait implements Toggleable {
|
||||
|
||||
@Override
|
||||
public void onNPCSpawn() {
|
||||
((Creeper) npc.getBukkitEntity()).setPowered(powered);
|
||||
if (npc.getBukkitEntity() instanceof Creeper)
|
||||
((Creeper) npc.getBukkitEntity()).setPowered(powered);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -28,7 +28,8 @@ public class Saddle extends Trait implements Toggleable, Listener {
|
||||
|
||||
@Override
|
||||
public void onNPCSpawn() {
|
||||
((Pig) npc.getBukkitEntity()).setSaddle(saddle);
|
||||
if (npc.getBukkitEntity() instanceof Pig)
|
||||
((Pig) npc.getBukkitEntity()).setSaddle(saddle);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
@ -33,7 +33,8 @@ public class WoolColor extends Trait implements Listener {
|
||||
|
||||
@Override
|
||||
public void onNPCSpawn() {
|
||||
((Sheep) npc.getBukkitEntity()).setColor(color);
|
||||
if (npc.getBukkitEntity() instanceof Sheep)
|
||||
((Sheep) npc.getBukkitEntity()).setColor(color);
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
|
Loading…
Reference in New Issue
Block a user