Search in sources :

Example 1 with TileEntityPresent

use of net.mcft.copy.betterstorage.tile.entity.TileEntityPresent in project BetterStorage by copygirl.

the class PacketPresentOpen method handle.

@Override
public void handle(EntityPlayer player) {
    TileEntityPresent present = WorldUtils.get(player.worldObj, x, y, z, TileEntityPresent.class);
    EffectRenderer effRender = Minecraft.getMinecraft().effectRenderer;
    if (present != null)
        for (int side = 0; side < 6; side++) for (int i = 0; i < (destroy ? 2 : 20); i++) if (destroy)
            effRender.addBlockDestroyEffects(x, y, z, present.getBlockType(), present.getBlockMetadata());
        else
            effRender.addBlockHitEffects(x, y, z, side);
}
Also used : TileEntityPresent(net.mcft.copy.betterstorage.tile.entity.TileEntityPresent) EffectRenderer(net.minecraft.client.particle.EffectRenderer)

Aggregations

TileEntityPresent (net.mcft.copy.betterstorage.tile.entity.TileEntityPresent)1 EffectRenderer (net.minecraft.client.particle.EffectRenderer)1