use of WayofTime.alchemicalWizardry.common.block.RitualStone in project BloodMagic by WayofTime.
the class ModBlocks method init.
public static void init() {
blockAltar = new BlockAltar();
bloodRune = new BloodRune();
speedRune = new SpeedRune();
efficiencyRune = new EfficiencyRune();
runeOfSacrifice = new RuneOfSacrifice();
runeOfSelfSacrifice = new RuneOfSelfSacrifice();
blockTeleposer = new BlockTeleposer();
spectralBlock = new SpectralBlock();
ritualStone = new RitualStone();
blockMasterStone = new BlockMasterStone();
imperfectRitualStone = new ImperfectRitualStone();
bloodSocket = new BlockSocket();
armourForge = new ArmourForge();
emptySocket = new EmptySocket();
largeBloodStoneBrick = new LargeBloodStoneBrick();
bloodStoneBrick = new BloodStoneBrick();
blockWritingTable = new BlockWritingTable();
blockHomHeart = new BlockHomHeart();
blockPedestal = new BlockPedestal();
blockPlinth = new BlockPlinth();
blockConduit = new BlockConduit();
blockBloodLight = new BlockBloodLightSource();
blockSpellEffect = new BlockSpellEffect();
blockSpellParadigm = new BlockSpellParadigm();
blockSpellModifier = new BlockSpellModifier();
blockSpellEnhancement = new BlockSpellEnhancement();
blockSpectralContainer = new BlockSpectralContainer();
blockDemonPortal = new BlockDemonPortal();
blockBuildingSchematicSaver = new BlockSchematicSaver();
blockReagentConduit = new BlockReagentConduit();
blockAlchemicCalcinator = new BlockAlchemicCalcinator();
blockCrystalBelljar = new BlockBelljar();
blockDemonChest = new BlockDemonChest();
blockCrystal = new BlockCrystal();
blockMimic = new MimicBlock();
blockLifeEssence = new LifeEssenceBlock();
blockEnchantmentGlyph = new BlockEnchantmentGlyph();
blockStabilityGlyph = new BlockStabilityGlyph();
blockCrucible = new BlockCrucible();
}
use of WayofTime.alchemicalWizardry.common.block.RitualStone in project BloodMagic by WayofTime.
the class ItemRitualDismantler method breakRitualStoneAtMasterStone.
public boolean breakRitualStoneAtMasterStone(ItemStack stack, EntityPlayer player, World world, int x, int y, int z) {
TileEntity tileEntity = world.getTileEntity(x, y, z);
if (tileEntity instanceof TEMasterStone) {
TEMasterStone masterStone = (TEMasterStone) tileEntity;
int direction = masterStone.getDirection();
String ritualName = Rituals.checkValidRitual(world, x, y, z);
List<RitualComponent> ritualList = Rituals.getRitualList(ritualName);
if (ritualList == null) {
return false;
}
for (RitualComponent rc : ritualList) {
if (!world.isAirBlock(x + rc.getX(direction), y + rc.getY(), z + rc.getZ(direction)) && world.getBlock(x + rc.getX(direction), y + rc.getY(), z + rc.getZ(direction)) instanceof RitualStone) {
if (EnergyItems.syphonBatteries(stack, player, getEnergyUsed()) || player.capabilities.isCreativeMode) {
world.setBlockToAir(x + rc.getX(direction), y + rc.getY(), z + rc.getZ(direction));
EntityItem entityItem = new EntityItem(world, player.posX, player.posY, player.posZ, new ItemStack(ModBlocks.ritualStone));
if (world.isRemote) {
world.playAuxSFX(2005, x, y + 1, z, 0);
} else {
world.spawnEntityInWorld(entityItem);
}
}
}
}
return true;
}
return false;
}
Aggregations