Java Code Examples for thaumcraft.common.items.wands.ItemWandCasting#addVis()
The following examples show how to use
thaumcraft.common.items.wands.ItemWandCasting#addVis() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TileEntityIndustrialWandRecharge.java From Electro-Magic-Tools with GNU General Public License v3.0 | 6 votes |
@Override public void updateEntity() { ic2EnergySink.updateEntity(); if (!this.worldObj.isRemote) { if (getStackInSlot(0) != null) { ItemStack wand = getStackInSlot(0); if (wand != null && wand.getItem() instanceof ItemWandCasting) { ItemWandCasting wandItem = (ItemWandCasting) wand.getItem(); if (ic2EnergySink.useEnergy(ConfigHandler.wandChargerConsumption) && wandItem.getAspectsWithRoom(wand) != null) { wandItem.addVis(wand, Aspect.ORDER, 1, true); wandItem.addVis(wand, Aspect.FIRE, 1, true); wandItem.addVis(wand, Aspect.ENTROPY, 1, true); wandItem.addVis(wand, Aspect.WATER, 1, true); wandItem.addVis(wand, Aspect.EARTH, 1, true); wandItem.addVis(wand, Aspect.AIR, 1, true); } } worldObj.markBlockForUpdate(xCoord, yCoord, zCoord); } } }
Example 2
Source File: ItemWandChargingFocus.java From Electro-Magic-Tools with GNU General Public License v3.0 | 6 votes |
@Override public void onUsingFocusTick(ItemStack itemstack, EntityPlayer player, int integer) { if (!player.worldObj.isRemote) { ItemWandCasting wandItem = (ItemWandCasting) itemstack.getItem(); ItemStack armor = player.inventory.armorInventory[1]; if (armor != null) { if ((ElectricItem.manager.use(armor, ConfigHandler.wandChargeFocusCost / 4, player) && (ElectricItem.manager.use(armor, ConfigHandler.wandChargeFocusCost / 4, player)) && (ElectricItem.manager.use(armor, ConfigHandler.wandChargeFocusCost / 4, player)) && (ElectricItem.manager.use(armor, ConfigHandler.wandChargeFocusCost / 4, player)))) { wandItem.addVis(itemstack, Aspect.ORDER, 1, true); wandItem.addVis(itemstack, Aspect.FIRE, 1, true); wandItem.addVis(itemstack, Aspect.ENTROPY, 1, true); wandItem.addVis(itemstack, Aspect.WATER, 1, true); wandItem.addVis(itemstack, Aspect.EARTH, 1, true); wandItem.addVis(itemstack, Aspect.AIR, 1, true); } } } }