use of mod.azure.doom.entity.projectiles.BarrelEntity in project MCDoom by AzureDoom.
the class BarrelBlock method onExplosionDestroy.
public void onExplosionDestroy(World world, BlockPos pos, Explosion explosionIn) {
if (!world.isClient) {
BarrelEntity tntentity = new BarrelEntity(world, (double) pos.getX() + 0.5D, (double) pos.getY(), (double) pos.getZ() + 0.5D, explosionIn.getCausingEntity());
world.spawnEntity(tntentity);
}
}
use of mod.azure.doom.entity.projectiles.BarrelEntity in project MCDoom by AzureDoom.
the class BarrelBlock method primeBlock.
private static void primeBlock(World world, BlockPos pos, LivingEntity igniter) {
if (!world.isClient) {
BarrelEntity tntEntity = new BarrelEntity(world, (double) pos.getX() + 0.5D, (double) pos.getY(), (double) pos.getZ() + 0.5D, igniter);
world.spawnEntity(tntEntity);
world.playSound((PlayerEntity) null, tntEntity.getX(), tntEntity.getY(), tntEntity.getZ(), SoundEvents.ENTITY_TNT_PRIMED, SoundCategory.BLOCKS, 1.0F, 1.0F);
}
}
Aggregations