Adios Soul Crap!
This commit is contained in:
parent
57c60fc073
commit
b2cd122725
|
@ -7,7 +7,6 @@ import net.minecraft.client.particle.EntityBreakingFX;
|
||||||
import net.minecraft.client.particle.EntityFX;
|
import net.minecraft.client.particle.EntityFX;
|
||||||
import net.minecraft.client.renderer.entity.RenderSnowball;
|
import net.minecraft.client.renderer.entity.RenderSnowball;
|
||||||
import biomesoplenty.api.Items;
|
import biomesoplenty.api.Items;
|
||||||
import biomesoplenty.blocks.renderers.AltarRenderer;
|
|
||||||
import biomesoplenty.blocks.renderers.BambooRenderer;
|
import biomesoplenty.blocks.renderers.BambooRenderer;
|
||||||
import biomesoplenty.blocks.renderers.FoliageRenderer;
|
import biomesoplenty.blocks.renderers.FoliageRenderer;
|
||||||
import biomesoplenty.blocks.renderers.GraveRenderer;
|
import biomesoplenty.blocks.renderers.GraveRenderer;
|
||||||
|
@ -43,7 +42,6 @@ public class ClientProxy extends CommonProxy {
|
||||||
@Override
|
@Override
|
||||||
public void registerRenderers()
|
public void registerRenderers()
|
||||||
{
|
{
|
||||||
RenderUtils.altarModel = RenderingRegistry.getNextAvailableRenderId();
|
|
||||||
RenderUtils.foliageModel = RenderingRegistry.getNextAvailableRenderId();
|
RenderUtils.foliageModel = RenderingRegistry.getNextAvailableRenderId();
|
||||||
RenderUtils.plantsModel = RenderingRegistry.getNextAvailableRenderId();
|
RenderUtils.plantsModel = RenderingRegistry.getNextAvailableRenderId();
|
||||||
RenderUtils.puddleModel = RenderingRegistry.getNextAvailableRenderId();
|
RenderUtils.puddleModel = RenderingRegistry.getNextAvailableRenderId();
|
||||||
|
@ -87,7 +85,6 @@ public class ClientProxy extends CommonProxy {
|
||||||
RenderingRegistry.registerBlockHandler(new FoliageRenderer());
|
RenderingRegistry.registerBlockHandler(new FoliageRenderer());
|
||||||
RenderingRegistry.registerBlockHandler(new PlantsRenderer());
|
RenderingRegistry.registerBlockHandler(new PlantsRenderer());
|
||||||
RenderingRegistry.registerBlockHandler(new SmallBlockRenderer());
|
RenderingRegistry.registerBlockHandler(new SmallBlockRenderer());
|
||||||
RenderingRegistry.registerBlockHandler(new AltarRenderer());
|
|
||||||
RenderingRegistry.registerBlockHandler(new PuddleRender());
|
RenderingRegistry.registerBlockHandler(new PuddleRender());
|
||||||
RenderingRegistry.registerBlockHandler(new GraveRenderer());
|
RenderingRegistry.registerBlockHandler(new GraveRenderer());
|
||||||
RenderingRegistry.registerBlockHandler(new BambooRenderer());
|
RenderingRegistry.registerBlockHandler(new BambooRenderer());
|
||||||
|
|
|
@ -97,8 +97,6 @@ public class Blocks
|
||||||
public static Optional<? extends Block> mudBrick = Optional.absent();
|
public static Optional<? extends Block> mudBrick = Optional.absent();
|
||||||
|
|
||||||
public static Optional<? extends Block> promisedPortal = Optional.absent();
|
public static Optional<? extends Block> promisedPortal = Optional.absent();
|
||||||
public static Optional<? extends Block> glass = Optional.absent();
|
|
||||||
public static Optional<? extends Block> altar = Optional.absent();
|
|
||||||
public static Optional<? extends Block> puddle = Optional.absent();
|
public static Optional<? extends Block> puddle = Optional.absent();
|
||||||
public static Optional<? extends Block> grave = Optional.absent();
|
public static Optional<? extends Block> grave = Optional.absent();
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,6 @@ public class Items
|
||||||
public static Optional<? extends Item> poison = Optional.absent();
|
public static Optional<? extends Item> poison = Optional.absent();
|
||||||
public static Optional<? extends Item> dartBlower = Optional.absent();
|
public static Optional<? extends Item> dartBlower = Optional.absent();
|
||||||
public static Optional<? extends Item> dart = Optional.absent();
|
public static Optional<? extends Item> dart = Optional.absent();
|
||||||
public static Optional<? extends Item> soulManipulator = Optional.absent();
|
|
||||||
|
|
||||||
public static Optional<? extends Item> flowerBand = Optional.absent();
|
public static Optional<? extends Item> flowerBand = Optional.absent();
|
||||||
public static Optional<? extends Item> wadingBoots = Optional.absent();
|
public static Optional<? extends Item> wadingBoots = Optional.absent();
|
||||||
|
|
|
@ -1,205 +0,0 @@
|
||||||
package biomesoplenty.blocks;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.block.material.Material;
|
|
||||||
import net.minecraft.client.renderer.texture.IconRegister;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.entity.item.EntityItem;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemPickaxe;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraft.util.Icon;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
import biomesoplenty.BiomesOPlenty;
|
|
||||||
import biomesoplenty.api.Blocks;
|
|
||||||
import biomesoplenty.api.Items;
|
|
||||||
import biomesoplenty.blocks.renderers.RenderUtils;
|
|
||||||
import biomesoplenty.tileentities.TileEntityAltar;
|
|
||||||
|
|
||||||
public class BlockAltar extends Block
|
|
||||||
{
|
|
||||||
private static final String[] altarTypes = new String[] {"altarframe"};
|
|
||||||
|
|
||||||
public static Icon altarFrame;
|
|
||||||
public static Icon altarFrameTop;
|
|
||||||
|
|
||||||
public static Icon frameMalachite;
|
|
||||||
public static Icon framePeridot;
|
|
||||||
public static Icon frameRuby;
|
|
||||||
public static Icon frameSapphire;
|
|
||||||
public static Icon frameTanzanite;
|
|
||||||
public static Icon frameTopaz;
|
|
||||||
|
|
||||||
public BlockAltar(int blockID)
|
|
||||||
{
|
|
||||||
super(blockID, Material.rock);
|
|
||||||
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
|
|
||||||
|
|
||||||
this.setHardness(3.0F);
|
|
||||||
this.setResistance(5.0F);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void registerIcons(IconRegister iconRegister)
|
|
||||||
{
|
|
||||||
altarFrame = iconRegister.registerIcon("biomesoplenty:altarframe");
|
|
||||||
altarFrameTop = iconRegister.registerIcon("biomesoplenty:altarframetop");
|
|
||||||
|
|
||||||
frameMalachite = iconRegister.registerIcon("biomesoplenty:framemalachite");
|
|
||||||
framePeridot = iconRegister.registerIcon("biomesoplenty:frameperidot");
|
|
||||||
frameRuby = iconRegister.registerIcon("biomesoplenty:frameruby");
|
|
||||||
frameSapphire = iconRegister.registerIcon("biomesoplenty:framesapphire");
|
|
||||||
frameTanzanite = iconRegister.registerIcon("biomesoplenty:frametanzanite");
|
|
||||||
frameTopaz = iconRegister.registerIcon("biomesoplenty:frametopaz");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Icon getIcon(int side, int meta)
|
|
||||||
{
|
|
||||||
if (side == 1 || side == 0)
|
|
||||||
{
|
|
||||||
return altarFrameTop;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return altarFrame;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean hasTileEntity(int metadata)
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public TileEntity createTileEntity(World world, int metadata)
|
|
||||||
{
|
|
||||||
return new TileEntityAltar();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int par6, float par7, float par8, float par9)
|
|
||||||
{
|
|
||||||
boolean returnStatement = false;
|
|
||||||
|
|
||||||
ItemStack equippedItem = player.getCurrentEquippedItem();
|
|
||||||
TileEntityAltar tileentityaltar = (TileEntityAltar) world.getBlockTileEntity(x, y, z);
|
|
||||||
|
|
||||||
if (equippedItem != null)
|
|
||||||
{
|
|
||||||
if (equippedItem.itemID == Items.miscItems.get().itemID && (equippedItem.getItemDamage() > 9 && equippedItem.getItemDamage() < 16))
|
|
||||||
{
|
|
||||||
if (tileentityaltar != null)
|
|
||||||
{
|
|
||||||
if (!tileentityaltar.getPresent(equippedItem.getItemDamage()))
|
|
||||||
{
|
|
||||||
if (!world.isRemote)
|
|
||||||
{
|
|
||||||
tileentityaltar.setPresent(equippedItem.getItemDamage(), true);
|
|
||||||
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
--equippedItem.stackSize;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
world.markBlockForUpdate(x, y, z);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
|
||||||
public void getSubBlocks(int blockID, CreativeTabs creativeTabs, List list) {
|
|
||||||
for (int i = 0; i < altarTypes.length; ++i) {
|
|
||||||
list.add(new ItemStack(blockID, 1, i));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean isOpaqueCube()
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean renderAsNormalBlock()
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getRenderType()
|
|
||||||
{
|
|
||||||
return RenderUtils.altarModel;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onBlockHarvested(World world, int x, int y, int z, int id, EntityPlayer par6EntityPlayer)
|
|
||||||
{
|
|
||||||
int meta = world.getBlockMetadata(x, y, z);
|
|
||||||
|
|
||||||
if (par6EntityPlayer.getCurrentEquippedItem() != null)
|
|
||||||
{
|
|
||||||
Item item = Item.itemsList[par6EntityPlayer.getCurrentEquippedItem().itemID];
|
|
||||||
|
|
||||||
if (item instanceof ItemPickaxe)
|
|
||||||
{
|
|
||||||
if (!world.isRemote && world.getGameRules().getGameRuleBooleanValue("doTileDrops"))
|
|
||||||
{
|
|
||||||
float f = 0.7F;
|
|
||||||
double d0 = (double)(world.rand.nextFloat() * f) + (double)(1.0F - f) * 0.5D;
|
|
||||||
double d1 = (double)(world.rand.nextFloat() * f) + (double)(1.0F - f) * 0.5D;
|
|
||||||
double d2 = (double)(world.rand.nextFloat() * f) + (double)(1.0F - f) * 0.5D;
|
|
||||||
EntityItem entityitem = new EntityItem(world, (double)x + d0, (double)y + d1, (double)z + d2, new ItemStack(Blocks.altar.get(), 1));
|
|
||||||
entityitem.delayBeforeCanPickup = 10;
|
|
||||||
world.spawnEntityInWorld(entityitem);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
dropBlockAsItem(world, x, y, z, id, meta);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public ArrayList<ItemStack> getBlockDropped(World world, int x, int y, int z, int meta, int fortune)
|
|
||||||
{
|
|
||||||
ArrayList<ItemStack> ret = new ArrayList<ItemStack>();
|
|
||||||
TileEntityAltar tileentityaltar = (TileEntityAltar) world.getBlockTileEntity(x, y, z);
|
|
||||||
|
|
||||||
if (tileentityaltar != null)
|
|
||||||
{
|
|
||||||
if (tileentityaltar.getPresent(10))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 10));
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(11))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 11));
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(12))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 12));
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(13))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 13));
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(14))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 14));
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(15))
|
|
||||||
ret.add(new ItemStack(Items.miscItems.get(), 1, 15));
|
|
||||||
}
|
|
||||||
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,317 +0,0 @@
|
||||||
package biomesoplenty.blocks;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Random;
|
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.block.material.Material;
|
|
||||||
import net.minecraft.client.renderer.texture.IconRegister;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.entity.boss.EntityDragon;
|
|
||||||
import net.minecraft.entity.effect.EntityLightningBolt;
|
|
||||||
import net.minecraft.entity.item.EntityTNTPrimed;
|
|
||||||
import net.minecraft.entity.passive.EntityVillager;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.AxisAlignedBB;
|
|
||||||
import net.minecraft.util.Icon;
|
|
||||||
import net.minecraft.world.IBlockAccess;
|
|
||||||
import net.minecraft.world.World;
|
|
||||||
import biomesoplenty.BiomesOPlenty;
|
|
||||||
import biomesoplenty.api.Blocks;
|
|
||||||
import biomesoplenty.api.Items;
|
|
||||||
import biomesoplenty.configuration.BOPAchievements;
|
|
||||||
import biomesoplenty.tileentities.TileEntityAltar;
|
|
||||||
import cpw.mods.fml.client.FMLClientHandler;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
|
|
||||||
public class BlockBOPGlass extends Block
|
|
||||||
{
|
|
||||||
private static final String[] glassTypes = new String[] {"celestiallens", "sacrificialfocus_empty", "sacrificialfocus_active", "sacrificialfocus_villager"};
|
|
||||||
private Icon[] textures;
|
|
||||||
|
|
||||||
public BlockBOPGlass(int blockID)
|
|
||||||
{
|
|
||||||
super(blockID, Material.glass);
|
|
||||||
this.setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
|
|
||||||
|
|
||||||
this.blockHardness = 0.37F;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int x, int y, int z)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 2)
|
|
||||||
{
|
|
||||||
float var5 = 0.01F;
|
|
||||||
return AxisAlignedBB.getAABBPool().getAABB(x, y, z, x + 1, y + 1 - var5, z + 1);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
return AxisAlignedBB.getAABBPool().getAABB(x, y, z, x + 1, y + 1, z + 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onEntityCollidedWithBlock(World world, int x, int y, int z, Entity entity)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 2)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (entity instanceof EntityVillager)
|
|
||||||
{
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 3, 2);
|
|
||||||
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x + 1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x -1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z + 1));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z - 1));
|
|
||||||
|
|
||||||
entity.setDead();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int meta, float par7, float par8, float par9)
|
|
||||||
{
|
|
||||||
ItemStack equippedItem = player.getCurrentEquippedItem();
|
|
||||||
Random rand = new Random();
|
|
||||||
|
|
||||||
if (equippedItem != null)
|
|
||||||
{
|
|
||||||
if (equippedItem.itemID == Items.soulManipulator.get().itemID)
|
|
||||||
{
|
|
||||||
if (equippedItem.getItemDamage() == 0)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 2)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
player.setCurrentItemOrArmor(0, new ItemStack(Items.soulManipulator.get(), 1, 1));
|
|
||||||
}
|
|
||||||
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 1, 2);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (world.getBlockMetadata(x, y, z) == 3)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
player.setCurrentItemOrArmor(0, new ItemStack(Items.soulManipulator.get(), 1, 2));
|
|
||||||
}
|
|
||||||
|
|
||||||
FMLClientHandler.instance().getClient().sndManager.playSound("mob.villager.idle", (float) x + 0.5F, (float) y + 0.5F, (float) z + 0.5F, 1.0F, 1.0F);
|
|
||||||
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 1, 2);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (equippedItem.getItemDamage() == 1)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 1)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
player.setCurrentItemOrArmor(0, new ItemStack(Items.soulManipulator.get(), 1, 0));
|
|
||||||
}
|
|
||||||
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x + 1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x -1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z + 1));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z - 1));
|
|
||||||
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 2, 2);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 3)
|
|
||||||
{
|
|
||||||
if (player.dimension == 1)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
player.setCurrentItemOrArmor(0, new ItemStack(Items.soulManipulator.get(), 1, 0));
|
|
||||||
}
|
|
||||||
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 1, z));
|
|
||||||
|
|
||||||
if (world.isRemote)
|
|
||||||
{
|
|
||||||
FMLClientHandler.instance().getClient().sndManager.playSound("mob.wither.death", (float) x + 0.5F, (float) y + 0.5F, (float) z + 0.5F, 5.0F, 10.0F);
|
|
||||||
FMLClientHandler.instance().getClient().sndManager.playSound("mob.enderdragon.growl", (float) x + 0.5F, (float) y + 0.5F, (float) z + 0.5F, 5.0F, 1.0F);
|
|
||||||
}
|
|
||||||
|
|
||||||
player.addStat(BOPAchievements.achSacrifice, 1);
|
|
||||||
|
|
||||||
if (!world.isRemote)
|
|
||||||
{
|
|
||||||
world.spawnEntityInWorld(new EntityDragon(world));
|
|
||||||
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 1, 2);
|
|
||||||
|
|
||||||
Entity entitytnt = new EntityTNTPrimed(world);
|
|
||||||
|
|
||||||
world.createExplosion(entitytnt, (double)x, (double)y, (double)z, 10.0F, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (equippedItem.getItemDamage() == 2)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x, y, z) == 2)
|
|
||||||
{
|
|
||||||
if (checkAltarStructreIntegrity(world, x, y, z))
|
|
||||||
{
|
|
||||||
if (player.dimension != 1)
|
|
||||||
{
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x + 1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x -1, y + 2, z));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z + 1));
|
|
||||||
world.spawnEntityInWorld(new EntityLightningBolt(world, x, y + 2, z - 1));
|
|
||||||
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
player.setCurrentItemOrArmor(0, new ItemStack(Items.soulManipulator.get(), 1, 0));
|
|
||||||
}
|
|
||||||
|
|
||||||
world.setBlockMetadataWithNotify(x, y, z, 3, 2);
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static boolean checkAltarStructreIntegrity(World world, int x, int y, int z)
|
|
||||||
{
|
|
||||||
TileEntityAltar tileentityaltar0 = (TileEntityAltar) world.getBlockTileEntity(x + 1, y, z);
|
|
||||||
TileEntityAltar tileentityaltar1 = (TileEntityAltar) world.getBlockTileEntity(x - 1, y, z);
|
|
||||||
TileEntityAltar tileentityaltar2 = (TileEntityAltar) world.getBlockTileEntity(x, y, z + 1);
|
|
||||||
TileEntityAltar tileentityaltar3 = (TileEntityAltar) world.getBlockTileEntity(x, y, z - 1);
|
|
||||||
|
|
||||||
if (tileentityaltar0 != null && tileentityaltar1 != null && tileentityaltar2 != null && tileentityaltar3 != null)
|
|
||||||
if (tileentityaltar0.getAllPresent() && tileentityaltar1.getAllPresent() && tileentityaltar2.getAllPresent() && tileentityaltar3.getAllPresent())
|
|
||||||
{
|
|
||||||
if (world.getBlockId(x + 1, y + 1, z) == Blocks.bones.get().blockID && world.getBlockId(x - 1, y + 1, z) == Blocks.bones.get().blockID && world.getBlockId(x, y + 1, z + 1) == Blocks.bones.get().blockID && world.getBlockId(x, y + 1, z - 1) == Blocks.bones.get().blockID)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x + 1, y + 1, z) == 1 && world.getBlockMetadata(x - 1, y + 1, z) == 1 && world.getBlockMetadata(x, y + 1, z + 1) == 1 && world.getBlockMetadata(x, y + 1, z - 1) == 1)
|
|
||||||
{
|
|
||||||
if (world.getBlockId(x + 1, y + 2, z) == Blocks.bones.get().blockID && world.getBlockId(x - 1, y + 2, z) == Blocks.bones.get().blockID && world.getBlockId(x, y + 2, z + 1) == Blocks.bones.get().blockID && world.getBlockId(x, y + 2, z - 1) == Blocks.bones.get().blockID)
|
|
||||||
{
|
|
||||||
if (world.getBlockMetadata(x + 1, y + 2, z) == 0 && world.getBlockMetadata(x - 1, y + 2, z) == 0 && world.getBlockMetadata(x, y + 2, z + 1) == 0 && world.getBlockMetadata(x, y + 2, z - 1) == 0)
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getDamageValue(World world, int x, int y, int z)
|
|
||||||
{
|
|
||||||
int meta = world.getBlockMetadata(x, y, z);
|
|
||||||
|
|
||||||
if (meta == 2 || meta == 3)
|
|
||||||
{
|
|
||||||
meta = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return meta;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int quantityDropped(Random par1Random)
|
|
||||||
{
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
@SideOnly(Side.CLIENT)
|
|
||||||
public int getRenderBlockPass()
|
|
||||||
{
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean shouldSideBeRendered(IBlockAccess par1IBlockAccess, int par2, int par3, int par4, int par5)
|
|
||||||
{
|
|
||||||
return super.shouldSideBeRendered(par1IBlockAccess, par2, par3, par4, 1 - par5);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean isOpaqueCube()
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected boolean canSilkHarvest()
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void registerIcons(IconRegister iconRegister)
|
|
||||||
{
|
|
||||||
textures = new Icon[glassTypes.length];
|
|
||||||
|
|
||||||
for (int i = 0; i < glassTypes.length; ++i) {
|
|
||||||
textures[i] = iconRegister.registerIcon("biomesoplenty:"+glassTypes[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Icon getIcon(int side, int meta)
|
|
||||||
{
|
|
||||||
if (meta < 0 || meta >= textures.length) {
|
|
||||||
meta = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return textures[meta];
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
|
||||||
public void getSubBlocks(int blockID, CreativeTabs creativeTabs, List list)
|
|
||||||
{
|
|
||||||
for (int i = 0; i < glassTypes.length; ++i)
|
|
||||||
{
|
|
||||||
if (i != 2 && i != 3)
|
|
||||||
list.add(new ItemStack(blockID, 1, i));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int damageDropped(int meta)
|
|
||||||
{
|
|
||||||
return meta;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,96 +0,0 @@
|
||||||
package biomesoplenty.blocks.renderers;
|
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
|
||||||
import net.minecraft.client.renderer.RenderBlocks;
|
|
||||||
import net.minecraft.client.renderer.Tessellator;
|
|
||||||
import net.minecraft.util.Icon;
|
|
||||||
import net.minecraft.world.IBlockAccess;
|
|
||||||
import net.minecraftforge.common.ForgeDirection;
|
|
||||||
import biomesoplenty.blocks.BlockAltar;
|
|
||||||
import biomesoplenty.tileentities.TileEntityAltar;
|
|
||||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
|
||||||
|
|
||||||
public class AltarRenderer implements ISimpleBlockRenderingHandler
|
|
||||||
{
|
|
||||||
@Override
|
|
||||||
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer)
|
|
||||||
{
|
|
||||||
TileEntityAltar tileentityaltar = (TileEntityAltar) world.getBlockTileEntity(x, y, z);
|
|
||||||
|
|
||||||
if (modelId == RenderUtils.altarModel)
|
|
||||||
{
|
|
||||||
if (tileentityaltar != null)
|
|
||||||
{
|
|
||||||
renderer.renderStandardBlock(block, x, y, z);
|
|
||||||
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.altarFrame, world, x, y, z);
|
|
||||||
|
|
||||||
if (renderer.hasOverrideBlockTexture())
|
|
||||||
{
|
|
||||||
renderer.setOverrideBlockTexture(null);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(10))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.frameRuby, world, x, y, z);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(11))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.framePeridot, world, x, y, z);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(12))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.frameTopaz, world, x, y, z);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(13))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.frameTanzanite, world, x, y, z);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(14))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.frameMalachite, world, x, y, z);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (tileentityaltar.getPresent(15))
|
|
||||||
{
|
|
||||||
renderAltarSlotFaces(renderer, block, BlockAltar.frameSapphire, world, x, y, z);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void renderAltarSlotFaces(RenderBlocks renderer, Block block, Icon icon, IBlockAccess world, int x, int y, int z)
|
|
||||||
{
|
|
||||||
RenderUtils.renderFace(renderer, block, icon, world, x, y, z, ForgeDirection.NORTH);
|
|
||||||
RenderUtils.renderFace(renderer, block, icon, world, x, y, z, ForgeDirection.EAST);
|
|
||||||
RenderUtils.renderFace(renderer, block, icon, world, x, y, z, ForgeDirection.SOUTH);
|
|
||||||
RenderUtils.renderFace(renderer, block, icon, world, x, y, z, ForgeDirection.WEST);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void renderInventoryBlock(Block block, int metadata, int modelID, RenderBlocks renderer)
|
|
||||||
{
|
|
||||||
Tessellator tessellator = Tessellator.instance;
|
|
||||||
|
|
||||||
renderer.setRenderBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);
|
|
||||||
RenderUtils.renderStandardInvBlock(renderer, block, metadata);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean shouldRender3DInInventory()
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getRenderId()
|
|
||||||
{
|
|
||||||
return RenderUtils.altarModel;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -13,7 +13,6 @@ import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
public class RenderUtils
|
public class RenderUtils
|
||||||
{
|
{
|
||||||
public static int altarModel = -1;
|
|
||||||
public static int foliageModel = -1;
|
public static int foliageModel = -1;
|
||||||
public static int plantsModel = -1;
|
public static int plantsModel = -1;
|
||||||
public static int puddleModel = -1;
|
public static int puddleModel = -1;
|
||||||
|
|
|
@ -5,7 +5,6 @@ import net.minecraft.block.BlockHalfSlab;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import biomesoplenty.api.Blocks;
|
import biomesoplenty.api.Blocks;
|
||||||
import biomesoplenty.blocks.BlockAltar;
|
|
||||||
import biomesoplenty.blocks.BlockAsh;
|
import biomesoplenty.blocks.BlockAsh;
|
||||||
import biomesoplenty.blocks.BlockBOPAmethyst;
|
import biomesoplenty.blocks.BlockBOPAmethyst;
|
||||||
import biomesoplenty.blocks.BlockBOPAppleLeaves;
|
import biomesoplenty.blocks.BlockBOPAppleLeaves;
|
||||||
|
@ -17,7 +16,6 @@ import biomesoplenty.blocks.BlockBOPFlower2;
|
||||||
import biomesoplenty.blocks.BlockBOPFoliage;
|
import biomesoplenty.blocks.BlockBOPFoliage;
|
||||||
import biomesoplenty.blocks.BlockBOPGeneric;
|
import biomesoplenty.blocks.BlockBOPGeneric;
|
||||||
import biomesoplenty.blocks.BlockBOPGeneric.BlockType;
|
import biomesoplenty.blocks.BlockBOPGeneric.BlockType;
|
||||||
import biomesoplenty.blocks.BlockBOPGlass;
|
|
||||||
import biomesoplenty.blocks.BlockBOPGrass;
|
import biomesoplenty.blocks.BlockBOPGrass;
|
||||||
import biomesoplenty.blocks.BlockBOPLeaves;
|
import biomesoplenty.blocks.BlockBOPLeaves;
|
||||||
import biomesoplenty.blocks.BlockBOPLeaves.LeafCategory;
|
import biomesoplenty.blocks.BlockBOPLeaves.LeafCategory;
|
||||||
|
@ -53,7 +51,6 @@ import biomesoplenty.blocks.BlockStoneFormations;
|
||||||
import biomesoplenty.blocks.BlockTreeMoss;
|
import biomesoplenty.blocks.BlockTreeMoss;
|
||||||
import biomesoplenty.blocks.BlockWillow;
|
import biomesoplenty.blocks.BlockWillow;
|
||||||
import biomesoplenty.configuration.configfile.BOPConfigurationIDs;
|
import biomesoplenty.configuration.configfile.BOPConfigurationIDs;
|
||||||
import biomesoplenty.itemblocks.ItemBlockAltar;
|
|
||||||
import biomesoplenty.itemblocks.ItemBlockAppleLeaves;
|
import biomesoplenty.itemblocks.ItemBlockAppleLeaves;
|
||||||
import biomesoplenty.itemblocks.ItemBlockBamboo;
|
import biomesoplenty.itemblocks.ItemBlockBamboo;
|
||||||
import biomesoplenty.itemblocks.ItemBlockBones;
|
import biomesoplenty.itemblocks.ItemBlockBones;
|
||||||
|
@ -63,7 +60,6 @@ import biomesoplenty.itemblocks.ItemBlockCoral;
|
||||||
import biomesoplenty.itemblocks.ItemBlockFlower;
|
import biomesoplenty.itemblocks.ItemBlockFlower;
|
||||||
import biomesoplenty.itemblocks.ItemBlockFlower2;
|
import biomesoplenty.itemblocks.ItemBlockFlower2;
|
||||||
import biomesoplenty.itemblocks.ItemBlockFoliage;
|
import biomesoplenty.itemblocks.ItemBlockFoliage;
|
||||||
import biomesoplenty.itemblocks.ItemBlockGlass;
|
|
||||||
import biomesoplenty.itemblocks.ItemBlockGrass;
|
import biomesoplenty.itemblocks.ItemBlockGrass;
|
||||||
import biomesoplenty.itemblocks.ItemBlockGrave;
|
import biomesoplenty.itemblocks.ItemBlockGrave;
|
||||||
import biomesoplenty.itemblocks.ItemBlockHive;
|
import biomesoplenty.itemblocks.ItemBlockHive;
|
||||||
|
@ -84,7 +80,6 @@ import biomesoplenty.itemblocks.ItemBlockStoneFormations;
|
||||||
import biomesoplenty.items.ItemBOPAmethyst;
|
import biomesoplenty.items.ItemBOPAmethyst;
|
||||||
import biomesoplenty.items.ItemBOPIvy;
|
import biomesoplenty.items.ItemBOPIvy;
|
||||||
import biomesoplenty.items.ItemBOPWillow;
|
import biomesoplenty.items.ItemBOPWillow;
|
||||||
import biomesoplenty.tileentities.TileEntityAltar;
|
|
||||||
|
|
||||||
import com.google.common.base.Optional;
|
import com.google.common.base.Optional;
|
||||||
|
|
||||||
|
@ -115,7 +110,6 @@ public class BOPBlocks
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.holyGrass.get(), 0, "pickaxe", 0);
|
MinecraftForge.setBlockHarvestLevel(Blocks.holyGrass.get(), 0, "pickaxe", 0);
|
||||||
|
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.driedDirt.get(), "pickaxe", 0);
|
MinecraftForge.setBlockHarvestLevel(Blocks.driedDirt.get(), "pickaxe", 0);
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.altar.get(), "pickaxe", 0);
|
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 0, "pickaxe", 3);
|
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 0, "pickaxe", 3);
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 2, "pickaxe", 2);
|
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 2, "pickaxe", 2);
|
||||||
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 4, "pickaxe", 2);
|
MinecraftForge.setBlockHarvestLevel(Blocks.amethystOre.get(), 4, "pickaxe", 2);
|
||||||
|
@ -190,10 +184,6 @@ public class BOPBlocks
|
||||||
|
|
||||||
Blocks.bones = Optional.of((new BlockBones(BOPConfigurationIDs.bonesID)).setStepSound(Block.soundStoneFootstep).setUnlocalizedName("bop.bones"));
|
Blocks.bones = Optional.of((new BlockBones(BOPConfigurationIDs.bonesID)).setStepSound(Block.soundStoneFootstep).setUnlocalizedName("bop.bones"));
|
||||||
|
|
||||||
Blocks.glass = Optional.of((new BlockBOPGlass(BOPConfigurationIDs.glassID)).setStepSound(Block.soundGlassFootstep).setUnlocalizedName("bop.glass"));
|
|
||||||
|
|
||||||
Blocks.altar = Optional.of((new BlockAltar(BOPConfigurationIDs.altarID)).setStepSound(Block.soundStoneFootstep).setUnlocalizedName("bop.altar"));
|
|
||||||
|
|
||||||
Blocks.puddle = Optional.of((new BlockPuddle(BOPConfigurationIDs.puddleID)).setHardness(0.6F).setStepSound(Block.soundGravelFootstep).setUnlocalizedName("bop.puddle"));
|
Blocks.puddle = Optional.of((new BlockPuddle(BOPConfigurationIDs.puddleID)).setHardness(0.6F).setStepSound(Block.soundGravelFootstep).setUnlocalizedName("bop.puddle"));
|
||||||
Blocks.grave = Optional.of((new BlockGrave(BOPConfigurationIDs.graveID)).setStepSound(Block.soundStoneFootstep).setUnlocalizedName("bop.grave"));
|
Blocks.grave = Optional.of((new BlockGrave(BOPConfigurationIDs.graveID)).setStepSound(Block.soundStoneFootstep).setUnlocalizedName("bop.grave"));
|
||||||
|
|
||||||
|
@ -275,8 +265,6 @@ public class BOPBlocks
|
||||||
GameRegistry.registerBlock(Blocks.honeyBlock.get(), "bop.honeyBlock");
|
GameRegistry.registerBlock(Blocks.honeyBlock.get(), "bop.honeyBlock");
|
||||||
|
|
||||||
GameRegistry.registerBlock(Blocks.bones.get(), ItemBlockBones.class, "bop.bones");
|
GameRegistry.registerBlock(Blocks.bones.get(), ItemBlockBones.class, "bop.bones");
|
||||||
GameRegistry.registerBlock(Blocks.glass.get(), ItemBlockGlass.class, "bop.glass");
|
|
||||||
GameRegistry.registerBlock(Blocks.altar.get(), ItemBlockAltar.class, "bop.altar");
|
|
||||||
GameRegistry.registerBlock(Blocks.puddle.get(), "bop.puddle");
|
GameRegistry.registerBlock(Blocks.puddle.get(), "bop.puddle");
|
||||||
GameRegistry.registerBlock(Blocks.grave.get(), ItemBlockGrave.class, "bop.grave");
|
GameRegistry.registerBlock(Blocks.grave.get(), ItemBlockGrave.class, "bop.grave");
|
||||||
|
|
||||||
|
@ -311,7 +299,6 @@ public class BOPBlocks
|
||||||
|
|
||||||
private static void registerTileEntities()
|
private static void registerTileEntities()
|
||||||
{
|
{
|
||||||
GameRegistry.registerTileEntity(TileEntityAltar.class, "tileEntityAltar");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void addGrassPlants()
|
private static void addGrassPlants()
|
||||||
|
|
|
@ -255,15 +255,6 @@ public class BOPCrafting
|
||||||
GameRegistry.addRecipe(new ItemStack(Items.bopDiscMud.get(), 1), new Object[] {" M ", "MDM", " M ", 'M', Items.mudball.get(), 'D', Items.bopDisc.get()});
|
GameRegistry.addRecipe(new ItemStack(Items.bopDiscMud.get(), 1), new Object[] {" M ", "MDM", " M ", 'M', Items.mudball.get(), 'D', Items.bopDisc.get()});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (BOPConfigurationMisc.altarCrafting)
|
|
||||||
{
|
|
||||||
GameRegistry.addRecipe(new ItemStack(Items.soulManipulator.get(), 1, 0), new Object[] {"G", "T", "B", 'G', Block.glass, 'T', Item.ghastTear, 'B', Item.blazeRod});
|
|
||||||
GameRegistry.addRecipe(new ItemStack(Items.soulManipulator.get(), 1, 1), new Object[] {"TSA", "PMS", "APT", 'S', new ItemStack(Items.miscItems.get(), 1, 16), 'A', Block.slowSand, 'T', Item.ghastTear, 'P', Item.blazePowder, 'M', new ItemStack(Items.soulManipulator.get(), 1, 0)});
|
|
||||||
GameRegistry.addRecipe(new ItemStack(Blocks.altar.get(), 1), new Object[] {"OBO", "BBB", "OBO", 'O', Block.obsidian, 'B', new ItemStack(Blocks.bones.get(), 1, 2)});
|
|
||||||
GameRegistry.addRecipe(new ItemStack(Blocks.glass.get(), 1, 1), new Object[] {"PCP", "CSC", "PCP", 'P', Item.blazePowder, 'C', new ItemStack(Blocks.glass.get(), 1, 0), 'S', new ItemStack(Items.miscItems.get(), 1, 16)});
|
|
||||||
GameRegistry.addRecipe(new ItemStack(Blocks.glass.get(), 1, 0), new Object [] {"CGC", "GGG", "CGC", Character.valueOf('G'), new ItemStack(Blocks.crystal.get(), 1, 0), Character.valueOf('C'), new ItemStack(Items.miscItems.get(), 1, 4)});
|
|
||||||
}
|
|
||||||
|
|
||||||
//Dart Blower
|
//Dart Blower
|
||||||
if (BOPConfigurationMisc.dartCrafting)
|
if (BOPConfigurationMisc.dartCrafting)
|
||||||
{
|
{
|
||||||
|
@ -295,9 +286,6 @@ public class BOPCrafting
|
||||||
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 4), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 0), Item.appleRed, Item.melon});
|
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 4), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 0), Item.appleRed, Item.melon});
|
||||||
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 5), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 2), Item.carrot, Item.potato});
|
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 5), new Object[] {Item.bowlEmpty, new ItemStack(Items.food.get(), 1, 2), Item.carrot, Item.potato});
|
||||||
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 6), new Object[] {Item.bowlEmpty, new ItemStack(Blocks.mushrooms.get(), 1, 0), new ItemStack(Blocks.mushrooms.get(), 1, 1), new ItemStack(Blocks.mushrooms.get(), 1, 2)});
|
GameRegistry.addShapelessRecipe(new ItemStack(Items.food.get(), 1, 6), new Object[] {Item.bowlEmpty, new ItemStack(Blocks.mushrooms.get(), 1, 0), new ItemStack(Blocks.mushrooms.get(), 1, 1), new ItemStack(Blocks.mushrooms.get(), 1, 2)});
|
||||||
|
|
||||||
//Glass
|
|
||||||
//GameRegistry.addRecipe(new ItemStack(Blocks.glass.get(), 1, 0), new Object [] {"GGG", "GGG", "GGG", Character.valueOf('G'), Block.glass});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void addSmeltingRecipes()
|
private static void addSmeltingRecipes()
|
||||||
|
|
|
@ -31,7 +31,6 @@ import biomesoplenty.items.ItemBOPSword;
|
||||||
import biomesoplenty.items.ItemDart;
|
import biomesoplenty.items.ItemDart;
|
||||||
import biomesoplenty.items.ItemDartBlower;
|
import biomesoplenty.items.ItemDartBlower;
|
||||||
import biomesoplenty.items.ItemEnderporter;
|
import biomesoplenty.items.ItemEnderporter;
|
||||||
import biomesoplenty.items.ItemSoulManipulator;
|
|
||||||
|
|
||||||
import com.google.common.base.Optional;
|
import com.google.common.base.Optional;
|
||||||
|
|
||||||
|
@ -110,7 +109,6 @@ public class BOPItems {
|
||||||
Items.mudball = Optional.of(new ItemBOPMudball(BOPConfigurationIDs.mudballID).setUnlocalizedName("bop.mudball"));
|
Items.mudball = Optional.of(new ItemBOPMudball(BOPConfigurationIDs.mudballID).setUnlocalizedName("bop.mudball"));
|
||||||
Items.dartBlower = Optional.of(new ItemDartBlower(BOPConfigurationIDs.dartBlowerID).setUnlocalizedName("bop.dartblower"));
|
Items.dartBlower = Optional.of(new ItemDartBlower(BOPConfigurationIDs.dartBlowerID).setUnlocalizedName("bop.dartblower"));
|
||||||
Items.dart = Optional.of(new ItemDart(BOPConfigurationIDs.dartID).setUnlocalizedName("bop.dart"));
|
Items.dart = Optional.of(new ItemDart(BOPConfigurationIDs.dartID).setUnlocalizedName("bop.dart"));
|
||||||
Items.soulManipulator = Optional.of(new ItemSoulManipulator(BOPConfigurationIDs.soulManipulatorID).setUnlocalizedName("bop.soulManipulator"));
|
|
||||||
|
|
||||||
Items.ancientStaff = Optional.of(new ItemBOPAncientStaff(BOPConfigurationIDs.ancientStaffID).setUnlocalizedName("bop.ancientStaff"));
|
Items.ancientStaff = Optional.of(new ItemBOPAncientStaff(BOPConfigurationIDs.ancientStaffID).setUnlocalizedName("bop.ancientStaff"));
|
||||||
|
|
||||||
|
|
|
@ -101,8 +101,6 @@ public class BOPConfigurationIDs
|
||||||
public static int stoneFormationsID;
|
public static int stoneFormationsID;
|
||||||
|
|
||||||
public static int bonesID;
|
public static int bonesID;
|
||||||
public static int glassID;
|
|
||||||
public static int altarID;
|
|
||||||
public static int graveID;
|
public static int graveID;
|
||||||
|
|
||||||
//Item IDs
|
//Item IDs
|
||||||
|
@ -118,7 +116,6 @@ public class BOPConfigurationIDs
|
||||||
public static int mudballID;
|
public static int mudballID;
|
||||||
public static int dartBlowerID;
|
public static int dartBlowerID;
|
||||||
public static int dartID;
|
public static int dartID;
|
||||||
public static int soulManipulatorID;
|
|
||||||
|
|
||||||
public static int bopBucketID;
|
public static int bopBucketID;
|
||||||
|
|
||||||
|
@ -400,10 +397,6 @@ public class BOPConfigurationIDs
|
||||||
hellBarkStairsID = config.getBlock("Hell Bark Stairs ID", 1976, null).getInt();
|
hellBarkStairsID = config.getBlock("Hell Bark Stairs ID", 1976, null).getInt();
|
||||||
jacarandaStairsID = config.getBlock("Jacaranda ID", 1977, null).getInt();
|
jacarandaStairsID = config.getBlock("Jacaranda ID", 1977, null).getInt();
|
||||||
|
|
||||||
glassID = config.getBlock("Glass ID", 1978, null).getInt();
|
|
||||||
|
|
||||||
altarID = config.getBlock("Altar ID", 1979, null).getInt();
|
|
||||||
|
|
||||||
puddleID = config.getBlock("Puddle ID", 1980, null).getInt();
|
puddleID = config.getBlock("Puddle ID", 1980, null).getInt();
|
||||||
|
|
||||||
graveID = config.getBlock("Grave ID", 1981, null).getInt();
|
graveID = config.getBlock("Grave ID", 1981, null).getInt();
|
||||||
|
@ -460,8 +453,6 @@ public class BOPConfigurationIDs
|
||||||
|
|
||||||
bopBucketID = config.getItem("Spring Water Bucket ID", 21079, null).getInt();
|
bopBucketID = config.getItem("Spring Water Bucket ID", 21079, null).getInt();
|
||||||
|
|
||||||
soulManipulatorID = config.getItem("Soul Manipulator ID", 21080).getInt();
|
|
||||||
|
|
||||||
scytheWoodID = config.getItem("Wood Scythe ID", 21081).getInt();
|
scytheWoodID = config.getItem("Wood Scythe ID", 21081).getInt();
|
||||||
scytheStoneID = config.getItem("Stone Scythe ID", 21082).getInt();
|
scytheStoneID = config.getItem("Stone Scythe ID", 21082).getInt();
|
||||||
scytheIronID = config.getItem("Iron Scythe ID", 21083).getInt();
|
scytheIronID = config.getItem("Iron Scythe ID", 21083).getInt();
|
||||||
|
|
|
@ -18,7 +18,6 @@ public class BOPConfigurationMisc
|
||||||
|
|
||||||
public static boolean amethystTools;
|
public static boolean amethystTools;
|
||||||
public static boolean mudTools;
|
public static boolean mudTools;
|
||||||
public static boolean altarCrafting;
|
|
||||||
public static boolean scytheCrafting;
|
public static boolean scytheCrafting;
|
||||||
public static boolean staffCrafting;
|
public static boolean staffCrafting;
|
||||||
public static boolean enderporterCrafting;
|
public static boolean enderporterCrafting;
|
||||||
|
@ -47,7 +46,6 @@ public class BOPConfigurationMisc
|
||||||
|
|
||||||
amethystTools = config.get("Crafting Settings", "Enable Amethyst Tool/Armor Crafting", true).getBoolean(true);
|
amethystTools = config.get("Crafting Settings", "Enable Amethyst Tool/Armor Crafting", true).getBoolean(true);
|
||||||
mudTools = config.get("Crafting Settings", "Enable Mud Tool/Armor Crafting", true).getBoolean(true);
|
mudTools = config.get("Crafting Settings", "Enable Mud Tool/Armor Crafting", true).getBoolean(true);
|
||||||
altarCrafting = config.get("Crafting Settings", "Enable Altar Items Crafting", true).getBoolean(true);
|
|
||||||
scytheCrafting = config.get("Crafting Settings", "Enable Scythe Crafting", true).getBoolean(true);
|
scytheCrafting = config.get("Crafting Settings", "Enable Scythe Crafting", true).getBoolean(true);
|
||||||
staffCrafting = config.get("Crafting Settings", "Enable Ancient Staff Crafting", true).getBoolean(true);
|
staffCrafting = config.get("Crafting Settings", "Enable Ancient Staff Crafting", true).getBoolean(true);
|
||||||
enderporterCrafting = config.get("Crafting Settings", "Enable Enderporter Crafting", true).getBoolean(true);
|
enderporterCrafting = config.get("Crafting Settings", "Enable Enderporter Crafting", true).getBoolean(true);
|
||||||
|
|
|
@ -125,46 +125,7 @@ public class EntityEventHandler
|
||||||
{
|
{
|
||||||
int itemDamage = itemstack.getItemDamage();
|
int itemDamage = itemstack.getItemDamage();
|
||||||
|
|
||||||
if (itemstack.itemID == Items.soulManipulator.get().itemID && itemstack.getItemDamage() == 2)
|
if (itemstack.itemID == Items.miscItems.get().itemID && (itemDamage == 5 || itemDamage == 6 || itemDamage == 7 || itemDamage == 8 || itemDamage == 9))
|
||||||
{
|
|
||||||
if (entity instanceof EntityEnderman)
|
|
||||||
{
|
|
||||||
EntityEnderman entityenderman = (EntityEnderman)entity;
|
|
||||||
|
|
||||||
if (entityenderman.worldObj.rand.nextInt(2) == 0)
|
|
||||||
{
|
|
||||||
entityenderman.attackEntityFrom(DamageSource.causePlayerDamage(player), 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
entityenderman.attackEntityFrom(DamageSource.causePlayerDamage(player), 0);
|
|
||||||
|
|
||||||
if (entityenderman.worldObj.rand.nextInt(6) == 0)
|
|
||||||
{
|
|
||||||
EntityVillager entityvillager = new EntityVillager(entityenderman.worldObj);
|
|
||||||
entityvillager.setLocationAndAngles(entityenderman.posX, entityenderman.posY, entityenderman.posZ, MathHelper.wrapAngleTo180_float(entityenderman.worldObj.rand.nextFloat() * 360.0F), 0.0F);
|
|
||||||
entityvillager.rotationYawHead = entityvillager.rotationYaw;
|
|
||||||
entityvillager.renderYawOffset = entityvillager.rotationYaw;
|
|
||||||
|
|
||||||
if (!entityenderman.worldObj.isRemote)
|
|
||||||
{
|
|
||||||
entityenderman.worldObj.spawnEntityInWorld(entityvillager);
|
|
||||||
|
|
||||||
FMLClientHandler.instance().getClient().sndManager.playSound("mob.endermen.death", (float) entityvillager.posX + 0.5F, (float) entityvillager.posY + 0.5F, (float) entityvillager.posZ + 0.5F, 5.0F, -8.0F);
|
|
||||||
entityenderman.setDead();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!player.capabilities.isCreativeMode)
|
|
||||||
{
|
|
||||||
itemstack.setItemDamage(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
event.setResult(Result.ALLOW);
|
|
||||||
|
|
||||||
entityvillager.playLivingSound();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (itemstack.itemID == Items.miscItems.get().itemID && (itemDamage == 5 || itemDamage == 6 || itemDamage == 7 || itemDamage == 8 || itemDamage == 9))
|
|
||||||
{
|
{
|
||||||
int dyeMeta = convertToDyeMeta(itemDamage);
|
int dyeMeta = convertToDyeMeta(itemDamage);
|
||||||
int i = BlockColored.getBlockFromDye(dyeMeta);
|
int i = BlockColored.getBlockFromDye(dyeMeta);
|
||||||
|
@ -229,23 +190,6 @@ public class EntityEventHandler
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ForgeSubscribe
|
|
||||||
public void lightningStrike(LivingHurtEvent event)
|
|
||||||
{
|
|
||||||
AxisAlignedBB axisalignedbb = AxisAlignedBB.getAABBPool().getAABB((double)event.entity.posX, (double)event.entity.posY, (double)event.entity.posZ, (double)(event.entity.posX + 1), (double)(event.entity.posY + 1), (double)(event.entity.posZ + 1)).expand(5, 5, 5);
|
|
||||||
|
|
||||||
if (!event.entity.worldObj.getEntitiesWithinAABB(EntityLightningBolt.class, axisalignedbb).isEmpty());
|
|
||||||
{
|
|
||||||
if (!event.entity.worldObj.getEntitiesWithinAABB(EntityPlayer.class, axisalignedbb).isEmpty());
|
|
||||||
{
|
|
||||||
if (isBlockInBB(event.entity.worldObj, axisalignedbb, Blocks.glass.get().blockID, 2) || isBlockInBB(event.entity.worldObj, axisalignedbb, Blocks.glass.get().blockID, 3))
|
|
||||||
{
|
|
||||||
event.setCanceled(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean isBlockInBB(World world, AxisAlignedBB par1AxisAlignedBB, int blockID, int blockMeta)
|
public boolean isBlockInBB(World world, AxisAlignedBB par1AxisAlignedBB, int blockID, int blockMeta)
|
||||||
{
|
{
|
||||||
int i = MathHelper.floor_double(par1AxisAlignedBB.minX);
|
int i = MathHelper.floor_double(par1AxisAlignedBB.minX);
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
package biomesoplenty.itemblocks;
|
|
||||||
|
|
||||||
import net.minecraft.item.ItemBlock;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
|
|
||||||
public class ItemBlockAltar extends ItemBlock
|
|
||||||
{
|
|
||||||
private static final String[] altarTypes = new String[] {"altarframe"};
|
|
||||||
|
|
||||||
public ItemBlockAltar(int par1)
|
|
||||||
{
|
|
||||||
super(par1);
|
|
||||||
setMaxDamage(0);
|
|
||||||
setHasSubtypes(true);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getMetadata(int meta)
|
|
||||||
{
|
|
||||||
return meta & 15;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getUnlocalizedName(ItemStack itemStack)
|
|
||||||
{
|
|
||||||
int meta = itemStack.getItemDamage();
|
|
||||||
if (meta < 0 || meta >= altarTypes.length) {
|
|
||||||
meta = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return super.getUnlocalizedName() + "." + altarTypes[meta];
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,33 +0,0 @@
|
||||||
package biomesoplenty.itemblocks;
|
|
||||||
|
|
||||||
import net.minecraft.item.ItemBlock;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
|
|
||||||
public class ItemBlockGlass extends ItemBlock
|
|
||||||
{
|
|
||||||
private static final String[] glassTypes = new String[] {"celestialLens", "sacrificialfocus_empty", "sacrificialfocus_active", "sacrificialfocus_villager"};
|
|
||||||
|
|
||||||
public ItemBlockGlass(int par1)
|
|
||||||
{
|
|
||||||
super(par1);
|
|
||||||
setMaxDamage(0);
|
|
||||||
setHasSubtypes(true);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public int getMetadata(int meta)
|
|
||||||
{
|
|
||||||
return meta & 15;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getUnlocalizedName(ItemStack itemStack)
|
|
||||||
{
|
|
||||||
int meta = itemStack.getItemDamage();
|
|
||||||
if (meta < 0 || meta >= glassTypes.length) {
|
|
||||||
meta = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return super.getUnlocalizedName() + "." + glassTypes[meta];
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,72 +0,0 @@
|
||||||
package biomesoplenty.items;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import net.minecraft.client.renderer.texture.IconRegister;
|
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
|
||||||
import net.minecraft.item.Item;
|
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.Icon;
|
|
||||||
import biomesoplenty.BiomesOPlenty;
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
|
||||||
|
|
||||||
public class ItemSoulManipulator extends Item
|
|
||||||
{
|
|
||||||
private static String[] manipulatorTypes = {"soulmanipulator_empty", "soulmanipulator_ghastlysoul", "soulmanipulator_villager"};
|
|
||||||
@SideOnly(Side.CLIENT)
|
|
||||||
private Icon[] textures;
|
|
||||||
|
|
||||||
public ItemSoulManipulator(int par1)
|
|
||||||
{
|
|
||||||
super(par1);
|
|
||||||
maxStackSize = 1;
|
|
||||||
setCreativeTab(BiomesOPlenty.tabBiomesOPlenty);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean isFull3D()
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void registerIcons(IconRegister iconRegister)
|
|
||||||
{
|
|
||||||
textures = new Icon[manipulatorTypes.length];
|
|
||||||
|
|
||||||
for (int i = 0; i < manipulatorTypes.length; ++i) {
|
|
||||||
textures[i] = iconRegister.registerIcon("biomesoplenty:"+manipulatorTypes[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getUnlocalizedName(ItemStack itemStack)
|
|
||||||
{
|
|
||||||
int meta = itemStack.getItemDamage();
|
|
||||||
if (meta < 0 || meta >= manipulatorTypes.length) {
|
|
||||||
meta = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return super.getUnlocalizedName() + "." + manipulatorTypes[meta];
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Icon getIconFromDamage(int meta)
|
|
||||||
{
|
|
||||||
if (meta < 0 || meta >= textures.length) {
|
|
||||||
meta = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return textures[meta];
|
|
||||||
}
|
|
||||||
|
|
||||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
|
||||||
@Override
|
|
||||||
public void getSubItems(int itemId, CreativeTabs creativeTab, List subTypes)
|
|
||||||
{
|
|
||||||
for(int meta = 0; meta < manipulatorTypes.length; ++meta) {
|
|
||||||
subTypes.add(new ItemStack(itemId, 1, meta));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,142 +0,0 @@
|
||||||
package biomesoplenty.tileentities;
|
|
||||||
|
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
|
||||||
import net.minecraft.network.INetworkManager;
|
|
||||||
import net.minecraft.network.packet.Packet;
|
|
||||||
import net.minecraft.network.packet.Packet132TileEntityData;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
|
|
||||||
public class TileEntityAltar extends TileEntity
|
|
||||||
{
|
|
||||||
private boolean malachitePresent = false;
|
|
||||||
private boolean peridotPresent = false;
|
|
||||||
private boolean rubyPresent = false;
|
|
||||||
private boolean sapphirePresent = false;
|
|
||||||
private boolean tanzanitePresent = false;
|
|
||||||
private boolean topazPresent = false;
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void readFromNBT(NBTTagCompound nbt)
|
|
||||||
{
|
|
||||||
super.readFromNBT(nbt);
|
|
||||||
this.malachitePresent = nbt.getBoolean("malachitePresent");
|
|
||||||
this.peridotPresent = nbt.getBoolean("peridotPresent");
|
|
||||||
this.rubyPresent = nbt.getBoolean("rubyPresent");
|
|
||||||
this.sapphirePresent = nbt.getBoolean("sapphirePresent");
|
|
||||||
this.tanzanitePresent = nbt.getBoolean("tanzanitePresent");
|
|
||||||
this.topazPresent = nbt.getBoolean("topazPresent");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void writeToNBT(NBTTagCompound nbt)
|
|
||||||
{
|
|
||||||
super.writeToNBT(nbt);
|
|
||||||
nbt.setBoolean("malachitePresent", malachitePresent);
|
|
||||||
nbt.setBoolean("peridotPresent", peridotPresent);
|
|
||||||
nbt.setBoolean("rubyPresent", rubyPresent);
|
|
||||||
nbt.setBoolean("sapphirePresent", sapphirePresent);
|
|
||||||
nbt.setBoolean("tanzanitePresent", tanzanitePresent);
|
|
||||||
nbt.setBoolean("topazPresent", topazPresent);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public Packet getDescriptionPacket()
|
|
||||||
{
|
|
||||||
NBTTagCompound nbt = new NBTTagCompound();
|
|
||||||
|
|
||||||
nbt.setBoolean("malachitePresent", malachitePresent);
|
|
||||||
nbt.setBoolean("peridotPresent", peridotPresent);
|
|
||||||
nbt.setBoolean("rubyPresent", rubyPresent);
|
|
||||||
nbt.setBoolean("sapphirePresent", sapphirePresent);
|
|
||||||
nbt.setBoolean("tanzanitePresent", tanzanitePresent);
|
|
||||||
nbt.setBoolean("topazPresent", topazPresent);
|
|
||||||
|
|
||||||
return new Packet132TileEntityData(this.xCoord, this.yCoord, this.zCoord, 0, nbt);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onDataPacket(INetworkManager var1, Packet132TileEntityData packet)
|
|
||||||
{
|
|
||||||
if (packet.actionType == 0)
|
|
||||||
{
|
|
||||||
this.malachitePresent = packet.data.getBoolean("malachitePresent");
|
|
||||||
this.peridotPresent = packet.data.getBoolean("peridotPresent");
|
|
||||||
this.rubyPresent = packet.data.getBoolean("rubyPresent");
|
|
||||||
this.sapphirePresent = packet.data.getBoolean("sapphirePresent");
|
|
||||||
this.tanzanitePresent = packet.data.getBoolean("tanzanitePresent");
|
|
||||||
this.topazPresent = packet.data.getBoolean("topazPresent");
|
|
||||||
}
|
|
||||||
|
|
||||||
this.worldObj.markBlockForUpdate(packet.xPosition, packet.yPosition, packet.zPosition);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setPresent(int presentGem, boolean state)
|
|
||||||
{
|
|
||||||
if (presentGem == 10)
|
|
||||||
{
|
|
||||||
rubyPresent = state;
|
|
||||||
}
|
|
||||||
else if (presentGem == 11)
|
|
||||||
{
|
|
||||||
peridotPresent = state;
|
|
||||||
}
|
|
||||||
else if (presentGem == 12)
|
|
||||||
{
|
|
||||||
topazPresent = state;
|
|
||||||
}
|
|
||||||
else if (presentGem == 13)
|
|
||||||
{
|
|
||||||
tanzanitePresent = state;
|
|
||||||
}
|
|
||||||
else if (presentGem == 14)
|
|
||||||
{
|
|
||||||
malachitePresent = state;
|
|
||||||
}
|
|
||||||
else if (presentGem == 15)
|
|
||||||
{
|
|
||||||
sapphirePresent = state;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean getPresent(int presentGem)
|
|
||||||
{
|
|
||||||
if (presentGem == 10)
|
|
||||||
{
|
|
||||||
return rubyPresent;
|
|
||||||
}
|
|
||||||
else if (presentGem == 11)
|
|
||||||
{
|
|
||||||
return peridotPresent;
|
|
||||||
}
|
|
||||||
else if (presentGem == 12)
|
|
||||||
{
|
|
||||||
return topazPresent;
|
|
||||||
}
|
|
||||||
else if (presentGem == 13)
|
|
||||||
{
|
|
||||||
return tanzanitePresent;
|
|
||||||
}
|
|
||||||
else if (presentGem == 14)
|
|
||||||
{
|
|
||||||
return malachitePresent;
|
|
||||||
}
|
|
||||||
else if (presentGem == 15)
|
|
||||||
{
|
|
||||||
return sapphirePresent;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean getAllPresent()
|
|
||||||
{
|
|
||||||
if (rubyPresent && peridotPresent && topazPresent && tanzanitePresent && malachitePresent && sapphirePresent)
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -172,14 +172,6 @@ tile.bop.bones.bones_small.name=Small Bone Segment
|
||||||
tile.bop.bones.bones_medium.name=Medium Bone Segment
|
tile.bop.bones.bones_medium.name=Medium Bone Segment
|
||||||
tile.bop.bones.bones_large.name=Large Bone Segment
|
tile.bop.bones.bones_large.name=Large Bone Segment
|
||||||
|
|
||||||
tile.bop.glass.celestialLens.name=Celestial Lens
|
|
||||||
|
|
||||||
tile.bop.glass.sacrificialfocus_empty.name=Sacrificial Focus
|
|
||||||
tile.bop.glass.sacrificialfocus_active.name=Sacrificial Focus
|
|
||||||
tile.bop.glass.sacrificialfocus_villager.name=Sacrificial Focus
|
|
||||||
|
|
||||||
tile.bop.altar.altarframe.name=Altar Frame
|
|
||||||
|
|
||||||
tile.bop.puddle.name=Puddle
|
tile.bop.puddle.name=Puddle
|
||||||
|
|
||||||
tile.bop.grave.name=Gravestone
|
tile.bop.grave.name=Gravestone
|
||||||
|
@ -363,10 +355,6 @@ item.bop.ancientStaff.staffpole.name=Ancient Staff Pole
|
||||||
item.bop.ancientStaff.stafftopper.name=Ancient Staff Topper
|
item.bop.ancientStaff.stafftopper.name=Ancient Staff Topper
|
||||||
item.bop.ancientStaff.ancientstaffbroken.name=Depleted Ancient Staff
|
item.bop.ancientStaff.ancientstaffbroken.name=Depleted Ancient Staff
|
||||||
|
|
||||||
item.bop.soulManipulator.soulmanipulator_empty.name=Soul Manipulator
|
|
||||||
item.bop.soulManipulator.soulmanipulator_ghastlysoul.name=Ghastly Soul Manipulator
|
|
||||||
item.bop.soulManipulator.soulmanipulator_villager.name=Villager Soul Manipulator
|
|
||||||
|
|
||||||
item.bop.enderporter.name=Enderporter
|
item.bop.enderporter.name=Enderporter
|
||||||
|
|
||||||
item.bop.bopDisc.name=Music Disc
|
item.bop.bopDisc.name=Music Disc
|
||||||
|
|
Loading…
Reference in New Issue