Pixie particles are now only spawned on the client (Fixes an NPE with them)

This commit is contained in:
Adubbz 2013-11-21 16:34:05 +11:00
parent 83c7ae8fd4
commit f0120e5269

View file

@ -96,12 +96,15 @@ public class EntityPixie extends EntityFlyingCreature
{
super.onEntityUpdate();
for (int i = 0; i < 7; i++)
if (this.worldObj.isRemote)
{
if (this.rand.nextInt(2) == 0)
{
BiomesOPlenty.proxy.spawnParticle("pixietrail", this.posX + (this.rand.nextDouble()) * (double)this.width, this.posY + this.rand.nextDouble() * (double)this.height - (double)this.yOffset, this.posZ + (this.rand.nextDouble()) * (double)this.width);
}
for (int i = 0; i < 7; i++)
{
if (this.rand.nextInt(2) == 0)
{
BiomesOPlenty.proxy.spawnParticle("pixietrail", this.posX + (this.rand.nextDouble()) * (double)this.width, this.posY + this.rand.nextDouble() * (double)this.height - (double)this.yOffset, this.posZ + (this.rand.nextDouble()) * (double)this.width);
}
}
}
}