diff --git a/.gitignore b/.gitignore index da50a65..9b52529 100644 --- a/.gitignore +++ b/.gitignore @@ -1,220 +1,13 @@ -################# -## Eclipse -################# +/common/* -*.pydevproject -.project -.metadata -common/bin/ -tmp/ -*.tmp -*.bak -*.swp -*~.nib -local.properties -.classpath -.settings/ -.loadpath - -# External tool builders -.externalToolBuilders/ - -# Locally stored "Eclipse launch configurations" -*.launch - -# CDT-specific -.cproject - -# PDT-specific -.buildpath - - -################# -## Visual Studio -################# - -## Ignore Visual Studio temporary files, build results, and -## files generated by popular Visual Studio add-ons. - -# User-specific files -*.suo -*.user -*.sln.docstates - -# Build results - -[Dd]ebug/ -[Rr]elease/ -x64/ -build/ -[Bb]in/ -[Oo]bj/ - -# MSTest test Results -[Tt]est[Rr]esult*/ -[Bb]uild[Ll]og.* - -*_i.c -*_p.c -*.ilk -*.meta -*.obj -*.pch -*.pdb -*.pgc -*.pgd -*.rsp -*.sbr -*.tlb -*.tli -*.tlh -*.tmp -*.tmp_proj -*.log -*.vspscc -*.vssscc -.builds -*.pidb -*.log -*.scc - -# Visual C++ cache files -ipch/ -*.aps -*.ncb -*.opensdf -*.sdf -*.cachefile - -# Visual Studio profiler -*.psess -*.vsp -*.vspx - -# Guidance Automation Toolkit -*.gpState - -# ReSharper is a .NET coding add-in -_ReSharper*/ -*.[Rr]e[Ss]harper - -# TeamCity is a build add-in -_TeamCity* - -# DotCover is a Code Coverage Tool -*.dotCover - -# NCrunch -*.ncrunch* -.*crunch*.local.xml - -# Installshield output folder -[Ee]xpress/ - -# DocProject is a documentation generator add-in -DocProject/buildhelp/ -DocProject/Help/*.HxT -DocProject/Help/*.HxC -DocProject/Help/*.hhc -DocProject/Help/*.hhk -DocProject/Help/*.hhp -DocProject/Help/Html2 -DocProject/Help/html - -# Click-Once directory -publish/ - -# Publish Web Output -*.Publish.xml -*.pubxml - -# NuGet Packages Directory -## TODO: If you have NuGet Package Restore enabled, uncomment the next line -#packages/ - -# Windows Azure Build Output -csx -*.build.csdef - -# Windows Store app package directory -AppPackages/ - -# Others -sql/ -*.Cache -ClientBin/ -[Ss]tyle[Cc]op.* -~$* -*~ -*.dbmdl -*.[Pp]ublish.xml -*.pfx -*.publishsettings - -# RIA/Silverlight projects -Generated_Code/ - -# Backup & report files from converting an old project file to a newer -# Visual Studio version. Backup files are not needed, because we have git ;-) -_UpgradeReport_Files/ -Backup*/ -UpgradeLog*.XML -UpgradeLog*.htm - -# SQL Server files -App_Data/*.mdf -App_Data/*.ldf - -############# -## Windows detritus -############# - -# Windows image file caches -Thumbs.db -ehthumbs.db - -# Folder config file -Desktop.ini - -# Recycle Bin used on file shares -$RECYCLE.BIN/ - -# Mac crap -.DS_Store - - -############# -## Python -############# - -*.py[co] - -# Packages -*.egg -*.egg-info -dist/ -build/ -eggs/ -parts/ -var/ -sdist/ -develop-eggs/ -.installed.cfg - -# Installer logs -pip-log.txt - -# Unit test / coverage reports -.coverage -.tox - -#Translations -*.mo - -#Mr Developer -.mr.developer.cfg - -/mcp/* -/eclipse/* -/api/* -/releases/* +!.gitignore +!*LICENSE.md +!README.md +!common/assets/ +!common/mysticores/ +!common/mysticruins/ +!common/mysticstones/ +!common/mysticworld/ +!common/mcmod.info +!common/build.gradle +!common/gradle* \ No newline at end of file diff --git a/MysticMods.iml b/MysticMods.iml new file mode 100644 index 0000000..d5cea56 --- /dev/null +++ b/MysticMods.iml @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/common/MysticMods.eml b/common/MysticMods.eml new file mode 100644 index 0000000..70f162e --- /dev/null +++ b/common/MysticMods.eml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/common/MysticMods_common.iml b/common/MysticMods_common.iml new file mode 100644 index 0000000..9ef36fb --- /dev/null +++ b/common/MysticMods_common.iml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/common/MysticOres/Blocks/BlockBase.java b/common/MysticOres/Blocks/BlockBase.java index ccd85f0..75b4865 100644 --- a/common/MysticOres/Blocks/BlockBase.java +++ b/common/MysticOres/Blocks/BlockBase.java @@ -1,31 +1,37 @@ package mysticores.blocks; -import java.util.List; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticores.MysticOres; import mysticores.items.Items; import net.minecraft.block.Block; import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.Entity; +import net.minecraft.init.Blocks; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.Facing; +import net.minecraft.util.IIcon; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; -import net.minecraftforge.common.ForgeDirection; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; +import net.minecraftforge.common.util.ForgeDirection; + +import java.util.List; +import java.util.Random; public class BlockBase extends Block { - Icon[] textures; + IIcon[] textures; - public BlockBase(int ID) { - super(ID, Material.rock); - setCreativeTab(MysticOres.MysticOresTab); + public BlockBase() { + super(Material.rock); + setCreativeTab(MysticOres.MysticOresTab); + setHarvestLevel("pickaxe", 2); + setHarvestLevel("pickaxe", 3, 0); + setHarvestLevel("pickaxe", 3, 2); + setHarvestLevel("pickaxe", 1, 6); } @Override @@ -74,7 +80,7 @@ public class BlockBase extends Block { @Override @SideOnly(Side.CLIENT) - public Icon getIcon(int side, int meta) { + public IIcon getIcon(int side, int meta) { return textures[meta]; } @@ -95,14 +101,14 @@ public class BlockBase extends Block { @Override @SideOnly(Side.CLIENT) - public void getSubBlocks(int i, CreativeTabs tab, List list) { - for (int meta = 0; meta < ItemBase.BLOCK_NAMES.length; meta++) { + public void getSubBlocks(Item i, CreativeTabs tab, List list) { + for (int meta = 0; meta < BlockHandler.BLOCK_NAMES.size(); meta++) { list.add(new ItemStack(i, 1, meta)); } } @Override - public int idDropped(int par1, Random random, int par3) { + public Item getItemDropped(int par1, Random random, int par3) { switch (par1) { case 1: case 2: @@ -111,25 +117,20 @@ public class BlockBase extends Block { case 7: case 11: case 12: - return Items.Resource.itemID; + return Items.Resource; case 8: - return this.BlackSoulstoneDrops(par1, random, par3); + return BlackSoulstoneDrops(par1, random, par3); case 9: - return this.BlueSoulstoneDrops(par1, random, par3); + return BlueSoulstoneDrops(par1, random, par3); case 10: - return this.RedSoulstoneDrops(par1, random, par3); + return RedSoulstoneDrops(par1, random, par3); default: - return blockID; + return super.getItemDropped(par1, random, par3); } } @Override - public int idPicked(World world, int x, int y, int z) { - return this.blockID; - } - - @Override - public boolean isBlockSolidOnSide(World world, int x, int y, int z, ForgeDirection side) { + public boolean isSideSolid(IBlockAccess world, int x, int y, int z, ForgeDirection side) { int meta = world.getBlockMetadata(x, y, z); if (meta == 12) return false; @@ -138,9 +139,9 @@ public class BlockBase extends Block { } @Override - public boolean isOpaqueCube() { - return false; - } + public boolean isOpaqueCube(){ + return false; + } @Override public int quantityDropped(int meta, int fortune, Random random) { @@ -164,79 +165,72 @@ public class BlockBase extends Block { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister register) { - textures = new Icon[16]; - for (int i = 0; i < ItemBase.BLOCK_NAMES.length; i++) { - textures[i] = register.registerIcon("MysticMods:" + ItemBase.BLOCK_NAMES[i]); + public void registerBlockIcons(IIconRegister register) { + textures = new IIcon[16]; + for (int i = 0; i < BlockHandler.BLOCK_NAMES.size(); i++) { + textures[i] = register.registerIcon("mysticores:" + BlockHandler.BLOCK_NAMES.get(i)); } } @Override - public boolean renderAsNormalBlock() { - return false; - } + public boolean renderAsNormalBlock(){ + return false; + } @Override @SideOnly(Side.CLIENT) - public boolean shouldSideBeRendered(IBlockAccess world, int x, int y, int z, int par) { + public boolean shouldSideBeRendered(IBlockAccess world, int x, int y, int z, int side) { int meta = world.getBlockMetadata(x, y, z); - int blockID = world.getBlockId(x, y, z); - if (meta == 12 && blockID == this.blockID) - return false; - else + if (meta == 12 && world.getBlock(x, y, z) == this){ + return !(world.getBlock(x-Facing.offsetsXForSide[side], y-Facing.offsetsYForSide[side], z-Facing.offsetsZForSide[side])==this&&world.getBlockMetadata(x-Facing.offsetsXForSide[side], y-Facing.offsetsYForSide[side], z-Facing.offsetsZForSide[side])==meta); + }else return true; } - @Override - protected boolean canSilkHarvest() { - return true; - } - - public static int BlackSoulstoneDrops(int par1, Random random, int par3) { + public static Item BlackSoulstoneDrops(int par1, Random random, int par3) { int rand = random.nextInt(2); switch (rand) { case 0: - return Item.coal.itemID; + return net.minecraft.init.Items.coal; case 1: - return Item.gunpowder.itemID; + return net.minecraft.init.Items.gunpowder; default: - return Item.sugar.itemID; + return net.minecraft.init.Items.sugar; } } - public static int BlueSoulstoneDrops(int par1, Random random, int par3) { + public static Item BlueSoulstoneDrops(int par1, Random random, int par3) { int rand = random.nextInt(5); switch (rand) { case 0: - return Item.diamond.itemID; + return net.minecraft.init.Items.diamond; case 1: - return Block.obsidian.blockID; + return Item.getItemFromBlock(Blocks.obsidian); case 2: - return Item.gunpowder.itemID; + return net.minecraft.init.Items.gunpowder; case 3: - return Item.glowstone.itemID; + return net.minecraft.init.Items.glowstone_dust; case 4: - return Item.blazeRod.itemID; + return net.minecraft.init.Items.blaze_rod; case 5: - return Item.emerald.itemID; default: - return Item.emerald.itemID; + return net.minecraft.init.Items.emerald; } } - public static int RedSoulstoneDrops(int par1, Random random, int par3) { + public static Item RedSoulstoneDrops(int par1, Random random, int par3) { int rand = random.nextInt(4); switch (rand) { case 0: - return Item.glowstone.itemID; + return net.minecraft.init.Items.glowstone_dust; case 1: - return Item.gunpowder.itemID; + return net.minecraft.init.Items.gunpowder; case 2: - return Item.redstone.itemID; + return net.minecraft.init.Items.redstone; case 3: - return Block.obsidian.blockID; + return Item.getItemFromBlock(Blocks.obsidian); default: - return Item.blazePowder.itemID; + return net.minecraft.init.Items.blaze_powder; } } } \ No newline at end of file diff --git a/common/MysticOres/Blocks/BlockHandler.java b/common/MysticOres/Blocks/BlockHandler.java index 3cde9ab..4658dbd 100644 --- a/common/MysticOres/Blocks/BlockHandler.java +++ b/common/MysticOres/Blocks/BlockHandler.java @@ -1,31 +1,17 @@ package mysticores.blocks; -import net.minecraft.block.Block; -import net.minecraftforge.common.MinecraftForge; import cpw.mods.fml.common.registry.GameRegistry; +import net.minecraft.block.Block; + +import java.util.ArrayList; +import java.util.Arrays; public class BlockHandler { + public static final ArrayList BLOCK_NAMES = new ArrayList(Arrays.asList("Adamantine Ore", "Amethyst Ore", "Iridium Ore", "Mithril Ore", "Tourmaline Ore", "Topaz Ore", "Verdite Ore", "Bloodstone", "Black Soulstone", + "Blue Soulstone", "Red Soulstone", "Agate Ore", "Tempered Glass")); public static Block BlockBase; - public static int BASEID = 540; public static void initialize() { - BlockBase = new BlockBase(BASEID).setStepSound(Block.soundStoneFootstep); - GameRegistry.registerBlock(BlockBase, ItemBase.class, "Base Blocks"); - setBlockHarvestLevels(); - } - - private static void setBlockHarvestLevels() { - MinecraftForge.setBlockHarvestLevel(BlockBase, 0, "pickaxe", 3); - MinecraftForge.setBlockHarvestLevel(BlockBase, 1, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 2, "pickaxe", 3); - MinecraftForge.setBlockHarvestLevel(BlockBase, 3, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 4, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 5, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 6, "pickaxe", 1); - MinecraftForge.setBlockHarvestLevel(BlockBase, 7, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 8, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 9, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 10, "pickaxe", 2); - MinecraftForge.setBlockHarvestLevel(BlockBase, 11, "pickaxe", 2); + BlockBase = GameRegistry.registerBlock(new BlockBase().setStepSound(Block.soundTypeStone), ItemBase.class, "Base Blocks", BLOCK_NAMES); } } diff --git a/common/MysticOres/Blocks/ItemBase.java b/common/MysticOres/Blocks/ItemBase.java index f512101..6d11b8d 100644 --- a/common/MysticOres/Blocks/ItemBase.java +++ b/common/MysticOres/Blocks/ItemBase.java @@ -1,36 +1,22 @@ package mysticores.blocks; -import net.minecraft.item.ItemBlock; +import net.minecraft.block.Block; +import net.minecraft.item.ItemBlockWithMetadata; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -public class ItemBase extends ItemBlock { - public static String[] BLOCK_NAMES = new String[] { "Adamantine Ore", "Amethyst Ore", "Iridium Ore", "Mithril Ore", "Tourmaline Ore", "Topaz Ore", "Verdite Ore", "Bloodstone", "Black Soulstone", - "Blue Soulstone", "Red Soulstone", "Agate Ore", "Tempered Glass" }; +import java.util.ArrayList; - public ItemBase(int par1) { - super(par1); - setMaxDamage(0); - setHasSubtypes(true); - } - - @Override - @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int par1) { - return BlockHandler.BlockBase.getIcon(2, par1); - } - - @Override - public int getMetadata(int par1) { - return par1; +public class ItemBase extends ItemBlockWithMetadata { + public final ArrayList names; + public ItemBase(Block block, ArrayList names) { + super(block, block); + this.names = names; } @Override public String getUnlocalizedName(ItemStack itemStack) { - int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, BLOCK_NAMES.length); - return BLOCK_NAMES[meta]; + int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, names.size()); + return names.get(meta); } } diff --git a/common/MysticOres/Items/EnumTools.java b/common/MysticOres/Items/EnumTools.java index 7075a00..1bb53e4 100644 --- a/common/MysticOres/Items/EnumTools.java +++ b/common/MysticOres/Items/EnumTools.java @@ -1,24 +1,24 @@ package mysticores.items; -import net.minecraft.block.Block; -import net.minecraft.item.EnumToolMaterial; +import net.minecraft.init.Blocks; import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraftforge.common.EnumHelper; +import net.minecraftforge.common.util.EnumHelper; public class EnumTools { - static EnumToolMaterial verditeToolMaterial = EnumHelper.addToolMaterial("Verdite", 1, 262, 5.0F, 1, 5); - static EnumToolMaterial mithrilToolMaterial = EnumHelper.addToolMaterial("Mithril", 2, 500, 7.0F, 2, 9); - static EnumToolMaterial adamantineToolMaterial = EnumHelper.addToolMaterial("Adamantine", 3, 3000, 10.0F, 5, 13); - static EnumToolMaterial iridiumToolMaterial = EnumHelper.addToolMaterial("Iridium", 3, 4000, 12.0F, 7, 15); - static EnumToolMaterial obsidianToolMaterial = EnumHelper.addToolMaterial("Obsidian", 2, 100, 4.0F, 6, 11); - static EnumToolMaterial bloodstoneToolMaterial = EnumHelper.addToolMaterial("Bloodstone", 3, 200, 16.0F, 8, 12); + public static final Item.ToolMaterial verditeToolMaterial = EnumHelper.addToolMaterial("Verdite", 1, 262, 5.0F, 1, 5); + public static final Item.ToolMaterial mithrilToolMaterial = EnumHelper.addToolMaterial("Mithril", 2, 500, 7.0F, 2, 9); + public static final Item.ToolMaterial adamantineToolMaterial = EnumHelper.addToolMaterial("Adamantine", 3, 3000, 10.0F, 5, 13); + public static final Item.ToolMaterial iridiumToolMaterial = EnumHelper.addToolMaterial("Iridium", 3, 4000, 12.0F, 7, 15); + public static final Item.ToolMaterial obsidianToolMaterial = EnumHelper.addToolMaterial("Obsidian", 2, 100, 4.0F, 6, 11); + public static final Item.ToolMaterial bloodstoneToolMaterial = EnumHelper.addToolMaterial("Bloodstone", 3, 200, 16.0F, 8, 12); - static { verditeToolMaterial.customCraftingMaterial = Item.itemsList[Items.Resource.itemID]; } - static { mithrilToolMaterial.customCraftingMaterial = Item.itemsList[Items.Resource.itemID]; } - static { adamantineToolMaterial.customCraftingMaterial = Item.itemsList[Items.Resource.itemID]; } - static { iridiumToolMaterial.customCraftingMaterial = Item.itemsList[Items.Resource.itemID]; } - static { obsidianToolMaterial.customCraftingMaterial = Item.itemsList[Block.obsidian.blockID]; } - static { bloodstoneToolMaterial.customCraftingMaterial = Item.itemsList[Items.Resource.itemID]; } + static { + verditeToolMaterial.customCraftingMaterial = Items.Resource; + mithrilToolMaterial.customCraftingMaterial = Items.Resource; + adamantineToolMaterial.customCraftingMaterial = Items.Resource; + iridiumToolMaterial.customCraftingMaterial = Items.Resource; + obsidianToolMaterial.customCraftingMaterial = Item.getItemFromBlock(Blocks.obsidian); + bloodstoneToolMaterial.customCraftingMaterial = Items.Resource; + } } diff --git a/common/MysticOres/Items/ItemAxes.java b/common/MysticOres/Items/ItemAxes.java deleted file mode 100644 index 6f46021..0000000 --- a/common/MysticOres/Items/ItemAxes.java +++ /dev/null @@ -1,18 +0,0 @@ -package mysticores.items; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemAxe; - -public class ItemAxes extends ItemAxe { - public ItemAxes(int par1, EnumToolMaterial par2EnumToolMaterial) { - super(par1, par2EnumToolMaterial); - setCreativeTab(MysticOres.MysticOresTab); - } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } -} diff --git a/common/MysticOres/Items/ItemHoes.java b/common/MysticOres/Items/ItemHoes.java deleted file mode 100644 index c08e3a9..0000000 --- a/common/MysticOres/Items/ItemHoes.java +++ /dev/null @@ -1,18 +0,0 @@ -package mysticores.items; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemHoe; - -public class ItemHoes extends ItemHoe { - public ItemHoes(int par1, EnumToolMaterial par2EnumToolMaterial) { - super(par1, par2EnumToolMaterial); - this.setCreativeTab(MysticOres.MysticOresTab); - } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } -} diff --git a/common/MysticOres/Items/ItemPickaxes.java b/common/MysticOres/Items/ItemPickaxes.java deleted file mode 100644 index da669cc..0000000 --- a/common/MysticOres/Items/ItemPickaxes.java +++ /dev/null @@ -1,18 +0,0 @@ -package mysticores.items; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemPickaxe; - -public class ItemPickaxes extends ItemPickaxe { - public ItemPickaxes(int par1, EnumToolMaterial par2EnumToolMaterial) { - super(par1, par2EnumToolMaterial); - this.setCreativeTab(MysticOres.MysticOresTab); - } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } -} diff --git a/common/MysticOres/Items/ItemResource.java b/common/MysticOres/Items/ItemResource.java index efaa710..17b3abf 100644 --- a/common/MysticOres/Items/ItemResource.java +++ b/common/MysticOres/Items/ItemResource.java @@ -1,38 +1,36 @@ package mysticores.items; -import java.util.List; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; public class ItemResource extends Item { - private Icon[] icons; + private IIcon[] icons; private static final String[] RESOURCE_TYPES = new String[] { "Verdite Ingot", "Mithril Ingot", "Adamantine Ingot", "Iridium Ingot", "Iridium Nugget", "Tourmaline Gem", "Agate Gem", "Topaz Gem", "Amethyst Gem", "Mystic Powder", "Bloodstone Shard", "Glass Shard", "Obsidian Shard", "Obsidian Rod" }; - public ItemResource(int id) { - super(id); + public ItemResource() { + super(); this.setHasSubtypes(true); - this.setCreativeTab(MysticOres.MysticOresTab); } @Override @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int meta) { + public IIcon getIconFromDamage(int meta) { int j = MathHelper.clamp_int(meta, 0, RESOURCE_TYPES.length); return icons[j]; } @Override @SideOnly(Side.CLIENT) - public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List) { + public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List) { for (int var4 = 0; var4 < RESOURCE_TYPES.length; var4++) par3List.add(new ItemStack(par1, 1, var4)); } @@ -45,9 +43,9 @@ public class ItemResource extends Item { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - icons = new Icon[RESOURCE_TYPES.length]; + public void registerIcons(IIconRegister iconRegister) { + icons = new IIcon[RESOURCE_TYPES.length]; for (int i = 0; i < RESOURCE_TYPES.length; ++i) - icons[i] = iconRegister.registerIcon("MysticMods:" + RESOURCE_TYPES[i]); + icons[i] = iconRegister.registerIcon("mysticores:" + RESOURCE_TYPES[i]); } } diff --git a/common/MysticOres/Items/ItemSatchel.java b/common/MysticOres/Items/ItemSatchel.java index 13e44e2..3d88cc5 100644 --- a/common/MysticOres/Items/ItemSatchel.java +++ b/common/MysticOres/Items/ItemSatchel.java @@ -1,40 +1,28 @@ package mysticores.items; -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.inventory.IInventory; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; public class ItemSatchel extends Item { - public ItemSatchel(int par1) { - super(par1); - setCreativeTab(MysticOres.MysticOresTab); - maxStackSize = 1; + public ItemSatchel() { + super(); } @Override @SideOnly(Side.CLIENT) - public boolean hasEffect(ItemStack par1ItemStack) { + public boolean hasEffect(ItemStack par1ItemStack, int i) { return true; } @Override public ItemStack onItemRightClick(ItemStack is, World world, EntityPlayer player) { if (!player.isSneaking()) { - IInventory inv; - inv = player.getInventoryEnderChest(); - player.displayGUIChest(inv); + player.displayGUIChest(player.getInventoryEnderChest()); } return is; } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } } diff --git a/common/MysticOres/Items/ItemShovels.java b/common/MysticOres/Items/ItemShovels.java deleted file mode 100644 index 7020991..0000000 --- a/common/MysticOres/Items/ItemShovels.java +++ /dev/null @@ -1,18 +0,0 @@ -package mysticores.items; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemSpade; - -public class ItemShovels extends ItemSpade { - public ItemShovels(int par1, EnumToolMaterial par2EnumToolMaterial) { - super(par1, par2EnumToolMaterial); - this.setCreativeTab(MysticOres.MysticOresTab); - } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } -} diff --git a/common/MysticOres/Items/ItemSwords.java b/common/MysticOres/Items/ItemSwords.java deleted file mode 100644 index 0cdc1f0..0000000 --- a/common/MysticOres/Items/ItemSwords.java +++ /dev/null @@ -1,18 +0,0 @@ -package mysticores.items; - -import mysticores.MysticOres; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemSword; - -public class ItemSwords extends ItemSword { - public ItemSwords(int par1, EnumToolMaterial par2EnumToolMaterial) { - super(par1, par2EnumToolMaterial); - setCreativeTab(MysticOres.MysticOresTab); - } - - @Override - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods" + ":" + this.getUnlocalizedName().substring(this.getUnlocalizedName().indexOf(".") + 1)); - } -} \ No newline at end of file diff --git a/common/MysticOres/Items/Items.java b/common/MysticOres/Items/Items.java index 62c523f..08ca594 100644 --- a/common/MysticOres/Items/Items.java +++ b/common/MysticOres/Items/Items.java @@ -1,74 +1,66 @@ package mysticores.items; -import mysticores.lib.ItemID; +import cpw.mods.fml.common.registry.GameRegistry; +import mysticores.MysticOres; import net.minecraft.item.Item; +import net.minecraft.item.ItemHoe; +import net.minecraft.item.ItemSpade; +import net.minecraft.item.ItemSword; + +import java.lang.reflect.Field; public class Items { - public static Item VerditeSword; - public static Item VerditePickaxe; - public static Item VerditeShovel; - public static Item VerditeAxe; - public static Item VerditeHoe; - public static Item MithrilSword; - public static Item MithrilPickaxe; - public static Item MithrilShovel; - public static Item MithrilAxe; - public static Item MithrilHoe; - public static Item AdamantineSword; - public static Item AdamantinePickaxe; - public static Item AdamantineShovel; - public static Item AdamantineAxe; - public static Item AdamantineHoe; - public static Item IridiumSword; - public static Item IridiumPickaxe; - public static Item IridiumShovel; - public static Item IridiumAxe; - public static Item IridiumHoe; - public static Item BloodstoneSword; - public static Item BloodstonePickaxe; - public static Item BloodstoneShovel; - public static Item BloodstoneAxe; - public static Item BloodstoneHoe; - public static Item ObsidianSword; - public static Item ObsidianPickaxe; - public static Item ObsidianShovel; - public static Item ObsidianAxe; - public static Item ObsidianHoe; + public static Item VerditeSword, VerditePickaxe, VerditeShovel, VerditeAxe, VerditeHoe; + public static Item MithrilSword, MithrilPickaxe, MithrilShovel, MithrilAxe, MithrilHoe; + public static Item AdamantineSword, AdamantinePickaxe, AdamantineShovel, AdamantineAxe, AdamantineHoe; + public static Item IridiumSword, IridiumPickaxe, IridiumShovel, IridiumAxe, IridiumHoe; + public static Item BloodstoneSword, BloodstonePickaxe, BloodstoneShovel, BloodstoneAxe, BloodstoneHoe; + public static Item ObsidianSword, ObsidianPickaxe, ObsidianShovel, ObsidianAxe, ObsidianHoe; public static Item Resource; public static Item Satchel; public static void initialize() { - Resource = new ItemResource(ItemID.RESOURCES); - VerditeSword = new ItemSwords(ItemID.VERDITESWORD, EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeSword"); - VerditePickaxe = new ItemPickaxes(ItemID.VERDITEPICKAXE, EnumTools.verditeToolMaterial).setUnlocalizedName("VerditePickaxe"); - VerditeShovel = new ItemShovels(ItemID.VERDITESHOVEL, EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeShovel"); - VerditeAxe = new ItemAxes(ItemID.VERDITEAXE, EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeAxe"); - VerditeHoe = new ItemHoes(ItemID.VERDITEHOE, EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeHoe"); - MithrilSword = new ItemSwords(ItemID.MITHRILSWORD, EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilSword"); - MithrilPickaxe = new ItemPickaxes(ItemID.MITHRILPICKAXE, EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilPickaxe"); - MithrilShovel = new ItemShovels(ItemID.MITHRILSHOVEL, EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilShovel"); - MithrilAxe = new ItemAxes(ItemID.MITHRILAXE, EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilAxe"); - MithrilHoe = new ItemHoes(ItemID.MITHRILHOE, EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilHoe"); - AdamantineSword = new ItemSwords(ItemID.ADAMANTINESWORD, EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineSword"); - AdamantinePickaxe = new ItemPickaxes(ItemID.ADAMANTINEPICKAXE, EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantinePickaxe"); - AdamantineShovel = new ItemShovels(ItemID.ADAMANTINESHOVEL, EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineShovel"); - AdamantineAxe = new ItemAxes(ItemID.ADAMANTINEAXE, EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineAxe"); - AdamantineHoe = new ItemHoes(ItemID.ADAMANTINEHOE, EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineHoe"); - IridiumSword = new ItemSwords(ItemID.IRIDIUMSWORD, EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumSword"); - IridiumPickaxe = new ItemPickaxes(ItemID.IRIDIUMPICKAXE, EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumPickaxe"); - IridiumShovel = new ItemShovels(ItemID.IRIDIUMSHOVEL, EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumShovel"); - IridiumAxe = new ItemAxes(ItemID.IRIDIUMAXE, EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumAxe"); - IridiumHoe = new ItemHoes(ItemID.IRIDIUMHOE, EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumHoe"); - BloodstoneSword = new ItemSwords(ItemID.BLOODSTONESWORD, EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneSword"); - BloodstonePickaxe = new ItemPickaxes(ItemID.BLOODSTONEPICKAXE, EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstonePickaxe"); - BloodstoneShovel = new ItemShovels(ItemID.BLOODSTONESHOVEL, EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneShovel"); - BloodstoneAxe = new ItemAxes(ItemID.BLOODSTONEAXE, EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneAxe"); - BloodstoneHoe = new ItemHoes(ItemID.BLOODSTONEHOE, EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneHoe"); - ObsidianSword = new ItemSwords(ItemID.OBSIDIANSWORD, EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianSword"); - ObsidianPickaxe = new ItemPickaxes(ItemID.OBSIDIANPICKAXE, EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianPickaxe"); - ObsidianShovel = new ItemShovels(ItemID.OBSIDIANSHOVEL, EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianShovel"); - ObsidianAxe = new ItemAxes(ItemID.OBSIDIANAXE, EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianAxe"); - ObsidianHoe = new ItemHoes(ItemID.OBSIDIANHOE, EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianHoe"); - Satchel = new ItemSatchel(ItemID.SATCHEL).setUnlocalizedName("Satchel"); + Resource = new ItemResource().setUnlocalizedName("Resources"); + VerditeSword = new ItemSword(EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeSword"); + VerditePickaxe = new ItemPick(EnumTools.verditeToolMaterial).setUnlocalizedName("VerditePickaxe"); + VerditeShovel = new ItemSpade(EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeShovel"); + VerditeAxe = new ItemHatchet(EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeAxe"); + VerditeHoe = new ItemHoe(EnumTools.verditeToolMaterial).setUnlocalizedName("VerditeHoe"); + MithrilSword = new ItemSword(EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilSword"); + MithrilPickaxe = new ItemPick(EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilPickaxe"); + MithrilShovel = new ItemSpade(EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilShovel"); + MithrilAxe = new ItemHatchet(EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilAxe"); + MithrilHoe = new ItemHoe(EnumTools.mithrilToolMaterial).setUnlocalizedName("MithrilHoe"); + AdamantineSword = new ItemSword(EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineSword"); + AdamantinePickaxe = new ItemPick(EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantinePickaxe"); + AdamantineShovel = new ItemSpade(EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineShovel"); + AdamantineAxe = new ItemHatchet(EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineAxe"); + AdamantineHoe = new ItemHoe(EnumTools.adamantineToolMaterial).setUnlocalizedName("AdamantineHoe"); + IridiumSword = new ItemSword(EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumSword"); + IridiumPickaxe = new ItemPick(EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumPickaxe"); + IridiumShovel = new ItemSpade(EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumShovel"); + IridiumAxe = new ItemHatchet(EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumAxe"); + IridiumHoe = new ItemHoe(EnumTools.iridiumToolMaterial).setUnlocalizedName("IridiumHoe"); + BloodstoneSword = new ItemSword(EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneSword"); + BloodstonePickaxe = new ItemPick(EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstonePickaxe"); + BloodstoneShovel = new ItemSpade(EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneShovel"); + BloodstoneAxe = new ItemHatchet(EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneAxe"); + BloodstoneHoe = new ItemHoe(EnumTools.bloodstoneToolMaterial).setUnlocalizedName("BloodstoneHoe"); + ObsidianSword = new ItemSword(EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianSword"); + ObsidianPickaxe = new ItemPick(EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianPickaxe"); + ObsidianShovel = new ItemSpade(EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianShovel"); + ObsidianAxe = new ItemHatchet(EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianAxe"); + ObsidianHoe = new ItemHoe(EnumTools.obsidianToolMaterial).setUnlocalizedName("ObsidianHoe"); + Satchel = new ItemSatchel().setMaxStackSize(1).setUnlocalizedName("Satchel"); + try { + for(Field f:Items.class.getFields()){ + Item it = (Item) f.get(null); + it.setCreativeTab(MysticOres.MysticOresTab); + String reg = it.getUnlocalizedName().substring(5); + it.setTextureName("mysticores:"+reg); + GameRegistry.registerItem(it,reg); + } + } catch (Exception e) { + } } } diff --git a/common/MysticOres/Lib/ItemID.java b/common/MysticOres/Lib/ItemID.java deleted file mode 100644 index 0feb4c1..0000000 --- a/common/MysticOres/Lib/ItemID.java +++ /dev/null @@ -1,36 +0,0 @@ -package mysticores.lib; - -public class ItemID { - public static int VERDITESWORD = 7050; - public static int VERDITEPICKAXE = 7051; - public static int VERDITESHOVEL = 7052; - public static int VERDITEAXE = 7053; - public static int VERDITEHOE = 7054; - public static int MITHRILSWORD = 7055; - public static int MITHRILPICKAXE = 7056; - public static int MITHRILSHOVEL = 7057; - public static int MITHRILAXE = 7058; - public static int MITHRILHOE = 7059; - public static int ADAMANTINESWORD = 7060; - public static int ADAMANTINEPICKAXE = 7061; - public static int ADAMANTINESHOVEL = 7062; - public static int ADAMANTINEAXE = 7063; - public static int ADAMANTINEHOE = 7064; - public static int IRIDIUMSWORD = 7065; - public static int IRIDIUMPICKAXE = 7066; - public static int IRIDIUMSHOVEL = 7067; - public static int IRIDIUMAXE = 7068; - public static int IRIDIUMHOE = 7069; - public static int OBSIDIANSWORD = 7070; - public static int OBSIDIANPICKAXE = 7071; - public static int OBSIDIANSHOVEL = 7072; - public static int OBSIDIANAXE = 7073; - public static int OBSIDIANHOE = 7074; - public static int BLOODSTONESWORD = 7075; - public static int BLOODSTONEPICKAXE = 7076; - public static int BLOODSTONESHOVEL = 7077; - public static int BLOODSTONEAXE = 7078; - public static int BLOODSTONEHOE = 7079; - public static int SATCHEL = 7080; - public static int RESOURCES = 7081; -} diff --git a/common/MysticOres/MysticOres.java b/common/MysticOres/MysticOres.java index c5f268b..c16cba2 100644 --- a/common/MysticOres/MysticOres.java +++ b/common/MysticOres/MysticOres.java @@ -1,33 +1,39 @@ package mysticores; -import mysticores.blocks.BlockHandler; -import mysticores.items.Items; -import mysticores.util.ConfigurationManager; -import mysticores.util.Localizations; -import mysticores.util.OreDictManager; -import mysticores.util.RecipeManager; -import mysticores.util.TabMysticOres; -import mysticores.worldgen.GeneratorManager; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.ItemStack; import cpw.mods.fml.common.IFuelHandler; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.Mod.Instance; +import cpw.mods.fml.common.event.FMLMissingMappingsEvent; import cpw.mods.fml.common.event.FMLPreInitializationEvent; -import cpw.mods.fml.common.network.NetworkMod; +import cpw.mods.fml.common.registry.GameData; import cpw.mods.fml.common.registry.GameRegistry; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import mysticores.blocks.BlockHandler; +import mysticores.items.Items; +import mysticores.util.ConfigurationManager; +import mysticores.util.RecipeManager; +import mysticores.worldgen.WorldGenOres; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraftforge.oredict.OreDictionary; -@Mod(modid = "MysticOres", name = "Mystic Ores", version = "0.1") -@NetworkMod(clientSideRequired = true) -public class MysticOres implements IFuelHandler { - @Instance("MysticOres") +@Mod(modid = "mysticores", name = "Mystic Ores", version = "0.1") +public final class MysticOres implements IFuelHandler { + @Instance("mysticores") public static MysticOres instance; - public static final CreativeTabs MysticOresTab = new TabMysticOres("MysticOresTab"); + public boolean ENABLE = true; + public static CreativeTabs MysticOresTab; + public static final String[] INGOTS = { "ingotVerdite", "ingotMithril", "ingotAdamantine", "ingotIridium", "fuelIridium", "gemTourmaline", "gemAgate", "gemTopaz", "gemAmethyst", "dustMystic", + " shardBloodstone", "shardGlass", "shardObsidian", "rodObsidian" }; + public static final String[] ORES = { "oreAdamantine", "oreAmethyst", "oreIridium", "oreMithril", "oreSapphire", "oreTopaz", "oreVerdite", "oreBloodstone", "oreBlackSoulstone", + "oreBlueSoulstone", "oreRedSoulstone", "oreAgate" }; @Override public int getBurnTime(ItemStack fuel) { - if (fuel.getItem().itemID == Items.Resource.itemID && fuel.getItemDamage() == 4) + if (fuel.getItem() == Items.Resource && fuel.getItemDamage() == 4) return 12800; else return 0; @@ -36,12 +42,41 @@ public class MysticOres implements IFuelHandler { @EventHandler public void preInit(FMLPreInitializationEvent event) { ConfigurationManager.initialize(event.getSuggestedConfigurationFile()); - BlockHandler.initialize(); - Items.initialize(); - OreDictManager.initialize(); - RecipeManager.initialize(); - GeneratorManager.initialize(); - Localizations.initialize(); - GameRegistry.registerFuelHandler(this); + if(ENABLE){ + MysticOresTab = new CreativeTabs("MysticOresTab") { + + @Override + public Item getTabIconItem() { + return Item.getItemFromBlock(BlockHandler.BlockBase); + } + + @Override + @SideOnly(Side.CLIENT) + public int func_151243_f() + { + return 7; + } + }; + BlockHandler.initialize(); + Items.initialize(); + for (int i = 0; i < INGOTS.length; i++) { + OreDictionary.registerOre(INGOTS[i], new ItemStack(Items.Resource, 1, i)); + } + for (int i = 0; i < ORES.length; i++) { + OreDictionary.registerOre(ORES[i], new ItemStack(BlockHandler.BlockBase, 1, i)); + } + RecipeManager.initialize(); + GameRegistry.registerWorldGenerator(new WorldGenOres(), 100); + GameRegistry.registerFuelHandler(this); + } } -} + + @EventHandler + public void onRemap(FMLMissingMappingsEvent event){ + for(FMLMissingMappingsEvent.MissingMapping missingMapping : event.get()){ + if(missingMapping.type.name().equals("ITEM") && missingMapping.name.contains("item.")){ + missingMapping.remap(GameData.getItemRegistry().getObject(missingMapping.name.replace("item.mysticores:r", "R").replace("item.", ""))); + } + } + } +} \ No newline at end of file diff --git a/common/MysticOres/Util/ConfigurationManager.java b/common/MysticOres/Util/ConfigurationManager.java index bcae963..9446108 100644 --- a/common/MysticOres/Util/ConfigurationManager.java +++ b/common/MysticOres/Util/ConfigurationManager.java @@ -1,48 +1,15 @@ package mysticores.util; -import java.io.File; - -import mysticores.blocks.BlockHandler; -import mysticores.lib.ItemID; +import mysticores.MysticOres; import mysticores.lib.Rarity; -import net.minecraftforge.common.Configuration; +import net.minecraftforge.common.config.Configuration; + +import java.io.File; public class ConfigurationManager { public static void initialize(File file) { Configuration config = new Configuration(file); - ItemID.RESOURCES = config.getItem("Resource Items", ItemID.RESOURCES).getInt(); - ItemID.VERDITESWORD = config.getItem("Tools", "Verdite Sword", ItemID.VERDITESWORD).getInt(); - ItemID.VERDITEPICKAXE = config.getItem("Tools", "Verdite Pickaxe", ItemID.VERDITEPICKAXE).getInt(); - ItemID.VERDITESHOVEL = config.getItem("Tools", "Verdite Shovel", ItemID.VERDITESHOVEL).getInt(); - ItemID.VERDITEAXE = config.getItem("Tools", "Verdite Axe", ItemID.VERDITEAXE).getInt(); - ItemID.VERDITEHOE = config.getItem("Tools", "Verdite Hoe", ItemID.VERDITEHOE).getInt(); - ItemID.MITHRILSWORD = config.getItem("Tools", "Mithril Sword", ItemID.MITHRILSWORD).getInt(); - ItemID.MITHRILPICKAXE = config.getItem("Tools", "Mithril Pickaxe", ItemID.MITHRILPICKAXE).getInt(); - ItemID.MITHRILSHOVEL = config.getItem("Tools", "Mithril Shovel", ItemID.MITHRILSHOVEL).getInt(); - ItemID.MITHRILAXE = config.getItem("Tools", "Mithril Axe", ItemID.MITHRILAXE).getInt(); - ItemID.MITHRILHOE = config.getItem("Tools", "Mithril Hoe", ItemID.MITHRILHOE).getInt(); - ItemID.ADAMANTINESWORD = config.getItem("Tools", "Adamantine Sword", ItemID.ADAMANTINESWORD).getInt(); - ItemID.ADAMANTINEPICKAXE = config.getItem("Tools", "Adamantine Pickaxe", ItemID.ADAMANTINEPICKAXE).getInt(); - ItemID.ADAMANTINESHOVEL = config.getItem("Tools", "Adamantine Shovel", ItemID.ADAMANTINESHOVEL).getInt(); - ItemID.ADAMANTINEAXE = config.getItem("Tools", "Adamantine Axe", ItemID.ADAMANTINEAXE).getInt(); - ItemID.ADAMANTINEHOE = config.getItem("Tools", "Adamantine Hoe", ItemID.ADAMANTINEHOE).getInt(); - ItemID.IRIDIUMSWORD = config.getItem("Tools", "Iridium Sword", ItemID.IRIDIUMSWORD).getInt(); - ItemID.IRIDIUMPICKAXE = config.getItem("Tools", "Iridium Pickaxe", ItemID.IRIDIUMPICKAXE).getInt(); - ItemID.IRIDIUMSHOVEL = config.getItem("Tools", "Iridium Shovel", ItemID.IRIDIUMSHOVEL).getInt(); - ItemID.IRIDIUMAXE = config.getItem("Tools", "Iridium Axe", ItemID.IRIDIUMAXE).getInt(); - ItemID.IRIDIUMHOE = config.getItem("Tools", "Iridium Hoe", ItemID.IRIDIUMHOE).getInt(); - ItemID.BLOODSTONESWORD = config.getItem("Tools", "Bloodstone Sword", ItemID.BLOODSTONESWORD).getInt(); - ItemID.BLOODSTONEPICKAXE = config.getItem("Tools", "Bloodstone Pickaxe", ItemID.BLOODSTONEPICKAXE).getInt(); - ItemID.BLOODSTONESHOVEL = config.getItem("Tools", "Bloodstone Shovel", ItemID.BLOODSTONESHOVEL).getInt(); - ItemID.BLOODSTONEAXE = config.getItem("Tools", "Bloodstone Axe", ItemID.BLOODSTONEAXE).getInt(); - ItemID.BLOODSTONEHOE = config.getItem("Tools", "Bloodstone Hoe", ItemID.BLOODSTONEHOE).getInt(); - ItemID.OBSIDIANSWORD = config.getItem("Tools", "Obsidian Sword", ItemID.OBSIDIANSWORD).getInt(); - ItemID.OBSIDIANPICKAXE = config.getItem("Tools", "Obsidian Pickaxe", ItemID.OBSIDIANPICKAXE).getInt(); - ItemID.OBSIDIANSHOVEL = config.getItem("Tools", "Obsidian Shovel", ItemID.OBSIDIANSHOVEL).getInt(); - ItemID.OBSIDIANAXE = config.getItem("Tools", "Obsidian Axe", ItemID.OBSIDIANAXE).getInt(); - ItemID.OBSIDIANHOE = config.getItem("Tools", "Obsidian Hoe", ItemID.OBSIDIANHOE).getInt(); - ItemID.SATCHEL = config.getItem("Satchel ID", ItemID.SATCHEL).getInt(); - BlockHandler.BASEID = config.getBlock("Base Block ID", BlockHandler.BASEID).getInt(); + MysticOres.instance.ENABLE = config.get("General", "Enable", true).getBoolean(); Rarity.VERDITE = config.get("Ore Rarity", "Verdite Ore", Rarity.VERDITE).getInt(); Rarity.MITHRIL = config.get("Ore Rarity", "Mithril Ore", Rarity.MITHRIL).getInt(); Rarity.ADAMANTINE = config.get("Ore Rarity", "Adamantine Ore", Rarity.ADAMANTINE).getInt(); diff --git a/common/MysticOres/Util/Localizations.java b/common/MysticOres/Util/Localizations.java deleted file mode 100644 index c60e3c6..0000000 --- a/common/MysticOres/Util/Localizations.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticores.util; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Enumeration; -import java.util.regex.Matcher; -import java.util.regex.Pattern; -import java.util.zip.ZipEntry; -import java.util.zip.ZipException; -import java.util.zip.ZipFile; - -import mysticores.MysticOres; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.registry.LanguageRegistry; - -/* - * - * All credits go to copygirl (or copy....boy) for this one - * Couldn't have done any of this without your - * repository, many thanks friend c: - * - */ -public class Localizations { - private Localizations() { - } - - public static void initialize() { - File source = Loader.instance().getReversedModObjectList().get(MysticOres.instance).getSource(); - Pattern pattern = Pattern.compile(".*(assets/" + "mysticmods/lang/(.+)\\.(.+))"); - for (String file : getResources(source, pattern)) { - Matcher matcher = pattern.matcher(file); - matcher.find(); - String resource = "/" + matcher.group(1); - String lang = matcher.group(2); - boolean isXML = matcher.group(3).equalsIgnoreCase("XML"); - LanguageRegistry.instance().loadLocalization(resource, lang, isXML); - } - } - - private static Collection getResources(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - if (file.isDirectory()) - retval.addAll(getResourcesFromDirectory(file, pattern)); - else - retval.addAll(getResourcesFromJarFile(file, pattern)); - return retval; - } - - private static Collection getResourcesFromDirectory(File directory, Pattern pattern) { - ArrayList retval = new ArrayList(); - File[] FileList = directory.listFiles(); - for (File file : FileList) { - if (file.isDirectory()) { - retval.addAll(getResourcesFromDirectory(file, pattern)); - } else - try { - String fileName = file.getCanonicalPath().replace('\\', '/'); - boolean accept = pattern.matcher(fileName).matches(); - if (accept) - retval.add(fileName); - } catch (final IOException e) { - throw new Error(e); - } - } - return retval; - } - - private static Collection getResourcesFromJarFile(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - ZipFile Zip; - try { - Zip = new ZipFile(file); - } catch (ZipException Ex) { - throw new Error(Ex); - } catch (IOException Ex) { - throw new Error(Ex); - } - Enumeration entries = Zip.entries(); - while (entries.hasMoreElements()) { - ZipEntry ZipE = entries.nextElement(); - String FileName = ZipE.getName(); - boolean accept = pattern.matcher(FileName).matches(); - if (accept) - retval.add(FileName); - } - try { - Zip.close(); - } catch (IOException Ex) { - throw new Error(Ex); - } - return retval; - } -} diff --git a/common/MysticOres/Util/OreDictManager.java b/common/MysticOres/Util/OreDictManager.java deleted file mode 100644 index 79fae4e..0000000 --- a/common/MysticOres/Util/OreDictManager.java +++ /dev/null @@ -1,22 +0,0 @@ -package mysticores.util; - -import mysticores.blocks.BlockHandler; -import mysticores.items.Items; -import net.minecraft.item.ItemStack; -import net.minecraftforge.oredict.OreDictionary; - -public class OreDictManager { - public static final String[] INGOTS = { "ingotVerdite", "ingotMithril", "ingotAdamantine", "ingotIridium", "fuelIridium", "gemTourmaline", "gemAgate", "gemTopaz", "gemAmethyst", "dustMystic", - " shardBloodstone", "shardGlass", "shardObsidian", "rodObsidian" }; - public static final String[] ORES = { "oreAdamantine", "oreAmethyst", "oreIridium", "oreMithril", "oreSapphire", "oreTopaz", "oreVerdite", "oreBloodstone", "oreBlackSoulstone", - "oreBlueSoulstone", "oreRedSoulstone", "oreAgate" }; - - public static void initialize() { - for (int i = 0; i < INGOTS.length; i++) { - OreDictionary.registerOre(INGOTS[i], new ItemStack(Items.Resource, 1, i)); - } - for (int i = 0; i < ORES.length; i++) { - OreDictionary.registerOre(ORES[i], new ItemStack(BlockHandler.BlockBase, 1, i)); - } - } -} diff --git a/common/MysticOres/Util/RecipeManager.java b/common/MysticOres/Util/RecipeManager.java index 89c4448..873e139 100644 --- a/common/MysticOres/Util/RecipeManager.java +++ b/common/MysticOres/Util/RecipeManager.java @@ -1,16 +1,91 @@ package mysticores.util; +import cpw.mods.fml.common.registry.GameRegistry; +import mysticores.MysticOres; import mysticores.blocks.BlockHandler; import mysticores.items.Items; -import net.minecraft.block.Block; -import net.minecraft.item.Item; +import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraftforge.oredict.ShapedOreRecipe; import net.minecraftforge.oredict.ShapelessOreRecipe; -import cpw.mods.fml.common.registry.GameRegistry; + +import java.util.HashMap; +import java.util.Map; public class RecipeManager { + private static HashMap agateConverted = new HashMap(); + static{ + agateConverted.put("stone",new ItemStack(net.minecraft.init.Items.slime_ball,8)); + agateConverted.put(new ItemStack(Blocks.sand),new ItemStack(Blocks.grass,8)); + agateConverted.put(new ItemStack(net.minecraft.init.Items.reeds),new ItemStack(net.minecraft.init.Items.wheat,16)); + agateConverted.put(new ItemStack(net.minecraft.init.Items.slime_ball),new ItemStack(Blocks.cactus,32)); + agateConverted.put("shardGlass",new ItemStack(net.minecraft.init.Items.flint,8)); + agateConverted.put("plankWood",new ItemStack(Blocks.bookshelf,8)); + agateConverted.put("stickWood",new ItemStack(net.minecraft.init.Items.leather,8)); + agateConverted.put(new ItemStack(Blocks.dirt),new ItemStack(BlockHandler.BlockBase, 8, 7)); + agateConverted.put(new ItemStack(net.minecraft.init.Items.egg),new ItemStack(net.minecraft.init.Items.wheat_seeds, 32)); + agateConverted.put(new ItemStack(Blocks.gravel),new ItemStack(Blocks.coal_ore,8)); + agateConverted.put(new ItemStack(net.minecraft.init.Items.wheat_seeds),new ItemStack(Blocks.deadbush, 8)); + agateConverted.put(new ItemStack(Blocks.glass),new ItemStack(Blocks.wool,8,0)); + agateConverted.put(new ItemStack(net.minecraft.init.Items.iron_ingot),new ItemStack(Items.Resource, 16, 0)); + agateConverted.put("oreGold",new ItemStack(BlockHandler.BlockBase, 16, 7)); + agateConverted.put("cobblestone",new ItemStack(Blocks.mossy_cobblestone, 8, 0)); + agateConverted.put("treeSapling",new ItemStack(net.minecraft.init.Items.wheat_seeds,16,0)); + } + private static HashMap amethystConverted = new HashMap(); + static{ + amethystConverted.put(new ItemStack(net.minecraft.init.Items.egg), new ItemStack(net.minecraft.init.Items.cookie, 8)); + amethystConverted.put("plankWood", new ItemStack(Blocks.noteblock, 8)); + amethystConverted.put("shardObsidian", new ItemStack(Items.Resource, 8, 4)); + amethystConverted.put("stickWood", new ItemStack(Items.Resource, 8, 13)); + amethystConverted.put(new ItemStack(Blocks.dirt), new ItemStack(Blocks.iron_ore, 8)); + amethystConverted.put(new ItemStack(Blocks.brick_block), new ItemStack(Blocks.tnt, 8)); + amethystConverted.put("treeSapling", new ItemStack(Blocks.leaves, 16)); + amethystConverted.put("oreRedstone", new ItemStack(Blocks.diamond_ore, 4)); + amethystConverted.put(new ItemStack(net.minecraft.init.Items.slime_ball), new ItemStack(net.minecraft.init.Items.cake)); + amethystConverted.put(new ItemStack(Blocks.glass), new ItemStack(Blocks.lit_pumpkin, 8)); + amethystConverted.put("shardGlass", new ItemStack(Items.Resource, 8, 12)); + amethystConverted.put("stone", new ItemStack(Blocks.monster_egg, 8)); + amethystConverted.put(new ItemStack(Blocks.lapis_block), new ItemStack(net.minecraft.init.Items.diamond, 8)); + amethystConverted.put(new ItemStack(Blocks.sand), new ItemStack(Blocks.gold_ore, 16)); + amethystConverted.put(new ItemStack(net.minecraft.init.Items.reeds), new ItemStack(net.minecraft.init.Items.book, 8)); + } + private static HashMap tourmalineConverted = new HashMap(); + static{ + tourmalineConverted.put(new ItemStack(Blocks.sand), new ItemStack(Blocks.glass, 16)); + tourmalineConverted.put("oreCoal", new ItemStack(Blocks.lapis_ore, 8)); + tourmalineConverted.put(new ItemStack(net.minecraft.init.Items.egg), new ItemStack(net.minecraft.init.Items.sugar, 16)); + tourmalineConverted.put(new ItemStack(net.minecraft.init.Items.wheat_seeds), new ItemStack(Blocks.brown_mushroom, 8)); + tourmalineConverted.put(new ItemStack(Blocks.glass), new ItemStack(Blocks.snow_layer, 8)); + tourmalineConverted.put("stone", new ItemStack(Blocks.glass, 8)); + tourmalineConverted.put(new ItemStack(Blocks.iron_block), new ItemStack(Blocks.lapis_block, 8)); + tourmalineConverted.put("plankWood", new ItemStack(Blocks.sandstone, 16)); + tourmalineConverted.put("stickWood", new ItemStack(net.minecraft.init.Items.string, 8)); + tourmalineConverted.put(new ItemStack(Blocks.snow), new ItemStack(Blocks.ice, 8)); + tourmalineConverted.put("treeSapling", new ItemStack(net.minecraft.init.Items.reeds, 8)); + tourmalineConverted.put(new ItemStack(Blocks.dirt), new ItemStack(Blocks.snow, 8)); + tourmalineConverted.put(new ItemStack(net.minecraft.init.Items.reeds), new ItemStack(net.minecraft.init.Items.snowball, 16)); + tourmalineConverted.put(new ItemStack(net.minecraft.init.Items.slime_ball), new ItemStack(net.minecraft.init.Items.clay_ball, 16)); + } + private static HashMap topazeConverted = new HashMap(); + static{ + topazeConverted.put("stone", new ItemStack(Blocks.sandstone, 16)); + topazeConverted.put(new ItemStack(Blocks.iron_block), new ItemStack(Blocks.gold_block, 8)); + topazeConverted.put(new ItemStack(Blocks.sand), new ItemStack(Blocks.sponge, 8)); + topazeConverted.put("oreLapis", new ItemStack(Blocks.redstone_ore, 8)); + topazeConverted.put(new ItemStack(net.minecraft.init.Items.egg), new ItemStack(net.minecraft.init.Items.feather, 32)); + topazeConverted.put(new ItemStack(net.minecraft.init.Items.wheat), new ItemStack(Blocks.red_mushroom, 8)); + topazeConverted.put(new ItemStack(Blocks.glass), new ItemStack(Blocks.glowstone, 8)); + topazeConverted.put("shardObsidian", new ItemStack(Items.Resource, 16, 11)); + topazeConverted.put("cobblestone", new ItemStack(Blocks.netherrack, 16)); + topazeConverted.put("treeSapling", new ItemStack(Blocks.log, 16)); + topazeConverted.put(new ItemStack(Blocks.dirt), new ItemStack(Blocks.iron_ore, 8)); + topazeConverted.put(new ItemStack(net.minecraft.init.Items.reeds), new ItemStack(net.minecraft.init.Items.apple, 1)); + topazeConverted.put("shardGlass", new ItemStack(net.minecraft.init.Items.arrow, 32)); + topazeConverted.put("plankWood", new ItemStack(Blocks.wooden_door, 8)); + topazeConverted.put("stickWood", new ItemStack(net.minecraft.init.Items.bone, 8)); + } public static void initialize() { recipes(); toolRecipes(); @@ -19,92 +94,108 @@ public class RecipeManager { } private static void powderRecipes() { - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreGold, 2), OreDictManager.INGOTS[9], "oreGold")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreIron, 2), OreDictManager.INGOTS[9], "oreIron")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 2, 10), OreDictManager.INGOTS[9], OreDictManager.INGOTS[10])); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Item.gunpowder, 2), OreDictManager.INGOTS[9], Item.gunpowder)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 2, 4), OreDictManager.INGOTS[9], OreDictManager.INGOTS[4])); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreCoal, 2), OreDictManager.INGOTS[9], Block.oreCoal)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreIron, 3), OreDictManager.INGOTS[9], "oreIron")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreGold, 3), OreDictManager.INGOTS[9], "oreGold")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreRedstone, 2), OreDictManager.INGOTS[9], "oreRedstone")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreLapis, 2), OreDictManager.INGOTS[9], "oreLapis")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Block.oreDiamond, 2), OreDictManager.INGOTS[9], "oreDiamond")); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Item.sugar, 18), OreDictManager.INGOTS[9], Item.sugar)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Item.redstone, 12), OreDictManager.INGOTS[9], Item.redstone)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Item.glowstone, 6), OreDictManager.INGOTS[9], Item.glowstone)); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Item.gunpowder, 3), OreDictManager.INGOTS[9], Item.gunpowder)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.gold_ore, 2), MysticOres.INGOTS[9], "oreGold")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.iron_ore, 2), MysticOres.INGOTS[9], "oreIron")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 2, 10), MysticOres.INGOTS[9], MysticOres.INGOTS[10])); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(net.minecraft.init.Items.gunpowder, 2), MysticOres.INGOTS[9], net.minecraft.init.Items.gunpowder)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 2, 4), MysticOres.INGOTS[9], MysticOres.INGOTS[4])); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.coal_ore, 2), MysticOres.INGOTS[9], "oreCoal")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.iron_ore, 3), MysticOres.INGOTS[9], "oreIron")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.gold_ore, 3), MysticOres.INGOTS[9], "oreGold")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.redstone_ore, 2), MysticOres.INGOTS[9], "oreRedstone")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.lapis_ore, 2), MysticOres.INGOTS[9], "oreLapis")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Blocks.diamond_ore, 2), MysticOres.INGOTS[9], "oreDiamond")); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(net.minecraft.init.Items.sugar, 18), MysticOres.INGOTS[9], net.minecraft.init.Items.sugar)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(net.minecraft.init.Items.redstone, 12), MysticOres.INGOTS[9], net.minecraft.init.Items.redstone)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(net.minecraft.init.Items.glowstone_dust, 6), MysticOres.INGOTS[9], net.minecraft.init.Items.glowstone_dust)); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(net.minecraft.init.Items.gunpowder, 3), MysticOres.INGOTS[9], net.minecraft.init.Items.gunpowder)); } private static void recipes() { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Block.glass, 1), "##", "##", '#', OreDictManager.INGOTS[11])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Block.obsidian, 1), "##", "##", '#', OreDictManager.INGOTS[12])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 7), "XXX", "XOX", "XXX", Character.valueOf('X'), Block.dirt, Character.valueOf('O'), - OreDictManager.INGOTS[6])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 16, 7), "XXX", "XOX", "XXX", Character.valueOf('X'), OreDictManager.ORES[3], Character.valueOf('O'), - OreDictManager.INGOTS[6])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 3), "XXX", "XOX", "XXX", Character.valueOf('X'), Block.dirt, Character.valueOf('O'), - OreDictManager.INGOTS[8])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 12), "###", "#D#", "###", '#', OreDictManager.INGOTS[11], 'D', OreDictManager.INGOTS[12])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 1, 7), "##", "##", '#', OreDictManager.INGOTS[10])); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 7), OreDictManager.INGOTS[9], OreDictManager.ORES[7])); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 3), OreDictManager.INGOTS[9], OreDictManager.ORES[3])); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 0), OreDictManager.INGOTS[9], OreDictManager.ORES[0])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.Resource, 2, 13), "#", "#", '#', OreDictManager.INGOTS[12])); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.Resource, 1, 3), "###", "#O#", "###", '#', OreDictManager.INGOTS[4], 'O', OreDictManager.INGOTS[2])); - GameRegistry.addShapelessRecipe(new ItemStack(Items.Resource, 4, 11), Block.glass); - GameRegistry.addShapelessRecipe(new ItemStack(Items.Resource, 4, 12), Block.obsidian); - GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 8, 9), OreDictManager.INGOTS[5], OreDictManager.INGOTS[7], OreDictManager.INGOTS[8], OreDictManager.INGOTS[6])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Blocks.glass, 1), "##", "##", '#', MysticOres.INGOTS[11])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Blocks.obsidian, 1), "##", "##", '#', MysticOres.INGOTS[12])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 7), "XXX", "XOX", "XXX", 'X', Blocks.dirt, 'O', + MysticOres.INGOTS[6])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 16, 7), "XXX", "XOX", "XXX", 'X', MysticOres.ORES[3], 'O', + MysticOres.INGOTS[6])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 3), "XXX", "XOX", "XXX", 'X', Blocks.dirt, 'O', + MysticOres.INGOTS[8])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 8, 12), "###", "#D#", "###", '#', MysticOres.INGOTS[11], 'D', MysticOres.INGOTS[12])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(BlockHandler.BlockBase, 1, 7), "##", "##", '#', MysticOres.INGOTS[10])); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 7), MysticOres.INGOTS[9], MysticOres.ORES[7])); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 3), MysticOres.INGOTS[9], MysticOres.ORES[3])); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(BlockHandler.BlockBase, 2, 0), MysticOres.INGOTS[9], MysticOres.ORES[0])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.Resource, 2, 13), "#", "#", '#', MysticOres.INGOTS[12])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.Resource, 1, 3), "###", "#O#", "###", '#', MysticOres.INGOTS[4], 'O', MysticOres.INGOTS[2])); + GameRegistry.addShapelessRecipe(new ItemStack(Items.Resource, 4, 11), Blocks.glass); + GameRegistry.addShapelessRecipe(new ItemStack(Items.Resource, 4, 12), Blocks.obsidian); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.Resource, 8, 9), MysticOres.INGOTS[5], MysticOres.INGOTS[7], MysticOres.INGOTS[8], MysticOres.INGOTS[6])); + for(Map.Entry entry:agateConverted.entrySet()){ + GameRegistry.addRecipe(new ShapedOreRecipe(entry.getValue(), "###", "#o#", "###", 'o', "gemAgate", '#', entry.getKey())); + } + for(Map.Entry entry:amethystConverted.entrySet()){ + GameRegistry.addRecipe(new ShapedOreRecipe(entry.getValue(), "###", "#o#", "###", 'o', "gemAmethyst", '#', entry.getKey())); + } + for(Map.Entry entry:tourmalineConverted.entrySet()){ + GameRegistry.addRecipe(new ShapedOreRecipe(entry.getValue(), "###", "#o#", "###", 'o', "gemTourmaline", '#', entry.getKey())); + } + for(Map.Entry entry:topazeConverted.entrySet()){ + GameRegistry.addRecipe(new ShapedOreRecipe(entry.getValue(), "###", "#o#", "###", 'o', "gemTopaz", '#', entry.getKey())); + } } private static void smelting() { - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 6, new ItemStack(Items.Resource, 1, 0), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 3, new ItemStack(Items.Resource, 1, 1), 0.7F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 0, new ItemStack(Items.Resource, 1, 2), 0.9F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 2, new ItemStack(Items.Resource, 1, 4), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 4, new ItemStack(Items.Resource, 1, 5), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 11, new ItemStack(Items.Resource, 1, 6), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 5, new ItemStack(Items.Resource, 1, 7), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 1, new ItemStack(Items.Resource, 1, 8), 0.4F); - FurnaceRecipes.smelting().addSmelting(BlockHandler.BlockBase.blockID, 7, new ItemStack(Items.Resource, 1, 10), 0.4F); + smeltBlockIntoResource(6, 0, 0.4F); + smeltBlockIntoResource(3, 1, 0.7F); + smeltBlockIntoResource(0, 2, 0.9F); + smeltBlockIntoResource(2, 4, 0.4F); + smeltBlockIntoResource(4, 5, 0.4F); + smeltBlockIntoResource(11, 6, 0.4F); + smeltBlockIntoResource(5, 7, 0.4F); + smeltBlockIntoResource(1, 8, 0.4F); + smeltBlockIntoResource(7, 10, 0.4F); } + private static void smeltBlockIntoResource(int metaInput, int metaOutput, float exp){ + FurnaceRecipes.smelting().func_151394_a(new ItemStack(BlockHandler.BlockBase,1, metaInput), new ItemStack(Items.Resource, 1, metaOutput), exp); + } + private static void toolRecipes() { - ToolRecipes.SwordRecipe(Items.VerditeSword, OreDictManager.INGOTS[0]); - ToolRecipes.PickaxeRecipe(Items.VerditePickaxe, OreDictManager.INGOTS[0]); - ToolRecipes.ShovelRecipe(Items.VerditeShovel, OreDictManager.INGOTS[0]); - ToolRecipes.AxeRecipe(Items.VerditeAxe, OreDictManager.INGOTS[0]); - ToolRecipes.HoeRecipe(Items.VerditeHoe, OreDictManager.INGOTS[0]); - ToolRecipes.SwordRecipe(Items.MithrilSword, OreDictManager.INGOTS[1]); - ToolRecipes.PickaxeRecipe(Items.MithrilPickaxe, OreDictManager.INGOTS[1]); - ToolRecipes.ShovelRecipe(Items.MithrilShovel, OreDictManager.INGOTS[1]); - ToolRecipes.AxeRecipe(Items.MithrilAxe, OreDictManager.INGOTS[1]); - ToolRecipes.HoeRecipe(Items.MithrilHoe, OreDictManager.INGOTS[1]); - ToolRecipes.AdvancedSwordRecipe(Items.AdamantineSword, OreDictManager.INGOTS[2]); - ToolRecipes.AdvancedPickaxeRecipe(Items.AdamantinePickaxe, OreDictManager.INGOTS[2]); - ToolRecipes.AdvancedShovelRecipe(Items.AdamantineShovel, OreDictManager.INGOTS[2]); - ToolRecipes.AdvancedAxeRecipe(Items.AdamantineAxe, OreDictManager.INGOTS[2]); - ToolRecipes.AdvancedHoeRecipe(Items.AdamantineHoe, OreDictManager.INGOTS[2]); - ToolRecipes.AdvancedSwordRecipe(Items.IridiumSword, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedPickaxeRecipe(Items.IridiumPickaxe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedShovelRecipe(Items.IridiumShovel, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedAxeRecipe(Items.IridiumAxe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedHoeRecipe(Items.IridiumHoe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedSwordRecipe(Items.IridiumSword, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedPickaxeRecipe(Items.IridiumPickaxe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedShovelRecipe(Items.IridiumShovel, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedAxeRecipe(Items.IridiumAxe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedHoeRecipe(Items.IridiumHoe, OreDictManager.INGOTS[3]); - ToolRecipes.AdvancedSwordRecipe(Items.ObsidianSword, new ItemStack(Block.obsidian)); - ToolRecipes.AdvancedPickaxeRecipe(Items.ObsidianPickaxe, new ItemStack(Block.obsidian)); - ToolRecipes.AdvancedShovelRecipe(Items.ObsidianShovel, new ItemStack(Block.obsidian)); - ToolRecipes.AdvancedAxeRecipe(Items.ObsidianAxe, new ItemStack(Block.obsidian)); - ToolRecipes.AdvancedHoeRecipe(Items.ObsidianHoe, new ItemStack(Block.obsidian)); - ToolRecipes.AdvancedSwordRecipe(Items.BloodstoneSword, OreDictManager.ORES[7]); - ToolRecipes.AdvancedPickaxeRecipe(Items.BloodstonePickaxe, OreDictManager.ORES[7]); - ToolRecipes.AdvancedShovelRecipe(Items.BloodstoneShovel, OreDictManager.ORES[7]); - ToolRecipes.AdvancedAxeRecipe(Items.BloodstoneAxe, OreDictManager.ORES[7]); - ToolRecipes.AdvancedHoeRecipe(Items.BloodstoneHoe, OreDictManager.ORES[7]); - GameRegistry.addRecipe(new ItemStack(Items.Satchel, 1), "#$#", "$%$", "#$#", '#', Item.silk, '$', OreDictManager.INGOTS[9], '%', Block.enderChest); + ToolRecipes.sword(Items.VerditeSword, MysticOres.INGOTS[0]); + ToolRecipes.pickaxe(Items.VerditePickaxe, MysticOres.INGOTS[0]); + ToolRecipes.shovel(Items.VerditeShovel, MysticOres.INGOTS[0]); + ToolRecipes.axe(Items.VerditeAxe, MysticOres.INGOTS[0]); + ToolRecipes.hoe(Items.VerditeHoe, MysticOres.INGOTS[0]); + ToolRecipes.sword(Items.MithrilSword, MysticOres.INGOTS[1]); + ToolRecipes.pickaxe(Items.MithrilPickaxe, MysticOres.INGOTS[1]); + ToolRecipes.shovel(Items.MithrilShovel, MysticOres.INGOTS[1]); + ToolRecipes.axe(Items.MithrilAxe, MysticOres.INGOTS[1]); + ToolRecipes.hoe(Items.MithrilHoe, MysticOres.INGOTS[1]); + ToolRecipes.advancedSword(Items.AdamantineSword, MysticOres.INGOTS[2]); + ToolRecipes.advancedPickaxe(Items.AdamantinePickaxe, MysticOres.INGOTS[2]); + ToolRecipes.advancedShovel(Items.AdamantineShovel, MysticOres.INGOTS[2]); + ToolRecipes.advancedAxe(Items.AdamantineAxe, MysticOres.INGOTS[2]); + ToolRecipes.advancedHoe(Items.AdamantineHoe, MysticOres.INGOTS[2]); + ToolRecipes.advancedSword(Items.IridiumSword, MysticOres.INGOTS[3]); + ToolRecipes.advancedPickaxe(Items.IridiumPickaxe, MysticOres.INGOTS[3]); + ToolRecipes.advancedShovel(Items.IridiumShovel, MysticOres.INGOTS[3]); + ToolRecipes.advancedAxe(Items.IridiumAxe, MysticOres.INGOTS[3]); + ToolRecipes.advancedHoe(Items.IridiumHoe, MysticOres.INGOTS[3]); + ToolRecipes.advancedSword(Items.IridiumSword, MysticOres.INGOTS[3]); + ToolRecipes.advancedPickaxe(Items.IridiumPickaxe, MysticOres.INGOTS[3]); + ToolRecipes.advancedShovel(Items.IridiumShovel, MysticOres.INGOTS[3]); + ToolRecipes.advancedAxe(Items.IridiumAxe, MysticOres.INGOTS[3]); + ToolRecipes.advancedHoe(Items.IridiumHoe, MysticOres.INGOTS[3]); + ToolRecipes.advancedSword(Items.ObsidianSword, new ItemStack(Blocks.obsidian)); + ToolRecipes.advancedPickaxe(Items.ObsidianPickaxe, new ItemStack(Blocks.obsidian)); + ToolRecipes.advancedShovel(Items.ObsidianShovel, new ItemStack(Blocks.obsidian)); + ToolRecipes.advancedAxe(Items.ObsidianAxe, new ItemStack(Blocks.obsidian)); + ToolRecipes.advancedHoe(Items.ObsidianHoe, new ItemStack(Blocks.obsidian)); + ToolRecipes.advancedSword(Items.BloodstoneSword, MysticOres.ORES[7]); + ToolRecipes.advancedPickaxe(Items.BloodstonePickaxe, MysticOres.ORES[7]); + ToolRecipes.advancedShovel(Items.BloodstoneShovel, MysticOres.ORES[7]); + ToolRecipes.advancedAxe(Items.BloodstoneAxe, MysticOres.ORES[7]); + ToolRecipes.advancedHoe(Items.BloodstoneHoe, MysticOres.ORES[7]); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.Satchel, 1), "#$#", "$%$", "#$#", '#', net.minecraft.init.Items.string, '$', MysticOres.INGOTS[9], '%', Blocks.ender_chest)); } } diff --git a/common/MysticOres/Util/TabMysticOres.java b/common/MysticOres/Util/TabMysticOres.java deleted file mode 100644 index 0cf0c80..0000000 --- a/common/MysticOres/Util/TabMysticOres.java +++ /dev/null @@ -1,16 +0,0 @@ -package mysticores.util; - -import mysticores.blocks.BlockHandler; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.ItemStack; - -public class TabMysticOres extends CreativeTabs { - public TabMysticOres(String par2Str) { - super(par2Str); - } - - @Override - public ItemStack getIconItemStack() { - return new ItemStack(BlockHandler.BlockBase, 1, 7); - } -} diff --git a/common/MysticOres/Util/ToolRecipes.java b/common/MysticOres/Util/ToolRecipes.java index eda088c..ef5ca42 100644 --- a/common/MysticOres/Util/ToolRecipes.java +++ b/common/MysticOres/Util/ToolRecipes.java @@ -1,52 +1,53 @@ package mysticores.util; +import cpw.mods.fml.common.registry.GameRegistry; +import mysticores.MysticOres; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraftforge.oredict.ShapedOreRecipe; -import cpw.mods.fml.common.registry.GameRegistry; public class ToolRecipes { - public static void AdvancedAxeRecipe(Item output, Object input) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "#S ", " S ", 'S', OreDictManager.INGOTS[13], '#', input)); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S# ", "S ", 'S', OreDictManager.INGOTS[13], '#', input)); + public static void advancedAxe(Item output, Object input) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "#S ", " S ", 'S', MysticOres.INGOTS[13], '#', input)); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S# ", "S ", 'S', MysticOres.INGOTS[13], '#', input)); } - public static void AdvancedHoeRecipe(Item output, Object input) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", " S ", " S ", 'S', OreDictManager.INGOTS[13], '#', input)); - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S ", "S ", 'S', OreDictManager.INGOTS[13], '#', input)); + public static void advancedHoe(Item output, Object input) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", " S ", " S ", 'S', MysticOres.INGOTS[13], '#', input)); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S ", "S ", 'S', MysticOres.INGOTS[13], '#', input)); } - public static void AdvancedPickaxeRecipe(Item output, Object input) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "###", " S ", " S ", 'S', OreDictManager.INGOTS[13], '#', input)); + public static void advancedPickaxe(Item output, Object input) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "###", " S ", " S ", 'S', MysticOres.INGOTS[13], '#', input)); } - public static void AdvancedShovelRecipe(Item output, Object input) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "S", "S", 'S', OreDictManager.INGOTS[13], '#', input)); + public static void advancedShovel(Item output, Object input) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "S", "S", 'S', MysticOres.INGOTS[13], '#', input)); } - public static void AdvancedSwordRecipe(Item output, Object input) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "#", "S", 'S', OreDictManager.INGOTS[13], '#', input)); + public static void advancedSword(Item output, Object input) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "#", "S", 'S', MysticOres.INGOTS[13], '#', input)); } - public static void AxeRecipe(Item output, Object input) { + public static void axe(Item output, Object input) { GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "#S ", " S ", 'S', "stickWood", '#', input)); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S# ", "S ", 'S', "stickWood", '#', input)); } - public static void HoeRecipe(Item output, Object input) { + public static void hoe(Item output, Object input) { GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", " S ", " S ", 'S', "stickWood", '#', input)); GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "## ", "S ", "S ", 'S', "stickWood", '#', input)); } - public static void PickaxeRecipe(Item output, Object input) { + public static void pickaxe(Item output, Object input) { GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "###", " S ", " S ", 'S', "stickWood", '#', input)); } - public static void ShovelRecipe(Item output, Object input) { + public static void shovel(Item output, Object input) { GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "S", "S", 'S', "stickWood", '#', input)); } - public static void SwordRecipe(Item output, Object input) { + public static void sword(Item output, Object input) { GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(output), "#", "#", "S", 'S', "stickWood", '#', input)); } } diff --git a/common/MysticOres/Worldgen/GeneratorManager.java b/common/MysticOres/Worldgen/GeneratorManager.java deleted file mode 100644 index 3b8c57f..0000000 --- a/common/MysticOres/Worldgen/GeneratorManager.java +++ /dev/null @@ -1,15 +0,0 @@ -package mysticores.worldgen; - -import mysticores.blocks.BlockHandler; -import mysticores.lib.Rarity; -import cpw.mods.fml.common.registry.GameRegistry; - -public class GeneratorManager { - public static void initialize() { - GameRegistry.registerWorldGenerator(new WorldGenOres()); - GameRegistry.registerWorldGenerator(new NetherGenMineable(BlockHandler.BlockBase.blockID, 7, Rarity.BLOODSTONE + 1)); - GameRegistry.registerWorldGenerator(new NetherGenMineable(BlockHandler.BlockBase.blockID, 8, Rarity.BLACKSOULSTONE + 1)); - GameRegistry.registerWorldGenerator(new NetherGenMineable(BlockHandler.BlockBase.blockID, 9, Rarity.BLUESOULSTONE + 1)); - GameRegistry.registerWorldGenerator(new NetherGenMineable(BlockHandler.BlockBase.blockID, 10, Rarity.REDSOULSTONE)); - } -} diff --git a/common/MysticOres/Worldgen/NetherGenHelper.java b/common/MysticOres/Worldgen/NetherGenHelper.java index 9e1957b..94734be 100644 --- a/common/MysticOres/Worldgen/NetherGenHelper.java +++ b/common/MysticOres/Worldgen/NetherGenHelper.java @@ -1,23 +1,24 @@ package mysticores.worldgen; -import java.util.Random; - import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.util.MathHelper; import net.minecraft.world.World; import net.minecraft.world.gen.feature.WorldGenerator; +import java.util.Random; + public class NetherGenHelper extends WorldGenerator { - private int minableBlockId; + private Block minableBlockId; private int minableBlockMeta = 0; private int numberOfBlocks; - public NetherGenHelper(int par1, int par2) { + public NetherGenHelper(Block par1, int par2) { this.minableBlockId = par1; this.numberOfBlocks = par2; } - public NetherGenHelper(int id, int meta, int number) { + public NetherGenHelper(Block id, int meta, int number) { this(id, number); minableBlockMeta = meta; } @@ -52,8 +53,8 @@ public class NetherGenHelper extends WorldGenerator { if (var39 * var39 + var42 * var42 < 1.0D) { for (int var44 = var34; var44 <= var37; ++var44) { double var45 = (var44 + 0.5D - var24) / (var28 / 2.0D); - int blocktoreplace = par1World.getBlockId(var38, var41, var44); - if (var39 * var39 + var42 * var42 + var45 * var45 < 1.0D && blocktoreplace == Block.netherrack.blockID) { + Block blocktoreplace = par1World.getBlock(var38, var41, var44); + if (var39 * var39 + var42 * var42 + var45 * var45 < 1.0D && blocktoreplace == Blocks.netherrack) { par1World.setBlock(var38, var41, var44, this.minableBlockId, minableBlockMeta, 3); } } diff --git a/common/MysticOres/Worldgen/NetherGenMineable.java b/common/MysticOres/Worldgen/NetherGenMineable.java deleted file mode 100644 index 0bc93a2..0000000 --- a/common/MysticOres/Worldgen/NetherGenMineable.java +++ /dev/null @@ -1,35 +0,0 @@ -package mysticores.worldgen; - -import java.util.Random; - -import net.minecraft.world.World; -import net.minecraft.world.chunk.IChunkProvider; -import net.minecraft.world.gen.feature.WorldGenerator; -import cpw.mods.fml.common.IWorldGenerator; - -public class NetherGenMineable implements IWorldGenerator { - private WorldGenerator helper; - - public NetherGenMineable(int blockId, int numBlocks) { - helper = new NetherGenHelper(blockId, numBlocks); - } - - public NetherGenMineable(int blockId, int meta, int numBlocks) { - helper = new NetherGenHelper(blockId, meta, numBlocks); - } - - @Override - public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { - if (world.provider.isHellWorld) - generateNether(world, random, chunkX * 16, chunkZ * 16); - } - - private void generateNether(World world, Random random, int i, int j) { - for (int j1 = 0; j1 < 50; j1++) { - int Xcoordinate = i + random.nextInt(16); - int Zcoordinate = j + random.nextInt(16); - int Ycoordinate = random.nextInt(256); - helper.generate(world, random, Xcoordinate, Ycoordinate, Zcoordinate); - } - } -} \ No newline at end of file diff --git a/common/MysticRuins/Config.java b/common/MysticRuins/Config.java index 032b225..bf1bb68 100644 --- a/common/MysticRuins/Config.java +++ b/common/MysticRuins/Config.java @@ -1,37 +1,175 @@ package mysticruins; -import java.io.File; -import java.util.ArrayList; -import java.util.List; +import cpw.mods.fml.common.registry.GameData; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.WeightedRandom; +import net.minecraft.world.biome.BiomeGenBase; +import net.minecraftforge.common.BiomeDictionary; +import net.minecraftforge.common.BiomeDictionary.Type; +import net.minecraftforge.common.DungeonHooks.DungeonMob; +import net.minecraftforge.common.config.Configuration; -import net.minecraftforge.common.Configuration; +import java.io.File; +import java.util.*; public class Config { public static Configuration config; public static int RuinRarity; public static int DunRarity; - public static List ruinAllowId = new ArrayList(); - public static List dungeonAllowId = new ArrayList(); + public static Set[] allowId = new HashSet[4]; + public static final String[] allows = { "Ruin allowed dimension id", "Dungeon allowed dimension id", "Ruin allowed biome id", "Dungeon allowed biome id" }; + public static Set[] allowType = new HashSet[2]; + public static List dungeonMobs = new ArrayList(); + public static final String commonItems = "iron_pickaxe,iron_axe,iron_sword,iron_shovel,gold_ingot,iron_ingot"; + public static final String rareItems = "ender_pearl:4,diamond,emerald,golden_apple,gold_ingot,iron_ingot"; + + public static void addDungeonMob(String name, int rarity) { + for (DungeonMob mob : dungeonMobs) { + if (name.equals(mob.type)) { + mob.itemWeight += rarity; + return; + } + } + dungeonMobs.add(new DungeonMob(rarity, name)); + } + + public static String getRandomDungeonMob(Random rand) { + DungeonMob mob = (DungeonMob) WeightedRandom.getRandomItem(rand, dungeonMobs); + if (mob == null) { + return ""; + } + return mob.type; + } public static void initialize(File file) { config = new Configuration(file); - config.load(); - RuinRarity = config.get("General", "Ruin Rarity", 2).getInt(); - DunRarity = config.get("General", "Mystic Dungeon Rarity", 1).getInt(); - String[] ID = config.get("General", "Ruin allowed dimension id", "0,").getString().split(","); - for (String txt : ID) { - try { - ruinAllowId.add(Integer.parseInt(txt.trim())); - } catch (NumberFormatException e) { + MysticRuins.ENABLE = config.get("General", "Enable", true).getBoolean(true); + String[] mobs = config.get("DungeonMobs", "Spawner Type & Relative Chance", "Skeleton-50,Spider-50,Zombie-20,Cavepider-10,Blaze-1", "MobName-RelativeWeight").getString().split(","); + String[] mob; + for (String txt : mobs) { + mob = txt.split("-"); + if (mob.length == 2) { + try { + addDungeonMob(mob[0].trim(), Integer.parseInt(mob[1].trim())); + } catch (NumberFormatException e) { + } } } - ID = config.get("General", "Dungeon allowed dimension id", "0,").getString().split(","); - for (String txt : ID) { - try { - dungeonAllowId.add(Integer.parseInt(txt.trim())); - } catch (NumberFormatException e) { + setChest("Common Items", commonItems, ChestFiller.valuables); + setChest("Rare Items", rareItems, ChestFiller.rares); + StringBuilder build = new StringBuilder("Available biome tags are: "); + for (Type t : Type.values()) { + build.append(t); + build.append(","); + } + config.addCustomCategoryComment("General", build.toString()); + RuinRarity = config.get("General", "Ruin Rarity", 200, "Chance per chunk : lower to make rarer").getInt(); + DunRarity = config.get("General", "Mystic Dungeon Rarity", 100, "Chance per chunk : lower to make rarer").getInt(); + String[] ID; + for (int i = 0; i < allows.length; i++) { + ID = config + .get("General", allows[i], i < 2 ? "0,[2;10]" : "ALL,-WATER", + i < 2 ? "Use [id1;id2] to add a range of id, prefix with - to exclude" : "Use ALL or * for all biomes, select with biome id or biome tags, prefix with - to exclude") + .getString().split(","); + allowId[i] = new HashSet(); + if (i > 1) { + allowType[i - 2] = new HashSet(); + } + for (String txt : ID) { + if (i > 1 && txt.startsWith("-")) { + txt = txt.substring(1).trim(); + try { + allowId[i].remove(Integer.parseInt(txt)); + } catch (NumberFormatException e) { + try { + allowType[i - 2].remove(Type.valueOf(txt.toUpperCase())); + } catch (IllegalArgumentException l) { + } + } + } else if (i < 2 && txt.contains("[") && txt.contains("]")) { + boolean remove = txt.trim().startsWith("-"); + String[] results = txt.substring(txt.indexOf("[")+1, txt.indexOf("]")).split(";"); + if (results.length == 2) { + try { + int a = Integer.parseInt(results[0]); + int b = Integer.parseInt(results[1]); + int c; + if (a > b) { + c = a; + a = b; + b = c; + } + for (int x = a; x <= b; x++) { + if (remove) { + allowId[i].remove(x); + } else { + allowId[i].add(x); + } + } + } catch (NumberFormatException n) { + } + } + } else { + try { + int j = Integer.parseInt(txt.trim()); + allowId[i].add(j); + if (i > 1) { + allowType[i - 2].addAll(Arrays.asList(BiomeDictionary.getTypesForBiome(BiomeGenBase.getBiomeGenArray()[j]))); + } + } catch (NumberFormatException e) { + if (i > 1) { + if (txt.equals("*") || txt.equalsIgnoreCase("ALL")) { + for (int j = 0; j < BiomeGenBase.getBiomeGenArray().length; j++) { + allowId[i].add(j); + } + for (Type t : Type.values()) { + allowType[i - 2].add(t); + } + } else { + try { + Type type = Type.valueOf(txt.toUpperCase()); + allowType[i - 2].add(type); + for (BiomeGenBase biome : BiomeDictionary.getBiomesForType(type)) { + allowId[i].add(biome.biomeID); + } + } catch (IllegalArgumentException l) { + } + } + } + } + } + } + } + if(config.hasChanged()) + config.save(); + } + + private static void setChest(String type, String list, List valuables) { + String[] items = config.get("Chests", type, list, "itemname:stacksize:damage").getString().split(","); + String[] item; + for (String txt : items) { + item = txt.split(":"); + Item id; + int amount = 1, data = 0; + try { + switch (item.length) { + case 3: + data = Integer.parseInt(item[2]); + case 2: + amount = Integer.parseInt(item[1]); + case 1: + id = GameData.itemRegistry.get(item[0]); + break; + default: + continue; + } + } catch (NumberFormatException n) { + continue; + } + if (id != null && amount > 0 && data >= 0) { + valuables.add(new ItemStack(id, amount, data)); } } - config.save(); } } \ No newline at end of file diff --git a/common/MysticRuins/MysticRuins.java b/common/MysticRuins/MysticRuins.java index a176bee..9004538 100644 --- a/common/MysticRuins/MysticRuins.java +++ b/common/MysticRuins/MysticRuins.java @@ -5,11 +5,13 @@ import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.event.FMLPreInitializationEvent; import cpw.mods.fml.common.registry.GameRegistry; -@Mod(modid = "MysticRuins", name = "Mystic Ruins", version = "0.1") -public class MysticRuins { +@Mod(modid = "mysticruins", name = "Mystic Ruins", version = "0.1") +public final class MysticRuins { + public static boolean ENABLE = true; @EventHandler public void preInit(FMLPreInitializationEvent event) { Config.initialize(event.getSuggestedConfigurationFile()); - GameRegistry.registerWorldGenerator(new WorldGenMystic()); + if(ENABLE) + GameRegistry.registerWorldGenerator(new WorldGenMystic(), 20); } } diff --git a/common/MysticRuins/StructureMysticDungeon.java b/common/MysticRuins/StructureMysticDungeon.java index e25958c..cc1522d 100644 --- a/common/MysticRuins/StructureMysticDungeon.java +++ b/common/MysticRuins/StructureMysticDungeon.java @@ -1,1884 +1,1806 @@ package mysticruins; -import java.util.Random; - import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.tileentity.TileEntityMobSpawner; import net.minecraft.world.World; -import net.minecraft.world.WorldType; import net.minecraft.world.gen.feature.WorldGenerator; +import java.util.Random; + public class StructureMysticDungeon extends WorldGenerator { public StructureMysticDungeon() { } @Override public boolean generate(World world, Random random, int i, int j, int k) { - if (world.getWorldInfo().getTerrainType() != WorldType.FLAT) { - int l = random.nextInt(100); - if (l >= 4) { - return false; + int j1 = (i + random.nextInt(8)) - random.nextInt(8); + int k1 = (j + random.nextInt(4)) - random.nextInt(4); + int l1 = (k + random.nextInt(8)) - random.nextInt(8); + boolean flag = false; + if (k1 <= 0) { + return false; + } + if (world.isAirBlock(j1 - 1, k1 + 1, l1) && world.isAirBlock(j1 - 1, k1 + 1, l1 + 1) && world.isAirBlock(j1 - 1, k1 + 2, l1) && world.isAirBlock(j1 - 1, k1 + 2, l1 + 1) + && world.getBlock(j1, k1, l1) == Blocks.stone && world.getBlock(j1, k1, l1 + 1) == Blocks.stone && world.getBlock(j1 - 1, k1, l1) == Blocks.stone + && world.getBlock(j1 - 1, k1, l1 + 1) == Blocks.stone && world.getBlock(j1, k1 + 1, l1) == Blocks.stone + && world.getBlock(j1, k1 + 1, l1 + 1) == Blocks.stone) + flag = true; + if (!flag) { + return false; + } + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1 - 1, k1 + 1, l1 + 2); + setBlock(world, j1 - 1, k1 + 1, l1 + 3); + setBlock(world, j1 - 1, k1 + 2, l1 + 2); + for (int y = k1 + 1; y < k1 + 4; y++) { + for (int x = 1; x < 6; x++) { + setBlock(world, j1 - x, y, l1); + setBlock(world, j1 - x, y, l1 + 1); + setBlock(world, j1 - x, y, l1 - 1); } - for (int i1 = 0; i1 < 1; i1++) { - int j1 = (i + random.nextInt(8)) - random.nextInt(8); - int k1 = (j + random.nextInt(4)) - random.nextInt(4); - int l1 = (k + random.nextInt(8)) - random.nextInt(8); - boolean flag = false; - /* - * if (world.isAirBlock(j1 - 1, k1 + 1, l1) && - * world.isAirBlock(j1 - 1, k1 + 1, l1 + 1) && - * world.isAirBlock(j1 - 1, k1 + 2, l1) && world.isAirBlock(j1 - - * 1, k1 + 2, l1 + 1) && world.getBlockId(j1, k1, l1) == - * Block.stone.blockID && world.getBlockId(j1, k1, l1 + 1) == - * Block.stone.blockID && world.getBlockId(j1 - 1, k1, l1) == - * Block.stone.blockID && world.getBlockId(j1 - 1, k1, l1 + 1) - * == Block.stone.blockID && world.getBlockId(j1, k1 + 1, l1) == - * Block.stone.blockID && world.getBlockId(j1, k1 + 1, l1 + 1) - * == Block.stone.blockID) - */ - flag = true; - if (!flag) { - continue; - } - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1 - 1, k1 + 1, l1 + 2, 0); - world.setBlock(j1 - 1, k1 + 1, l1 + 3, 0); - world.setBlock(j1 - 1, k1 + 2, l1 + 2, 0); - for (int y = k1 + 1; y < k1 + 4; y++) { - for (int x = 1; x < 6; x++) { - world.setBlock(j1 - x, y, l1, 0); - world.setBlock(j1 - x, y, l1 + 1, 0); - world.setBlock(j1 - x, y, l1 - 1, 0); - } - } - world.setBlock(j1 - 2, k1 + 1, l1 + 2, 0); - for (int x = 6; x < 17; x++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1 - x, k1 + y, l1, 0); - } - } - world.setBlock(j1 - 15, k1 + 14, l1, 0); - int i2 = random.nextInt(100); - if (i2 <= 40) { - for (int z = 1; z < 9; z++) { - world.setBlock(j1 - 16, k1 + 11, l1 - z, 0); - world.setBlock(j1 - 16, k1 + 12, l1 - z, 0); - } - world.setBlock(j1 - 16, k1 + 13, l1 - 8, 0); - world.setBlock(j1 - 16, k1 + 14, l1 - 8, 0); - for (int z = 0; z < 5; z++) { - for (int y = 12; y < 16; y++) { - world.setBlock(j1 - 16, k1 + y + z, l1 - 9 + z, 0); - } - } - world.setBlock(j1 - 16, k1 + 20, l1 - 13, 0); - int j2 = random.nextInt(100); - if (j2 <= 20) { - for (int x = 0; x < 3; x++) { - for (int z = 15; z < 18; z++) { - world.setBlock(j1 - 15 - x, k1 + 17, l1 - z, 0); - world.setBlock(j1 - 15 - x, k1 + 18, l1 - z, 0); - } - } - world.setBlock(j1 - 16, k1 + 16, l1 - 15, Block.blockLapis.blockID); - world.setBlock(j1 - 16, k1 + 16, l1 - 16, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 16, k1 + 16, l1 - 17, Block.blockLapis.blockID); - for (int z = 15; z < 18; z++) { - world.setBlock(j1 - 15, k1 + 16, l1 - z, Block.blockLapis.blockID); - world.setBlock(j1 - 17, k1 + 16, l1 - z, Block.blockLapis.blockID); - } - world.setBlock(j1 - 16, k1 + 17, l1 - 16, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1 - 16, k1 + 17, l1 - 16)); - } - } - for (int z = 0; z < 12; z++) { - for (int y = k1 + 12 + z; y < k1 + 16 + z; y++) { - world.setBlock(j1 - 16, y, l1 + 1 + z, 0); - } - } - world.setBlock(j1 - 16, k1 + 24, l1 + 9, 0); - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1, Block.cobblestoneMossy.blockID); - int k2 = random.nextInt(100); - if (k2 <= 40) { - world.setBlock(j1 - 1, k1 + 3, l1, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 3, l1 + 1, Block.vine.blockID); - world.setBlock(j1 - 2, k1 + 3, l1 - 1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 3, l1 + 2, Block.vine.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 1, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 2, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 + 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 1, l1 + 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - int l2 = random.nextInt(100); - if (l2 <= 30) { - world.setBlock(j1 - 1, k1 + 3, l1, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 3, l1 + 2, Block.vine.blockID); - world.setBlock(j1 - 2, k1 + 3, l1 - 1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 3, l1 + 1, Block.vine.blockID); - world.setBlock(j1 - 5, k1 + 3, l1, Block.vine.blockID); - } - int i3 = random.nextInt(100); - if (i3 <= 40) { - for (int z = 2; z < 10; z++) { - world.setBlock(j1, k1 + 1, l1 - z, 0); - world.setBlock(j1, k1 + 2, l1 - z, 0); - } - for (int z = 0; z < 14; z++) { - for (int y = k1 + 1 + z; y < k + 5 + z; y++) { - world.setBlock(j1, y, l1 - 10 - z, 0); - } - } - world.setBlock(j1, k1 + 15, l1 - 20, 0); - world.setBlock(j1, k1 + 16, l1 - 21, 0); - int j3 = random.nextInt(100); - if (j3 <= 20) { - for (int x = -1; x < 2; x++) { - world.setBlock(j1 + x, k1 + 15, l1 - 25, 0); - world.setBlock(j1 + x, k1 + 16, l1 - 25, 0); - world.setBlock(j1 + x, k1 + 15, l1 - 26, 0); - world.setBlock(j1 + x, k1 + 16, l1 - 26, 0); - world.setBlock(j1 + x, k1 + 15, l1 - 27, 0); - world.setBlock(j1 + x, k1 + 16, l1 - 27, 0); - } - world.setBlock(j1 - 16, k1 + 14, l1 - 15, 0); - world.setBlock(j1 - 16, k1 + 14, l1 - 16, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 16, k1 + 14, l1 - 17, 0); - world.setBlock(j1 - 15, k1 + 14, l1 - 15, 0); - world.setBlock(j1 - 15, k1 + 14, l1 - 16, 0); - world.setBlock(j1 - 15, k1 + 14, l1 - 17, 0); - world.setBlock(j1 - 17, k1 + 14, l1 - 15, 0); - world.setBlock(j1 - 17, k1 + 14, l1 - 16, 0); - world.setBlock(j1 - 17, k1 + 14, l1 - 17, 0); - world.setBlock(j1 - 16, k1 + 15, l1 - 16, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1 - 16, k1 + 15, l1 - 16)); - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 1, l1 + 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 3, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - for (int y = 1; y < 4; y++) { - world.setBlock(j1, k1 + y, l1, 0); - world.setBlock(j1, k1 + y, l1 + 1, 0); - world.setBlock(j1, k1 + y, l1 - 1, 0); - } - world.setBlock(j1, k1 + 1, l1 + 2, 0); - world.setBlock(j1, k1 + 1, l1 - 2, 0); - world.setBlock(j1, k1 + 2, l1 + 2, 0); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - for (int y = 1; y < 4; y++) { - for (int z = -2; z < 3; z++) { - world.setBlock(j1, k1 + y, l1 + z, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 3, 0); - world.setBlock(j1, k1 + 3, l1 - 3, 0); - world.setBlock(j1, k1 + 1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1, Block.cobblestoneMossy.blockID); - j1++; - int k3 = random.nextInt(2) + 1; - if (k3 == 1) { - int l3 = random.nextInt(2) + 1; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int y = 1; y < 5; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 + y, l1 + z, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestoneMossy.blockID); - if (l3 == 1) { - int k4 = random.nextInt(100); - if (k4 <= 60) { - for (int u = 1; u < 4; u++) { - world.setBlock(j1, k1 + u, l1 + u, Block.bookShelf.blockID); - } - } - } - if (l3 == 2) { - int l4 = random.nextInt(100); - if (l4 <= 40) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.blockIron.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.blockIron.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.blockIron.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, 0); - world.setBlock(j1, k1 + 3, l1 + 2, 0); - world.setBlock(j1, k1 + 1, l1 + 3, 0); - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestone.blockID); - if (l3 == 2) { - int i5 = random.nextInt(100); - if (i5 <= 40) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.blockIron.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.blockIron.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, 0); - world.setBlock(j1, k1 + 1, l1 + 3, 0); - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestone.blockID); - if (l3 == 1) { - int j5 = random.nextInt(100); - if (j5 <= 15) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 1, l1 + 1); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Zombie"); - } - world.setBlock(j1, k1 + 2, l1 + 1, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1, k1 + 2, l1 + 1)); - world.setBlock(j1, k1 + 3, l1 + 1, Block.mobSpawner.blockID); - TileEntityMobSpawner spawnerII = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 3, l1 + 1); - if (spawnerII != null) { - spawnerII.getSpawnerLogic().setMobID("CaveSpider"); - } - world.setBlock(j1, k1 + 1, l1 + 2, 0); - world.setBlock(j1, k1 + 2, l1 + 2, 0); - world.setBlock(j1, k1 + 3, l1 + 2, 0); - world.setBlock(j1, k1 + 1, l1 + 3, 0); - world.setBlock(j1, k1 + 2, l1 + 3, 0); - world.setBlock(j1, k1 + 3, l1 + 3, 0); - } - world.setBlock(j1, k1 + 1, l1 - 2, Block.planks.blockID); - world.setBlock(j1, k1 + 1, l1 - 3, Block.planks.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestoneMossy.blockID); - if (l3 == 1) { - world.setBlock(j1, k1 + 1, l1 - 2, Block.planks.blockID); - world.setBlock(j1, k1 + 1, l1 - 3, Block.planks.blockID); - } - if (l3 == 2) { - int k5 = random.nextInt(100); - if (k5 <= 30) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.blockIron.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.blockIron.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, Block.blockIron.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 1, l1 + 3); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Creeper"); - } - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 5, Block.cobblestoneMossy.blockID); - if (l3 == 1) { - int l5 = random.nextInt(100); - if (l5 <= 60) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 3, l1 + 1, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 2, l1 + 2); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Skeleton"); - } - world.setBlock(j1, k1 + 3, l1 + 2, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 2, l1 + 3, Block.bookShelf.blockID); - world.setBlock(j1, k1 + 3, l1 + 3, Block.bookShelf.blockID); - } - world.setBlock(j1, k1 + 1, l1 - 2, Block.planks.blockID); - world.setBlock(j1, k1 + 1, l1 - 3, Block.planks.blockID); - } - int i6 = random.nextInt(100); - if (i6 <= 30) { - world.setBlock(j1 - 1, k1 + 4, l1 + 3, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 4, l1 + 2, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 4, l1 - 1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 4, l1 + 1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 4, l1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 4, l1 - 3, Block.vine.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestone.blockID); - if (l3 == 2) { - int l6 = random.nextInt(100); - if (l6 <= 30) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.blockGold.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 1, l1 + 2); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Blaze"); - } - world.setBlock(j1, k1 + 1, l1 + 3, Block.blockGold.blockID); - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 - 5, Block.cobblestone.blockID); - if (l3 == 1) { - int i7 = random.nextInt(100); - if (i7 <= 60) { - for (int y = 1; y < 4; y++) { - for (int z = 1; z < 4; z++) { - world.setBlock(j1, k1 + y, l1 + z, Block.bookShelf.blockID); - } - } - } - } - if (l3 == 2) { - int j7 = random.nextInt(100); - if (j7 <= 20) { - world.setBlock(j1, k1 + 1, l1 + 1, Block.blockGold.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.blockGold.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.blockGold.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, Block.blockGold.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.blockGold.blockID); - } - int j8 = random.nextInt(100); - if (j8 <= 30) { - world.setBlock(j1, k1 + 1, l1 - 1, 0); - world.setBlock(j1, k1 + 2, l1 - 1, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1, k1 + 2, l1 - 1); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Zombie"); - } - world.setBlock(j1, k1 + 1, l1 - 2, 0); - world.setBlock(j1, k1 + 2, l1 - 2, 0); - world.setBlock(j1 - 1, k1 + 1, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 2, l1 - 2, 0); - world.setBlock(j1 - 1, k1 + 1, l1 - 2, 0); - } - int j9 = random.nextInt(100); - if (j9 <= 10) { - world.setBlock(j1 - 3, k1 + 1, l1 - 1, Block.blockDiamond.blockID); - world.setBlock(j1 - 3, k1 + 1, l1 - 2, Block.blockDiamond.blockID); - } - int j10 = random.nextInt(100); - if (j10 <= 10) { - world.setBlock(j1 - 3, k1 + 1, l1 - 2, Block.blockDiamond.blockID); - } - int j11 = random.nextInt(100); - if (j11 <= 15) { - world.setBlock(j1 - 5, k1 + 1, l1 - 2, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1 - 5, k1 + 1, l1 - 2)); - world.setBlock(j1 - 5, k1 + 1, l1 - 3, 0); - } - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - for (int u = 0; u < 5; u++) { - for (int y = 1; y < 5; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 2, l1 - 5, Block.cobblestone.blockID); - int k7 = random.nextInt(100); - if (k7 <= 30) { - world.setBlock(j1 - 2, k1 + 5, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 5, l1 - 3, 0); - world.setBlock(j1 - 2, k1 + 5, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 5, l1 - 2, 0); - world.setBlock(j1 - 3, k1 + 5, l1 - 2, 0); - world.setBlock(j1 - 5, k1 + 5, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 6, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 6, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 6, l1 - 2, 0); - world.setBlock(j1 - 3, k1 + 6, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 7, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 7, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 7, l1 - 2, 0); - world.setBlock(j1 - 3, k1 + 7, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 8, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 8, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 8, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 9, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 9, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 9, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 10, l1 - 1, 0); - world.setBlock(j1 - 1, k1 + 10, l1 - 2, 0); - world.setBlock(j1 - 2, k1 + 1, l1 - 2, Block.stone.blockID); - world.setBlock(j1 - 2, k1 + 1, l1 - 3, Block.gravel.blockID); - world.setBlock(j1 - 1, k1 + 1, l1 - 2, Block.stone.blockID); - world.setBlock(j1 - 1, k1 + 1, l1 - 3, Block.gravel.blockID); - world.setBlock(j1 - 2, k1 + 1, l1 - 1, Block.stone.blockID); - world.setBlock(j1 - 3, k1 + 1, l1 - 2, Block.stone.blockID); - world.setBlock(j1 - 2, k1 + 2, l1 - 2, Block.stone.blockID); - world.setBlock(j1 - 2, k1 + 2, l1 - 1, Block.gravel.blockID); - world.setBlock(j1 - 2, k1 + 3, l1 - 2, Block.stone.blockID); - world.setBlock(j1 - 2, k1 + 3, l1 - 1, Block.stone.blockID); - world.setBlock(j1 - 4, k1 + 3, l1 - 1, Block.gravel.blockID); - world.setBlock(j1 - 2, k1 + 3, l1, Block.gravel.blockID); - world.setBlock(j1 - 1, k1 + 3, l1 - 3, Block.stone.blockID); - } - } - if (k3 == 2) { - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - for (int u = 0; u < 9; u++) { - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 - 9, Block.cobblestoneMossy.blockID); - int i4 = random.nextInt(100); - if (i4 <= 60) { - for (int y = 0; y < 15; y++) { - world.setBlock(j1 + 7, k1 - y, l1, 0); - } - world.setBlock(j1, k1 - 13, l1 + 1, 0); - world.setBlock(j1, k1 - 13, l1 - 1, 0); - world.setBlock(j1, k1 - 14, l1 + 1, 0); - world.setBlock(j1, k1 - 14, l1 - 1, 0); - world.setBlock(j1 + 1, k1 - 13, l1 + 1, 0); - world.setBlock(j1 + 1, k1 - 13, l1 - 1, 0); - world.setBlock(j1 + 1, k1 - 14, l1 + 1, 0); - world.setBlock(j1 + 1, k1 - 14, l1 - 1, 0); - } - int j6 = random.nextInt(100); - if (j6 <= 70) { - for (int y = 0; y < 13; y++) { - world.setBlock(j1 + 7, k1 - y, l1 + 6, 0); - } - world.setBlock(j1, k1 - 11, l1 + 7, 0); - world.setBlock(j1, k1 - 11, l1 + 5, 0); - world.setBlock(j1, k1 - 12, l1 + 7, 0); - world.setBlock(j1, k1 - 12, l1 + 5, 0); - world.setBlock(j1 + 1, k1 - 11, l1 + 7, 0); - world.setBlock(j1 + 1, k1 - 11, l1 + 5, 0); - world.setBlock(j1 + 1, k1 - 12, l1 + 7, 0); - world.setBlock(j1 + 1, k1 - 12, l1 + 5, 0); - } - int l7 = random.nextInt(100); - if (l7 <= 50) { - for (int y = 0; y < 17; y++) { - world.setBlock(j1 + 7, k1 - y, l1 - 4, 0); - } - world.setBlock(j1 + 7, k1 - 15, l1 - 5, 0); - world.setBlock(j1 + 7, k1 - 15, l1 - 3, 0); - world.setBlock(j1 + 7, k1 - 16, l1 - 5, 0); - world.setBlock(j1 + 7, k1 - 16, l1 - 3, 0); - world.setBlock(j1 + 8, k1 - 15, l1 - 5, 0); - world.setBlock(j1 + 8, k1 - 15, l1 - 3, 0); - world.setBlock(j1 + 8, k1 - 16, l1 - 5, 0); - world.setBlock(j1 + 8, k1 - 16, l1 - 3, 0); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestoneMossy.blockID); - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + 6, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + y, l1 - 6, Block.blockNetherQuartz.blockID, 2, 2); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1 + 3, l1, 0); - world.setBlock(j1, k1 + 4, l1, 0); - world.setBlock(j1, k1 + 5, l1, 0); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int u = 1; u < 9; u++) { - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + u, 0); - world.setBlock(j1, k1 + y, l1 - u, 0); - } - } - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 + 1, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 - 1, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 - 2, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1 - 3, Block.stoneSingleSlab.blockID); - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.stoneSingleSlab.blockID); - for (int z = -2; z < 3; z++) { - world.setBlock(j1, k1, l1 + z, Block.obsidian.blockID); - world.setBlock(j1, k1 + 1, l1 + z, Block.obsidian.blockID); - world.setBlock(j1, k1 + 2, l1 + z, Block.obsidian.blockID); - } - world.setBlock(j1, k1 + 1, l1 - 3, Block.stoneSingleSlab.blockID); - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + 6, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + y, l1 - 6, Block.blockNetherQuartz.blockID, 2, 2); - } - int k8 = random.nextInt(100); - if (k8 <= 15) { - world.setBlock(j1, k1 + 1, l1 - 7, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1, k1 + 1, l1 - 7)); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 4, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.stoneSingleSlab.blockID); - world.setBlock(j1, k1 + 1, l1, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1, k1 + 1, l1)); - for (int z = -2; z < 3; z++) { - world.setBlock(j1, k1, l1 + z, Block.obsidian.blockID); - if (z != 0) - world.setBlock(j1, k1 + 1, l1 + z, Block.obsidian.blockID); - world.setBlock(j1, k1 + 2, l1 + z, Block.obsidian.blockID); - } - world.setBlock(j1, k1 + 1, l1 - 3, Block.stoneSingleSlab.blockID); - int k9 = random.nextInt(100); - if (k9 <= 75) { - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1 + 1, l1 + 1, 0); - world.setBlock(j1, k1 + 2, l1 + 1, 0); - world.setBlock(j1, k1 + 1, l1 - 1, 0); - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1 - 1, k1 + 1, l1, 0); - world.setBlock(j1 - 1, k1 + 2, l1, 0); - world.setBlock(j1 - 1, k1 + 2, l1 - 1, 0); - world.setBlock(j1 - 3, k1 + 1, l1 + 2, Block.obsidian.blockID); - world.setBlock(j1 - 2, k1 + 1, l1, Block.obsidian.blockID); - world.setBlock(j1 - 3, k1 + 1, l1 - 3, Block.obsidian.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.stoneSingleSlab.blockID); - for (int z = -2; z < 3; z++) { - world.setBlock(j1, k1, l1 + z, Block.obsidian.blockID); - world.setBlock(j1, k1 + 1, l1 + z, Block.obsidian.blockID); - world.setBlock(j1, k1 + 2, l1 + z, Block.obsidian.blockID); - } - world.setBlock(j1, k1 + 1, l1 - 3, Block.stoneSingleSlab.blockID); - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + 6, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + y, l1 - 6, Block.blockNetherQuartz.blockID, 2, 2); - } - int k10 = random.nextInt(100); - if (k10 <= 50) { - world.setBlock(j1, k1 + 1, l1 + 7, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 2, k1 + 1, l1 + 8, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 1, k1 + 1, l1 + 5, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + 2, l1 + 6, 0); - world.setBlock(j1, k1 + 3, l1 + 6, 0); - world.setBlock(j1, k1 + 4, l1 + 6, 0); - } - int k11 = random.nextInt(100); - if (k11 <= 30) { - world.setBlock(j1 + 1, k1 + 5, l1 + 3, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 5, l1 + 3, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 6, l1 + 2, Block.vine.blockID); - world.setBlock(j1 - 1, k1 + 5, l1 + 2, Block.vine.blockID); - world.setBlock(j1 - 2, k1 + 7, l1 - 1, Block.vine.blockID); - world.setBlock(j1 - 2, k1 + 7, l1 + 1, Block.vine.blockID); - world.setBlock(j1 - 2, k1 + 6, l1 + 1, Block.vine.blockID); - world.setBlock(j1 - 3, k1 + 8, l1, Block.vine.blockID); - world.setBlock(j1 + 1, k1 + 5, l1 - 3, Block.vine.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 4, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 - 9, Block.cobblestone.blockID); - for (int z = -3; z < 4; z++) { - world.setBlock(j1, k1 + 1, l1 + z, Block.stoneSingleSlab.blockID); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestone.blockID); - for (int y = 1; y < 6; y++) { - world.setBlock(j1, k1 + y, l1 + 6, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + y, l1 - 6, Block.blockNetherQuartz.blockID, 2, 2); - } - int j12 = random.nextInt(100); - if (j12 <= 50) { - world.setBlock(j1, k1 + 1, l1 - 7, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 1, k1 + 1, l1 - 8, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 3, k1 + 1, l1 - 5, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 + 3, l1 - 6, 0); - world.setBlock(j1, k1 + 4, l1 - 6, 0); - world.setBlock(j1, k1 + 5, l1 - 6, 0); - } - j1++; - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 8, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 6, l1, 0); - world.setBlock(j1, k1 + 6, l1 + 1, 0); - world.setBlock(j1, k1 + 6, l1 - 1, 0); - world.setBlock(j1, k1 + 6, l1 + 2, 0); - world.setBlock(j1, k1 + 6, l1 - 2, 0); - world.setBlock(j1, k1 + 7, l1, 0); - world.setBlock(j1, k1 + 7, l1 + 1, 0); - world.setBlock(j1, k1 + 7, l1 - 1, 0); - world.setBlock(j1, k1 + 8, l1, 0); - for (int y = 1; y < 6; y++) { - for (int z = -8; z < 9; z++) { - world.setBlock(j1, k1 + y, l1 + 1, 0); - } - } - world.setBlock(j1, k1 + 1, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 - 9, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 9, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 - 9, Block.cobblestone.blockID); - } - j1++; - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 1, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 2, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 3, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 3, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 + 1, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 + 2, l1 - 1, Block.cobblestoneMossy.blockID); - j1++; - for (int y = 1; y < 4; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 + y, l1 + z, 0); - } - } - world.setBlock(j1, k1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestone.blockID); - j1++; - for (int y = 1; y < 4; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 + y, l1 + z, 0); - } - } - world.setBlock(j1, k1, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1, l1 - 1, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1, l1, 0); - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - world.setBlock(j1, k1 + 3, l1, 0); - j1++; - world.setBlock(j1, k1 - 1, l1, 0); - world.setBlock(j1, k1, l1, 0); - world.setBlock(j1, k1 + 1, l1, 0); - world.setBlock(j1, k1 + 2, l1, 0); - j1++; - world.setBlock(j1, k1 - 2, l1, 0); - world.setBlock(j1, k1 - 1, l1, 0); - world.setBlock(j1, k1, l1, 0); - world.setBlock(j1, k1 + 1, l1, 0); - j1++; - world.setBlock(j1, k1 - 3, l1, 0); - world.setBlock(j1, k1 - 2, l1, 0); - world.setBlock(j1, k1 - 1, l1, 0); - world.setBlock(j1, k1, l1, 0); - j1++; - world.setBlock(j1, k1 - 4, l1, 0); - world.setBlock(j1, k1 - 3, l1, 0); - world.setBlock(j1, k1 - 2, l1, 0); - world.setBlock(j1, k1 - 1, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - world.setBlock(j1, k1 - 3, l1, 0); - world.setBlock(j1, k1 - 2, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - j1++; - for (int z = 0; z < 21; z++) { - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 4, l1, 0); - } - world.setBlock(j1, k1 - 4, l1 + 21, 0); - world.setBlock(j1, k1 - 5, l1 + 21, 0); - world.setBlock(j1, k1 - 6, l1 + 21, 0); - for (int z = 0; z < 8; z++) { - for (int y = 4; y < 7; y++) { - world.setBlock(j1, k1 - y - z, l1 + 22 + z, 0); - } - } - int j4 = random.nextInt(100); - if (j4 <= 20) { - for (int x = -1; x < 2; x++) { - world.setBlock(j1 + x, k1 - 12, l1 + 31, 0); - world.setBlock(j1 + x, k1 - 13, l1 + 31, 0); - world.setBlock(j1 + x, k1 - 12, l1 + 32, 0); - world.setBlock(j1 + x, k1 - 13, l1 + 32, 0); - world.setBlock(j1 + x, k1 - 12, l1 + 33, 0); - world.setBlock(j1 + x, k1 - 13, l1 + 33, 0); - } - world.setBlock(j1, k1 - 10, l1 + 31, Block.blockLapis.blockID); - world.setBlock(j1, k1 - 10, l1 + 32, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 + 33, Block.blockLapis.blockID); - world.setBlock(j1 + 1, k1 - 10, l1 + 31, Block.blockLapis.blockID); - world.setBlock(j1 + 1, k1 - 10, l1 + 32, Block.blockLapis.blockID); - world.setBlock(j1 + 1, k1 - 10, l1 + 33, Block.blockLapis.blockID); - world.setBlock(j1 - 1, k1 - 10, l1 + 31, Block.blockLapis.blockID); - world.setBlock(j1 - 1, k1 - 10, l1 + 32, Block.blockLapis.blockID); - world.setBlock(j1 - 1, k1 - 10, l1 + 33, Block.blockLapis.blockID); - world.setBlock(j1, k1 - 11, l1 + 32, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1, k1 - 11, l1 + 32)); - } - j1++; - world.setBlock(j1, k1 - 4, l1, 0); - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 6, l1, 0); - j1++; - world.setBlock(j1, k1 - 4, l1, 0); - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 6, l1, 0); - world.setBlock(j1, k1 - 7, l1, 0); - j1++; - world.setBlock(j1, k1 - 5, l1, 0); - world.setBlock(j1, k1 - 6, l1, 0); - world.setBlock(j1, k1 - 7, l1, 0); - world.setBlock(j1, k1 - 8, l1, 0); - j1++; - world.setBlock(j1, k1 - 6, l1, 0); - world.setBlock(j1, k1 - 7, l1, 0); - world.setBlock(j1, k1 - 8, l1, 0); - world.setBlock(j1, k1 - 9, l1, 0); - j1++; - world.setBlock(j1, k1 - 7, l1, 0); - world.setBlock(j1, k1 - 8, l1, 0); - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 10, l1, 0); - j1++; - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 10, l1, 0); - j1++; - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 10, l1, 0); - j1++; - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 10, l1, 0); - j1++; - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 10, l1, 0); - world.setBlock(j1, k1 - 8, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.stone.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 + 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 2, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 - 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 3; y++) { - for (int z = -1; z < 2; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 + 2, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 10, l1, 0); - world.setBlock(j1, k1 - 9, l1, 0); - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1, Block.cobblestoneMossy.blockID); - int k6 = random.nextInt(100); - if (k6 <= 30) { - world.setBlock(j1 - 1, k1 - 8, l1 + 3, Block.vine.blockID); - world.setBlock(j1 - 2, k1 - 8, l1, Block.vine.blockID); - world.setBlock(j1 - 2, k1 - 9, l1, Block.vine.blockID); - world.setBlock(j1 - 4, k1 - 8, l1 + 2, Block.vine.blockID); - world.setBlock(j1 - 6, k1 - 8, l1 - 1, Block.vine.blockID); - } - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 10, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 - 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestone.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - j1++; - world.setBlock(j1, k1 - 11, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 11, l1 - 2, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 11, l1 - 4, Block.cobblestoneMossy.blockID); - for (int y = 0; y < 4; y++) { - for (int z = -4; z < 5; z++) { - world.setBlock(j1, k1 - 10 - y, l1 + z, 0); - } - } - world.setBlock(j1, k1 - 10, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1, k1 - 9, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - 8, l1 + 5, Block.cobblestone.blockID); - int i8 = random.nextInt(2) + 1; - if (i8 == 1) { - for (int y = 0; y < 4; y++) { - world.setBlock(j1 - 2, k1 - 10 - y, l1, Block.cobblestone.blockID); - world.setBlock(j1 - 6, k1 - 10 - y, l1, Block.cobblestone.blockID); - world.setBlock(j1 - 10, k1 - 10 - y, l1, Block.cobblestone.blockID); - } - int l8 = random.nextInt(100); - if (l8 <= 50) { - world.setBlock(j1 - 1, k1 - 10, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 1, k1 - 9, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 1, k1 - 8, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 1, k1 - 10, l1 + 3, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 1, k1 - 9, l1 + 3, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 1, k1 - 8, l1 + 3, Block.stoneDoubleSlab.blockID); - } - int l9 = random.nextInt(100); - if (l9 <= 60) { - world.setBlock(j1 - 2, k1 - 10, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 2, k1 - 9, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 2, k1 - 8, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 2, k1 - 10, l1 + 3, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 2, k1 - 9, l1 + 3, Block.stoneDoubleSlab.blockID); - } - int l10 = random.nextInt(100); - if (l10 <= 70) { - world.setBlock(j1 - 3, k1 - 10, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 3, k1 - 9, l1 + 2, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 3, k1 - 10, l1 + 3, Block.stoneDoubleSlab.blockID); - world.setBlock(j1 - 3, k1 - 9, l1 + 3, Block.stoneDoubleSlab.blockID); - } - int l11 = random.nextInt(100); - if (l11 <= 40) { - world.setBlock(j1 - 1, k1 - 10, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 1, k1 - 9, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 1, k1 - 8, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 1, k1 - 10, l1 - 3, Block.brick.blockID); - world.setBlock(j1 - 1, k1 - 9, l1 - 3, Block.brick.blockID); - } - int k12 = random.nextInt(100); - if (k12 <= 50) { - world.setBlock(j1 - 2, k1 - 10, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 2, k1 - 9, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 2, k1 - 8, l1 - 2, Block.brick.blockID); - world.setBlock(j1 - 2, k1 - 10, l1 - 3, Block.brick.blockID); - world.setBlock(j1 - 2, k1 - 9, l1 - 3, Block.brick.blockID); - world.setBlock(j1 - 2, k1 - 8, l1 - 3, Block.brick.blockID); - } - int l12 = random.nextInt(100); - if (l12 <= 40) { - world.setBlock(j1 - 4, k1 - 10, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 4, k1 - 9, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 4, k1 - 10, l1 - 3, Block.netherBrick.blockID); - world.setBlock(j1 - 4, k1 - 9, l1 - 3, Block.netherBrick.blockID); - } - int i13 = random.nextInt(100); - if (i13 <= 40) { - world.setBlock(j1 - 5, k1 - 10, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 5, k1 - 9, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 5, k1 - 10, l1 - 3, Block.netherBrick.blockID); - world.setBlock(j1 - 5, k1 - 9, l1 - 3, Block.netherBrick.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 6, k1 - 9, l1 - 2, Block.netherBrick.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 - 3, Block.netherBrick.blockID); - } - int j13 = random.nextInt(100); - if (j13 <= 15) { - world.setBlock(j1 - 9, k1 - 10, l1 + 2, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1 - 9, k1 - 10, l1 + 2)); - } - int k13 = random.nextInt(100); - if (k13 <= 15) { - world.setBlock(j1 - 9, k1 - 10, l1 - 2, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1 - 9, k1 - 10, l1 - 2)); - } - } - if (i8 != 2) { - continue; - } - for (int y = 0; y < 4; y++) { - world.setBlock(j1 - 1, k1 - 10 - y, l1, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 1, k1 - 10 - y, l1 + 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 1, k1 - 10 - y, l1 - 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 3, k1 - 10 - y, l1, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 3, k1 - 10 - y, l1 + 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 3, k1 - 10 - y, l1 - 3, Block.blockNetherQuartz.blockID, 2, 2); - } - world.setBlock(j1 - 4, k1 - 10, l1, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1 - 4, k1 - 10, l1); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID("Zombie"); - } - world.setBlock(j1 - 8, k1 - 10, l1, Block.stoneSingleSlab.blockID); - world.setBlock(j1 - 8, k1 - 10, l1 + 1, Block.stoneSingleSlab.blockID); - world.setBlock(j1 - 8, k1 - 10, l1 - 1, Block.stoneSingleSlab.blockID); - world.setBlock(j1 - 5, k1 - 10, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 5, k1 - 10, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1 - 5, k1 - 10, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 6, k1 - 10, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 6, k1 - 10, l1 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 7, k1 - 10, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 7, k1 - 10, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 7, k1 - 10, l1 - 1, Block.cobblestone.blockID); - int i9 = random.nextInt(100); - if (i9 <= 30) { - world.setBlock(j1 - 6, k1 - 9, l1, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1 - 6, k1 - 9, l1)); - } - if (i9 <= 10) { - world.setBlock(j1 - 6, k1 - 9, l1, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1 - 6, k1 - 9, l1)); - } - for (int y = 0; y < 4; y++) { - world.setBlock(j1 - 9, k1 - 10 - y, l1, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 9, k1 - 10 - y, l1 + 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 9, k1 - 10 - y, l1 - 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 11, k1 - 10 - y, l1, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 11, k1 - 10 - y, l1 + 3, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 11, k1 - 10 - y, l1 - 3, Block.blockNetherQuartz.blockID, 2, 2); - } - int i10 = random.nextInt(100); - if (i10 <= 20) { - world.setBlock(j1 - 2, k1 - 10, l1 + 4, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1 - 2, k1 - 10, l1 + 4)); - } - int i11 = random.nextInt(100); - if (i11 <= 40) { - world.setBlock(j1 - 3, k1 - 9, l1 + 3, 0); - world.setBlock(j1 - 3, k1 - 8, l1 + 3, 0); - world.setBlock(j1 - 3, k1 - 7, l1 + 3, 0); - world.setBlock(j1 - 1, k1 - 10, l1 + 4, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 2, k1 - 10, l1 + 4, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1, k1 - 10, l1 + 2, Block.blockNetherQuartz.blockID, 2, 2); - } - int i12 = random.nextInt(100); - if (i12 <= 40) { - world.setBlock(j1 - 9, k1 - 9, l1 - 3, 0); - world.setBlock(j1 - 9, k1 - 8, l1 - 3, 0); - world.setBlock(j1 - 9, k1 - 7, l1 - 3, 0); - world.setBlock(j1 - 7, k1 - 10, l1 - 2, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 8, k1 - 10, l1 - 4, Block.blockNetherQuartz.blockID, 2, 2); - world.setBlock(j1 - 8, k1 - 10, l1 - 2, Block.blockNetherQuartz.blockID, 2, 2); - } - System.out.println((j1 - 8) + "," + (k1 - 10) + "," + (l1 - 2)); + } + setBlock(world, j1 - 2, k1 + 1, l1 + 2); + for (int x = 6; x < 17; x++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1 - x, k1 + y, l1); } } + setBlock(world, j1 - 15, k1 + 14, l1); + int i2 = random.nextInt(100); + if (i2 <= 40) { + for (int z = 1; z < 9; z++) { + setBlock(world, j1 - 16, k1 + 11, l1 - z); + setBlock(world, j1 - 16, k1 + 12, l1 - z); + } + setBlock(world, j1 - 16, k1 + 13, l1 - 8); + setBlock(world, j1 - 16, k1 + 14, l1 - 8); + for (int z = 0; z < 5; z++) { + for (int y = 12; y < 16; y++) { + setBlock(world, j1 - 16, k1 + y + z, l1 - 9 + z); + } + } + setBlock(world, j1 - 16, k1 + 20, l1 - 13); + int j2 = random.nextInt(100); + if (j2 <= 20) { + for (int x = 0; x < 3; x++) { + for (int z = 15; z < 18; z++) { + setBlock(world, j1 - 15 - x, k1 + 17, l1 - z); + setBlock(world, j1 - 15 - x, k1 + 18, l1 - z); + } + } + setBlock(world, j1 - 16, k1 + 16, l1 - 15, Blocks.lapis_block); + setBlock(world, j1 - 16, k1 + 16, l1 - 16, pickBlock(random)); + setBlock(world, j1 - 16, k1 + 16, l1 - 17, Blocks.lapis_block); + for (int z = 15; z < 18; z++) { + setBlock(world, j1 - 15, k1 + 16, l1 - z, Blocks.lapis_block); + setBlock(world, j1 - 17, k1 + 16, l1 - z, Blocks.lapis_block); + } + setBlock(world, j1 - 16, k1 + 17, l1 - 16, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1 - 16, k1 + 17, l1 - 16)); + } + } + for (int z = 0; z < 12; z++) { + for (int y = k1 + 12 + z; y < k1 + 16 + z; y++) { + setBlock(world, j1 - 16, y, l1 + 1 + z); + } + } + setBlock(world, j1 - 16, k1 + 24, l1 + 9); + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1, pickBlock(random)); + int k2 = random.nextInt(100); + if (k2 <= 40) { + setBlock(world, j1 - 1, k1 + 3, l1, Blocks.vine); + setBlock(world, j1 - 1, k1 + 3, l1 + 1, Blocks.vine); + setBlock(world, j1 - 2, k1 + 3, l1 - 1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 3, l1 + 2, Blocks.vine); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 1, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 2, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 1, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + int l2 = random.nextInt(100); + if (l2 <= 30) { + setBlock(world, j1 - 1, k1 + 3, l1, Blocks.vine); + setBlock(world, j1 - 1, k1 + 3, l1 + 2, Blocks.vine); + setBlock(world, j1 - 2, k1 + 3, l1 - 1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 3, l1 + 1, Blocks.vine); + setBlock(world, j1 - 5, k1 + 3, l1, Blocks.vine); + } + int i3 = random.nextInt(100); + if (i3 <= 40) { + for (int z = 2; z < 10; z++) { + setBlock(world, j1, k1 + 1, l1 - z); + setBlock(world, j1, k1 + 2, l1 - z); + } + for (int z = 0; z < 14; z++) { + for (int y = k1 + 1 + z; y < k + 5 + z; y++) { + setBlock(world, j1, y, l1 - 10 - z); + } + } + setBlock(world, j1, k1 + 15, l1 - 20); + setBlock(world, j1, k1 + 16, l1 - 21); + int j3 = random.nextInt(100); + if (j3 <= 20) { + for (int x = -1; x < 2; x++) { + setBlock(world, j1 + x, k1 + 15, l1 - 25); + setBlock(world, j1 + x, k1 + 16, l1 - 25); + setBlock(world, j1 + x, k1 + 15, l1 - 26); + setBlock(world, j1 + x, k1 + 16, l1 - 26); + setBlock(world, j1 + x, k1 + 15, l1 - 27); + setBlock(world, j1 + x, k1 + 16, l1 - 27); + } + setBlock(world, j1 - 16, k1 + 14, l1 - 15); + setBlock(world, j1 - 16, k1 + 14, l1 - 16, pickBlock(random)); + setBlock(world, j1 - 16, k1 + 14, l1 - 17); + setBlock(world, j1 - 15, k1 + 14, l1 - 15); + setBlock(world, j1 - 15, k1 + 14, l1 - 16); + setBlock(world, j1 - 15, k1 + 14, l1 - 17); + setBlock(world, j1 - 17, k1 + 14, l1 - 15); + setBlock(world, j1 - 17, k1 + 14, l1 - 16); + setBlock(world, j1 - 17, k1 + 14, l1 - 17); + setBlock(world, j1 - 16, k1 + 15, l1 - 16, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1 - 16, k1 + 15, l1 - 16)); + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 1, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 3, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + setBlock(world, j1, k1 + y, l1); + setBlock(world, j1, k1 + y, l1 + 1); + setBlock(world, j1, k1 + y, l1 - 1); + } + setBlock(world, j1, k1 + 1, l1 + 2); + setBlock(world, j1, k1 + 1, l1 - 2); + setBlock(world, j1, k1 + 2, l1 + 2); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + for (int y = 1; y < 4; y++) { + for (int z = -2; z < 3; z++) { + setBlock(world, j1, k1 + y, l1 + z); + } + } + setBlock(world, j1, k1 + 1, l1 + 3); + setBlock(world, j1, k1 + 3, l1 - 3); + setBlock(world, j1, k1 + 1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1, pickBlock(random)); + j1++; + int k3 = random.nextInt(2) + 1; + if (k3 == 1) { + int l3 = random.nextInt(2) + 1; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int y = 1; y < 5; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 + y, l1 + z); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + if (l3 == 1) { + int k4 = random.nextInt(100); + if (k4 <= 60) { + for (int u = 1; u < 4; u++) { + setBlock(world, j1, k1 + u, l1 + u, Blocks.bookshelf); + } + } + } + if (l3 == 2) { + int l4 = random.nextInt(100); + if (l4 <= 40) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.iron_block); + setBlock(world, j1, k1 + 2, l1 + 1, Blocks.iron_block); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.iron_block); + setBlock(world, j1, k1 + 2, l1 + 2); + setBlock(world, j1, k1 + 3, l1 + 2); + setBlock(world, j1, k1 + 1, l1 + 3); + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + if (l3 == 2) { + int i5 = random.nextInt(100); + if (i5 <= 40) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.iron_block); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.iron_block); + setBlock(world, j1, k1 + 2, l1 + 2); + setBlock(world, j1, k1 + 1, l1 + 3); + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + if (l3 == 1) { + int j5 = random.nextInt(100); + if (j5 <= 15) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 1, l1 + 1); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1, k1 + 2, l1 + 1, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1, k1 + 2, l1 + 1)); + setBlock(world, j1, k1 + 3, l1 + 1, Blocks.mob_spawner); + spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 3, l1 + 1); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1, k1 + 1, l1 + 2); + setBlock(world, j1, k1 + 2, l1 + 2); + setBlock(world, j1, k1 + 3, l1 + 2); + setBlock(world, j1, k1 + 1, l1 + 3); + setBlock(world, j1, k1 + 2, l1 + 3); + setBlock(world, j1, k1 + 3, l1 + 3); + } + setBlock(world, j1, k1 + 1, l1 - 2, Blocks.planks); + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.planks); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + if (l3 == 1) { + setBlock(world, j1, k1 + 1, l1 - 2, Blocks.planks); + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.planks); + } + if (l3 == 2) { + int k5 = random.nextInt(100); + if (k5 <= 30) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.iron_block); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.iron_block); + setBlock(world, j1, k1 + 2, l1 + 2, Blocks.iron_block); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 1, l1 + 3); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 5, pickBlock(random)); + if (l3 == 1) { + int l5 = random.nextInt(100); + if (l5 <= 60) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.bookshelf); + setBlock(world, j1, k1 + 2, l1 + 1, Blocks.bookshelf); + setBlock(world, j1, k1 + 3, l1 + 1, Blocks.bookshelf); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.bookshelf); + setBlock(world, j1, k1 + 2, l1 + 2, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 2, l1 + 2); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1, k1 + 3, l1 + 2, Blocks.bookshelf); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.bookshelf); + setBlock(world, j1, k1 + 2, l1 + 3, Blocks.bookshelf); + setBlock(world, j1, k1 + 3, l1 + 3, Blocks.bookshelf); + } + setBlock(world, j1, k1 + 1, l1 - 2, Blocks.planks); + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.planks); + } + int i6 = random.nextInt(100); + if (i6 <= 30) { + setBlock(world, j1 - 1, k1 + 4, l1 + 3, Blocks.vine); + setBlock(world, j1 - 1, k1 + 4, l1 + 2, Blocks.vine); + setBlock(world, j1 - 3, k1 + 4, l1 - 1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 4, l1 + 1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 4, l1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 4, l1 - 3, Blocks.vine); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + if (l3 == 2) { + int l6 = random.nextInt(100); + if (l6 <= 30) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.gold_block); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 1, l1 + 2); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.gold_block); + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 5, pickBlock(random)); + if (l3 == 1) { + int i7 = random.nextInt(100); + if (i7 <= 60) { + for (int y = 1; y < 4; y++) { + for (int z = 1; z < 4; z++) { + setBlock(world, j1, k1 + y, l1 + z, Blocks.bookshelf); + } + } + } + } + if (l3 == 2) { + int j7 = random.nextInt(100); + if (j7 <= 20) { + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.gold_block); + setBlock(world, j1, k1 + 2, l1 + 1, Blocks.gold_block); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.gold_block); + setBlock(world, j1, k1 + 2, l1 + 2, Blocks.gold_block); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.gold_block); + } + int j8 = random.nextInt(100); + if (j8 <= 30) { + setBlock(world, j1, k1 + 1, l1 - 1); + setBlock(world, j1, k1 + 2, l1 - 1, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1, k1 + 2, l1 - 1); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1, k1 + 1, l1 - 2); + setBlock(world, j1, k1 + 2, l1 - 2); + setBlock(world, j1 - 1, k1 + 1, l1 - 1); + setBlock(world, j1 - 1, k1 + 2, l1 - 2); + setBlock(world, j1 - 1, k1 + 1, l1 - 2); + } + int j9 = random.nextInt(100); + if (j9 <= 10) { + setBlock(world, j1 - 3, k1 + 1, l1 - 1, Blocks.diamond_block); + setBlock(world, j1 - 3, k1 + 1, l1 - 2, Blocks.diamond_block); + } + int j10 = random.nextInt(100); + if (j10 <= 10) { + setBlock(world, j1 - 3, k1 + 1, l1 - 2, Blocks.diamond_block); + } + int j11 = random.nextInt(100); + if (j11 <= 15) { + setBlock(world, j1 - 5, k1 + 1, l1 - 2, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1 - 5, k1 + 1, l1 - 2)); + setBlock(world, j1 - 5, k1 + 1, l1 - 3); + } + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + for (int u = 0; u < 5; u++) { + for (int y = 1; y < 5; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 2, l1 - 5, pickBlock(random)); + int k7 = random.nextInt(100); + if (k7 <= 30) { + setBlock(world, j1 - 2, k1 + 5, l1 - 3); + setBlock(world, j1 - 2, k1 + 5, l1 - 2); + setBlock(world, j1 - 2, k1 + 5, l1 - 1); + setBlock(world, j1 - 1, k1 + 5, l1 - 2); + setBlock(world, j1 - 3, k1 + 5, l1 - 2); + setBlock(world, j1 - 5, k1 + 5, l1 - 2); + setBlock(world, j1 - 2, k1 + 6, l1 - 2); + setBlock(world, j1 - 2, k1 + 6, l1 - 1); + setBlock(world, j1 - 1, k1 + 6, l1 - 2); + setBlock(world, j1 - 3, k1 + 6, l1 - 2); + setBlock(world, j1 - 2, k1 + 7, l1 - 2); + setBlock(world, j1 - 2, k1 + 7, l1 - 1); + setBlock(world, j1 - 1, k1 + 7, l1 - 2); + setBlock(world, j1 - 3, k1 + 7, l1 - 2); + setBlock(world, j1 - 2, k1 + 8, l1 - 2); + setBlock(world, j1 - 2, k1 + 8, l1 - 1); + setBlock(world, j1 - 1, k1 + 8, l1 - 2); + setBlock(world, j1 - 2, k1 + 9, l1 - 2); + setBlock(world, j1 - 2, k1 + 9, l1 - 1); + setBlock(world, j1 - 1, k1 + 9, l1 - 2); + setBlock(world, j1 - 2, k1 + 10, l1 - 1); + setBlock(world, j1 - 1, k1 + 10, l1 - 2); + setBlock(world, j1 - 2, k1 + 1, l1 - 2, Blocks.stone); + setBlock(world, j1 - 2, k1 + 1, l1 - 3, Blocks.gravel); + setBlock(world, j1 - 1, k1 + 1, l1 - 2, Blocks.stone); + setBlock(world, j1 - 1, k1 + 1, l1 - 3, Blocks.gravel); + setBlock(world, j1 - 2, k1 + 1, l1 - 1, Blocks.stone); + setBlock(world, j1 - 3, k1 + 1, l1 - 2, Blocks.stone); + setBlock(world, j1 - 2, k1 + 2, l1 - 2, Blocks.stone); + setBlock(world, j1 - 2, k1 + 2, l1 - 1, Blocks.gravel); + setBlock(world, j1 - 2, k1 + 3, l1 - 2, Blocks.stone); + setBlock(world, j1 - 2, k1 + 3, l1 - 1, Blocks.stone); + setBlock(world, j1 - 4, k1 + 3, l1 - 1, Blocks.gravel); + setBlock(world, j1 - 2, k1 + 3, l1, Blocks.gravel); + setBlock(world, j1 - 1, k1 + 3, l1 - 3, Blocks.stone); + } + } + if (k3 == 2) { + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + for (int u = 0; u < 9; u++) { + for (int y = 1; y < 6; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 9, pickBlock(random)); + int i4 = random.nextInt(100); + if (i4 <= 60) { + for (int y = 0; y < 15; y++) { + setBlock(world, j1 + 7, k1 - y, l1); + } + setBlock(world, j1, k1 - 13, l1 + 1); + setBlock(world, j1, k1 - 13, l1 - 1); + setBlock(world, j1, k1 - 14, l1 + 1); + setBlock(world, j1, k1 - 14, l1 - 1); + setBlock(world, j1 + 1, k1 - 13, l1 + 1); + setBlock(world, j1 + 1, k1 - 13, l1 - 1); + setBlock(world, j1 + 1, k1 - 14, l1 + 1); + setBlock(world, j1 + 1, k1 - 14, l1 - 1); + } + int j6 = random.nextInt(100); + if (j6 <= 70) { + for (int y = 0; y < 13; y++) { + setBlock(world, j1 + 7, k1 - y, l1 + 6); + } + setBlock(world, j1, k1 - 11, l1 + 7); + setBlock(world, j1, k1 - 11, l1 + 5); + setBlock(world, j1, k1 - 12, l1 + 7); + setBlock(world, j1, k1 - 12, l1 + 5); + setBlock(world, j1 + 1, k1 - 11, l1 + 7); + setBlock(world, j1 + 1, k1 - 11, l1 + 5); + setBlock(world, j1 + 1, k1 - 12, l1 + 7); + setBlock(world, j1 + 1, k1 - 12, l1 + 5); + } + int l7 = random.nextInt(100); + if (l7 <= 50) { + for (int y = 0; y < 17; y++) { + setBlock(world, j1 + 7, k1 - y, l1 - 4); + } + setBlock(world, j1 + 7, k1 - 15, l1 - 5); + setBlock(world, j1 + 7, k1 - 15, l1 - 3); + setBlock(world, j1 + 7, k1 - 16, l1 - 5); + setBlock(world, j1 + 7, k1 - 16, l1 - 3); + setBlock(world, j1 + 8, k1 - 15, l1 - 5); + setBlock(world, j1 + 8, k1 - 15, l1 - 3); + setBlock(world, j1 + 8, k1 - 16, l1 - 5); + setBlock(world, j1 + 8, k1 - 16, l1 - 3); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + for (int y = 1; y < 6; y++) { + setBlockAndMetadata(world, j1, k1 + y, l1 + 6, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1, k1 + y, l1 - 6, Blocks.quartz_block, 2); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1 + 3, l1); + setBlock(world, j1, k1 + 4, l1); + setBlock(world, j1, k1 + 5, l1); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int u = 1; u < 9; u++) { + for (int y = 1; y < 6; y++) { + setBlock(world, j1, k1 + y, l1 + u); + setBlock(world, j1, k1 + y, l1 - u); + } + } + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 + 1, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 + 2, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 - 1, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 - 2, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.stone_slab); + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.stone_slab); + for (int z = -2; z < 3; z++) { + setBlock(world, j1, k1, l1 + z, Blocks.obsidian); + setBlock(world, j1, k1 + 1, l1 + z, Blocks.obsidian); + setBlock(world, j1, k1 + 2, l1 + z, Blocks.obsidian); + } + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.stone_slab); + for (int y = 1; y < 6; y++) { + setBlockAndMetadata(world, j1, k1 + y, l1 + 6, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1, k1 + y, l1 - 6, Blocks.quartz_block, 2); + } + int k8 = random.nextInt(100); + if (k8 <= 15) { + setBlock(world, j1, k1 + 1, l1 - 7, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1, k1 + 1, l1 - 7)); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 4, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.stone_slab); + setBlock(world, j1, k1 + 1, l1, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1, k1 + 1, l1)); + for (int z = -2; z < 3; z++) { + setBlock(world, j1, k1, l1 + z, Blocks.obsidian); + if (z != 0) + setBlock(world, j1, k1 + 1, l1 + z, Blocks.obsidian); + setBlock(world, j1, k1 + 2, l1 + z, Blocks.obsidian); + } + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.stone_slab); + int k9 = random.nextInt(100); + if (k9 <= 75) { + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1 + 1, l1 + 1); + setBlock(world, j1, k1 + 2, l1 + 1); + setBlock(world, j1, k1 + 1, l1 - 1); + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1 - 1, k1 + 1, l1); + setBlock(world, j1 - 1, k1 + 2, l1); + setBlock(world, j1 - 1, k1 + 2, l1 - 1); + setBlock(world, j1 - 3, k1 + 1, l1 + 2, Blocks.obsidian); + setBlock(world, j1 - 2, k1 + 1, l1, Blocks.obsidian); + setBlock(world, j1 - 3, k1 + 1, l1 - 3, Blocks.obsidian); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 3, Blocks.stone_slab); + for (int z = -2; z < 3; z++) { + setBlock(world, j1, k1, l1 + z, Blocks.obsidian); + setBlock(world, j1, k1 + 1, l1 + z, Blocks.obsidian); + setBlock(world, j1, k1 + 2, l1 + z, Blocks.obsidian); + } + setBlock(world, j1, k1 + 1, l1 - 3, Blocks.stone_slab); + for (int y = 1; y < 6; y++) { + setBlockAndMetadata(world, j1, k1 + y, l1 + 6, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1, k1 + y, l1 - 6, Blocks.quartz_block, 2); + } + int k10 = random.nextInt(100); + if (k10 <= 50) { + setBlockAndMetadata(world, j1, k1 + 1, l1 + 7, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 2, k1 + 1, l1 + 8, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 1, k1 + 1, l1 + 5, Blocks.quartz_block, 2); + setBlock(world, j1, k1 + 2, l1 + 6); + setBlock(world, j1, k1 + 3, l1 + 6); + setBlock(world, j1, k1 + 4, l1 + 6); + } + int k11 = random.nextInt(100); + if (k11 <= 30) { + setBlock(world, j1 + 1, k1 + 5, l1 + 3, Blocks.vine); + setBlock(world, j1 - 1, k1 + 5, l1 + 3, Blocks.vine); + setBlock(world, j1 - 1, k1 + 6, l1 + 2, Blocks.vine); + setBlock(world, j1 - 1, k1 + 5, l1 + 2, Blocks.vine); + setBlock(world, j1 - 2, k1 + 7, l1 - 1, Blocks.vine); + setBlock(world, j1 - 2, k1 + 7, l1 + 1, Blocks.vine); + setBlock(world, j1 - 2, k1 + 6, l1 + 1, Blocks.vine); + setBlock(world, j1 - 3, k1 + 8, l1, Blocks.vine); + setBlock(world, j1 + 1, k1 + 5, l1 - 3, Blocks.vine); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 4, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 9, pickBlock(random)); + for (int z = -3; z < 4; z++) { + setBlock(world, j1, k1 + 1, l1 + z, Blocks.stone_slab); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + for (int y = 1; y < 6; y++) { + setBlockAndMetadata(world, j1, k1 + y, l1 + 6, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1, k1 + y, l1 - 6, Blocks.quartz_block, 2); + } + int j12 = random.nextInt(100); + if (j12 <= 50) { + setBlockAndMetadata(world, j1, k1 + 1, l1 - 7, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 1, k1 + 1, l1 - 8, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 3, k1 + 1, l1 - 5, Blocks.quartz_block, 2); + setBlock(world, j1, k1 + 3, l1 - 6); + setBlock(world, j1, k1 + 4, l1 - 6); + setBlock(world, j1, k1 + 5, l1 - 6); + } + j1++; + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1, l1 + 4, pickBlock(random)); + setBlock(world, j1, k1, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1, l1 + 6, pickBlock(random)); + setBlock(world, j1, k1, l1 + 7, pickBlock(random)); + setBlock(world, j1, k1, l1 + 8, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1, l1 - 3, pickBlock(random)); + setBlock(world, j1, k1, l1 - 4, pickBlock(random)); + setBlock(world, j1, k1, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1, l1 - 6, pickBlock(random)); + setBlock(world, j1, k1, l1 - 7, pickBlock(random)); + setBlock(world, j1, k1, l1 - 8, pickBlock(random)); + setBlock(world, j1, k1 + 6, l1); + setBlock(world, j1, k1 + 6, l1 + 1); + setBlock(world, j1, k1 + 6, l1 - 1); + setBlock(world, j1, k1 + 6, l1 + 2); + setBlock(world, j1, k1 + 6, l1 - 2); + setBlock(world, j1, k1 + 7, l1); + setBlock(world, j1, k1 + 7, l1 + 1); + setBlock(world, j1, k1 + 7, l1 - 1); + setBlock(world, j1, k1 + 8, l1); + for (int y = 1; y < 6; y++) { + for (int z = -8; z < 9; z++) { + setBlock(world, j1, k1 + y, l1 + 1); + } + } + setBlock(world, j1, k1 + 1, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 9, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 9, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 - 9, pickBlock(random)); + } + j1++; + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 + 3, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 + 3, l1, pickBlock(random)); + setBlock(world, j1, k1 + 1, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 + 2, l1 - 1, pickBlock(random)); + j1++; + for (int y = 1; y < 4; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 + y, l1 + z); + } + } + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + j1++; + for (int y = 1; y < 4; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 + y, l1 + z); + } + } + setBlock(world, j1, k1, l1, pickBlock(random)); + setBlock(world, j1, k1, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1, l1 - 1, pickBlock(random)); + j1++; + setBlock(world, j1, k1, l1); + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + setBlock(world, j1, k1 + 3, l1); + j1++; + setBlock(world, j1, k1 - 1, l1); + setBlock(world, j1, k1, l1); + setBlock(world, j1, k1 + 1, l1); + setBlock(world, j1, k1 + 2, l1); + j1++; + setBlock(world, j1, k1 - 2, l1); + setBlock(world, j1, k1 - 1, l1); + setBlock(world, j1, k1, l1); + setBlock(world, j1, k1 + 1, l1); + j1++; + setBlock(world, j1, k1 - 3, l1); + setBlock(world, j1, k1 - 2, l1); + setBlock(world, j1, k1 - 1, l1); + setBlock(world, j1, k1, l1); + j1++; + setBlock(world, j1, k1 - 4, l1); + setBlock(world, j1, k1 - 3, l1); + setBlock(world, j1, k1 - 2, l1); + setBlock(world, j1, k1 - 1, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + setBlock(world, j1, k1 - 3, l1); + setBlock(world, j1, k1 - 2, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + j1++; + for (int z = 0; z < 21; z++) { + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 4, l1); + } + setBlock(world, j1, k1 - 4, l1 + 21); + setBlock(world, j1, k1 - 5, l1 + 21); + setBlock(world, j1, k1 - 6, l1 + 21); + for (int z = 0; z < 8; z++) { + for (int y = 4; y < 7; y++) { + setBlock(world, j1, k1 - y - z, l1 + 22 + z); + } + } + int j4 = random.nextInt(100); + if (j4 <= 20) { + for (int x = -1; x < 2; x++) { + setBlock(world, j1 + x, k1 - 12, l1 + 31); + setBlock(world, j1 + x, k1 - 13, l1 + 31); + setBlock(world, j1 + x, k1 - 12, l1 + 32); + setBlock(world, j1 + x, k1 - 13, l1 + 32); + setBlock(world, j1 + x, k1 - 12, l1 + 33); + setBlock(world, j1 + x, k1 - 13, l1 + 33); + } + setBlock(world, j1, k1 - 10, l1 + 31, Blocks.lapis_block); + setBlock(world, j1, k1 - 10, l1 + 32, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 + 33, Blocks.lapis_block); + setBlock(world, j1 + 1, k1 - 10, l1 + 31, Blocks.lapis_block); + setBlock(world, j1 + 1, k1 - 10, l1 + 32, Blocks.lapis_block); + setBlock(world, j1 + 1, k1 - 10, l1 + 33, Blocks.lapis_block); + setBlock(world, j1 - 1, k1 - 10, l1 + 31, Blocks.lapis_block); + setBlock(world, j1 - 1, k1 - 10, l1 + 32, Blocks.lapis_block); + setBlock(world, j1 - 1, k1 - 10, l1 + 33, Blocks.lapis_block); + setBlock(world, j1, k1 - 11, l1 + 32, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1, k1 - 11, l1 + 32)); + } + j1++; + setBlock(world, j1, k1 - 4, l1); + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 6, l1); + j1++; + setBlock(world, j1, k1 - 4, l1); + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 6, l1); + setBlock(world, j1, k1 - 7, l1); + j1++; + setBlock(world, j1, k1 - 5, l1); + setBlock(world, j1, k1 - 6, l1); + setBlock(world, j1, k1 - 7, l1); + setBlock(world, j1, k1 - 8, l1); + j1++; + setBlock(world, j1, k1 - 6, l1); + setBlock(world, j1, k1 - 7, l1); + setBlock(world, j1, k1 - 8, l1); + setBlock(world, j1, k1 - 9, l1); + j1++; + setBlock(world, j1, k1 - 7, l1); + setBlock(world, j1, k1 - 8, l1); + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 10, l1); + j1++; + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 10, l1); + j1++; + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 10, l1); + j1++; + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 10, l1); + j1++; + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 10, l1); + setBlock(world, j1, k1 - 8, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, Blocks.stone); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 - 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + for (int y = 0; y < 3; y++) { + for (int z = -1; z < 2; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 2, pickBlock(random)); + j1++; + setBlock(world, j1, k1 - 10, l1); + setBlock(world, j1, k1 - 9, l1); + setBlock(world, j1, k1 - 11, l1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 11, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 1, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 1, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1, pickBlock(random)); + int k6 = random.nextInt(100); + if (k6 <= 30) { + setBlock(world, j1 - 1, k1 - 8, l1 + 3, Blocks.vine); + setBlock(world, j1 - 2, k1 - 8, l1, Blocks.vine); + setBlock(world, j1 - 2, k1 - 9, l1, Blocks.vine); + setBlock(world, j1 - 4, k1 - 8, l1 + 2, Blocks.vine); + setBlock(world, j1 - 6, k1 - 8, l1 - 1, Blocks.vine); + } + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 10, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 - 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 - 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + j1++; + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 11, l1 + z, pickBlock(random)); + } + for (int y = 0; y < 4; y++) { + for (int z = -4; z < 5; z++) { + setBlock(world, j1, k1 - 10 - y, l1 + z); + } + } + setBlock(world, j1, k1 - 10, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 9, l1 + 5, pickBlock(random)); + setBlock(world, j1, k1 - 8, l1 + 5, pickBlock(random)); + int i8 = random.nextInt(2) + 1; + if (i8 == 1) { + for (int y = 0; y < 4; y++) { + setBlock(world, j1 - 2, k1 - 10 - y, l1, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10 - y, l1, pickBlock(random)); + setBlock(world, j1 - 10, k1 - 10 - y, l1, pickBlock(random)); + } + int l8 = random.nextInt(100); + if (l8 <= 50) { + setBlock(world, j1 - 1, k1 - 10, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 1, k1 - 9, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 1, k1 - 8, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 1, k1 - 10, l1 + 3, Blocks.double_stone_slab); + setBlock(world, j1 - 1, k1 - 9, l1 + 3, Blocks.double_stone_slab); + setBlock(world, j1 - 1, k1 - 8, l1 + 3, Blocks.double_stone_slab); + } + int l9 = random.nextInt(100); + if (l9 <= 60) { + setBlock(world, j1 - 2, k1 - 10, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 2, k1 - 9, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 2, k1 - 8, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 2, k1 - 10, l1 + 3, Blocks.double_stone_slab); + setBlock(world, j1 - 2, k1 - 9, l1 + 3, Blocks.double_stone_slab); + } + int l10 = random.nextInt(100); + if (l10 <= 70) { + setBlock(world, j1 - 3, k1 - 10, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 3, k1 - 9, l1 + 2, Blocks.double_stone_slab); + setBlock(world, j1 - 3, k1 - 10, l1 + 3, Blocks.double_stone_slab); + setBlock(world, j1 - 3, k1 - 9, l1 + 3, Blocks.double_stone_slab); + } + int l11 = random.nextInt(100); + if (l11 <= 40) { + setBlock(world, j1 - 1, k1 - 10, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 1, k1 - 9, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 1, k1 - 8, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 1, k1 - 10, l1 - 3, Blocks.stonebrick); + setBlock(world, j1 - 1, k1 - 9, l1 - 3, Blocks.stonebrick); + } + int k12 = random.nextInt(100); + if (k12 <= 50) { + setBlock(world, j1 - 2, k1 - 10, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 2, k1 - 9, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 2, k1 - 8, l1 - 2, Blocks.stonebrick); + setBlock(world, j1 - 2, k1 - 10, l1 - 3, Blocks.stonebrick); + setBlock(world, j1 - 2, k1 - 9, l1 - 3, Blocks.stonebrick); + setBlock(world, j1 - 2, k1 - 8, l1 - 3, Blocks.stonebrick); + } + int l12 = random.nextInt(100); + if (l12 <= 40) { + setBlock(world, j1 - 4, k1 - 10, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 4, k1 - 9, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 4, k1 - 10, l1 - 3, Blocks.nether_brick); + setBlock(world, j1 - 4, k1 - 9, l1 - 3, Blocks.nether_brick); + } + int i13 = random.nextInt(100); + if (i13 <= 40) { + setBlock(world, j1 - 5, k1 - 10, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 5, k1 - 9, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 5, k1 - 10, l1 - 3, Blocks.nether_brick); + setBlock(world, j1 - 5, k1 - 9, l1 - 3, Blocks.nether_brick); + setBlock(world, j1 - 6, k1 - 10, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 6, k1 - 9, l1 - 2, Blocks.nether_brick); + setBlock(world, j1 - 6, k1 - 10, l1 - 3, Blocks.nether_brick); + } + int j13 = random.nextInt(100); + if (j13 <= 15) { + setBlock(world, j1 - 9, k1 - 10, l1 + 2, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1 - 9, k1 - 10, l1 + 2)); + } + if (j13 >= 85) { + setBlock(world, j1 - 9, k1 - 10, l1 - 2, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1 - 9, k1 - 10, l1 - 2)); + } + } + if (i8 != 2) { + return true; + } + for (int y = 0; y < 4; y++) { + setBlockAndMetadata(world, j1 - 1, k1 - 10 - y, l1, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 1, k1 - 10 - y, l1 + 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 1, k1 - 10 - y, l1 - 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 3, k1 - 10 - y, l1, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 3, k1 - 10 - y, l1 + 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 3, k1 - 10 - y, l1 - 3, Blocks.quartz_block, 2); + } + setBlock(world, j1 - 4, k1 - 10, l1, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1 - 4, k1 - 10, l1); + if (spawner != null) { + spawner.func_145881_a().setEntityName(Config.getRandomDungeonMob(random)); + } + setBlock(world, j1 - 8, k1 - 10, l1, Blocks.stone_slab); + setBlock(world, j1 - 8, k1 - 10, l1 + 1, Blocks.stone_slab); + setBlock(world, j1 - 8, k1 - 10, l1 - 1, Blocks.stone_slab); + setBlock(world, j1 - 5, k1 - 10, l1, pickBlock(random)); + setBlock(world, j1 - 5, k1 - 10, l1 + 1, pickBlock(random)); + setBlock(world, j1 - 5, k1 - 10, l1 - 1, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10, l1, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10, l1 + 1, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10, l1 - 1, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10, l1 + 2, pickBlock(random)); + setBlock(world, j1 - 6, k1 - 10, l1 - 2, pickBlock(random)); + setBlock(world, j1 - 7, k1 - 10, l1, pickBlock(random)); + setBlock(world, j1 - 7, k1 - 10, l1 + 1, pickBlock(random)); + setBlock(world, j1 - 7, k1 - 10, l1 - 1, pickBlock(random)); + int i9 = random.nextInt(100); + if (i9 <= 30) { + setBlock(world, j1 - 6, k1 - 9, l1, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1 - 6, k1 - 9, l1)); + } + if (i9 <= 10) { + setBlock(world, j1 - 6, k1 - 9, l1, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1 - 6, k1 - 9, l1)); + } + for (int y = 0; y < 4; y++) { + setBlockAndMetadata(world, j1 - 9, k1 - 10 - y, l1, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 9, k1 - 10 - y, l1 + 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 9, k1 - 10 - y, l1 - 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 11, k1 - 10 - y, l1, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 11, k1 - 10 - y, l1 + 3, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 11, k1 - 10 - y, l1 - 3, Blocks.quartz_block, 2); + } + int i10 = random.nextInt(100); + if (i10 <= 20) { + setBlock(world, j1 - 2, k1 - 10, l1 + 4, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1 - 2, k1 - 10, l1 + 4)); + } + int i11 = random.nextInt(100); + if (i11 <= 40) { + setBlock(world, j1 - 3, k1 - 9, l1 + 3); + setBlock(world, j1 - 3, k1 - 8, l1 + 3); + setBlock(world, j1 - 3, k1 - 7, l1 + 3); + setBlockAndMetadata(world, j1 - 1, k1 - 10, l1 + 4, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 2, k1 - 10, l1 + 4, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1, k1 - 10, l1 + 2, Blocks.quartz_block, 2); + } + int i12 = random.nextInt(100); + if (i12 <= 40) { + setBlock(world, j1 - 9, k1 - 9, l1 - 3); + setBlock(world, j1 - 9, k1 - 8, l1 - 3); + setBlock(world, j1 - 9, k1 - 7, l1 - 3); + setBlockAndMetadata(world, j1 - 7, k1 - 10, l1 - 2, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 8, k1 - 10, l1 - 4, Blocks.quartz_block, 2); + setBlockAndMetadata(world, j1 - 8, k1 - 10, l1 - 2, Blocks.quartz_block, 2); + } return true; } + + private static Block pickBlock(Random random) { + return random.nextBoolean() ? Blocks.cobblestone : Blocks.mossy_cobblestone; + } + + private void setBlock(World w, int x, int y, int z){ + func_150515_a(w, x, y, z, Blocks.air); + } + + private void setBlock(World w, int x, int y, int z, Block bl){ + func_150515_a(w, x, y, z, bl); + } + + private void setBlockAndMetadata(World w, int x, int y, int z, Block bl, int meta){ + setBlockAndNotifyAdequately(w, x, y, z, bl, meta); + } } diff --git a/common/MysticRuins/StructureRuin$1.java b/common/MysticRuins/StructureRuin$1.java index 389c90c..b856e54 100644 --- a/common/MysticRuins/StructureRuin$1.java +++ b/common/MysticRuins/StructureRuin$1.java @@ -1,435 +1,431 @@ package mysticruins; -import java.util.Random; - import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.tileentity.TileEntityMobSpawner; import net.minecraft.world.World; import net.minecraft.world.gen.feature.WorldGenerator; import net.minecraftforge.common.DungeonHooks; +import java.util.Random; + public class StructureRuin$1 extends WorldGenerator { public StructureRuin$1() { } @Override public boolean generate(World world, Random random, int i, int j, int k) { - int l = random.nextInt(100); - if (l >= 10) { + int j1 = (i + random.nextInt(8)) - random.nextInt(8); + int k1 = (j + random.nextInt(4)) - random.nextInt(4); + int l1 = (k + random.nextInt(8)) - random.nextInt(8); + if (k1 <= 0) { return false; } - for (int i1 = 0; i1 < 1; i1++) { - int j1 = (i + random.nextInt(8)) - random.nextInt(8); - int k1 = (j + random.nextInt(4)) - random.nextInt(4); - int l1 = (k + random.nextInt(8)) - random.nextInt(8); - if (!world.isAirBlock(j1, k1, l1) || world.getBlockId(j1, k1 - 1, l1) != Block.grass.blockID || !Block.pumpkin.canPlaceBlockAt(world, j1, k1, l1)) { - continue; - } - int i2 = random.nextInt(3) + 1; - if (i2 == 1) { - int j2 = random.nextInt(8) + 5; - int i3 = random.nextInt(8) + 5; - int l3 = random.nextInt(8) + 5; - int k4 = random.nextInt(4) + 3; - int j5 = 1; - int i6 = 0; - int l6 = 1; - boolean flag = false; - int k7 = random.nextInt(100); - int j8 = random.nextInt(100); - if (j8 <= 20) { - j5 = 0; - } else { - j5 = random.nextInt(4) + 5; - } - world.setBlock(j1, k1 - j5, l1, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - j5) + 1, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 2, l1, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 3, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 4, l1 + 1, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - j5) + 5, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 2, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 3, l1 + 2, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - j5) + 4, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - j5, l1 + 3, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - j5) + 1, l1 + 3, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1 + 3, Block.stoneBrick.blockID); - world.setBlock(j1, k1 - j5 - k4 - 1, l1 + 2, Block.dirt.blockID); - world.setBlock(j1, k1 - j5 - k4, l1 + 2, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1, k1 - j5 - k4, l1 + 2)); - l6 = 1; - i6 = 0; - flag = false; - do { - if (world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) - || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) == Block.waterStill.blockID || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) == Block.waterStill.blockID - || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) == Block.waterStill.blockID) { - i6++; - } else { - flag = true; - } - } while (!flag && l6++ < 12); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3 + 1, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3 + 1, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3 + 2, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + l3 + 3, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3 + 4, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3 + 5, k1 - j5 - i6, l1 + l3 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 5, Block.stoneBrick.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3, ((k1 - j5) + 3) - i6, l1 + l3 + 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 7, Block.stoneBrick.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 7, Block.stoneBrick.blockID, 1, 2); - k7 = random.nextInt(100); - if (k7 <= 30) { - world.setBlock(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID(DungeonHooks.getRandomDungeonMob(random)); - } - world.setBlock(j1 + l3, k1 - j5 - i6 - k4 - 1, l1 + l3 + 5, Block.dirt.blockID); - } - l6 = 1; - i6 = 0; - flag = false; - do { - if (world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 4) || world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 5) || world.isAirBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) - || world.getBlockId(j1 - i3, k1 - j5 - l6, l1 - 4) == Block.waterStill.blockID || world.getBlockId(j1 - i3, k1 - j5 - l6, l1 - 5) == Block.waterStill.blockID - || world.getBlockId(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) == Block.waterStill.blockID) { - i6++; - } else { - flag = true; - } - } while (!flag && l6++ < 12); - world.setBlock(j1 - i3, k1 - j5 - i6, l1 - 4, Block.stoneBrick.blockID); - world.setBlock(j1 - i3, ((k1 - j5) + 1) - i6, l1 - 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - i3, k1 - j5 - i6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - i3 - 1, k1 - j5 - i6, l1 - 5, Block.stoneBrick.blockID); - world.setBlock(j1 - i3 - 1, ((k1 - j5) + 1) - i6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - i3 - 1, ((k1 - j5) + 2) - i6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - i3 - 2, k1 - j5 - i6, l1 - 5, Block.stoneBrick.blockID); - k7 = random.nextInt(100); - if (k7 <= 60) { - world.setBlock(j1 - i3 - 1, k1 - j5 - i6 - k4, l1 - 5, Block.dirt.blockID); - world.setBlock(j1 - i3 - 1, k1 - j5 - i6 - k4 - 1, l1 - 5, Block.dirt.blockID); - } - } - if (i2 == 2) { - int k2 = random.nextInt(8) + 5; - int j3 = random.nextInt(8) + 5; - int i4 = random.nextInt(8) + 5; - int l4 = random.nextInt(4) + 3; - int k5 = 1; - int j6 = 0; - int i7 = 1; - boolean flag1 = false; - int l7 = random.nextInt(100); - int k8 = random.nextInt(100); - if (k8 <= 20) { - k5 = 0; - } else { - k5 = random.nextInt(4) + 5; - } - world.setBlock(j1, k1 - k5, l1, Block.stoneBrick.blockID); - world.setBlock(j1, k1 - k5, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - k5, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - k5, l1 + 3, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - k5, l1 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - k5) + 1, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - k5) + 2, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - k5) + 3, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - k5) + 1, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + 1, k1 - k5, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + 2, k1 - k5, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - k5 - l4, l1 + 2, Block.dirt.blockID); - world.setBlock(j1, k1 - k5 - l4 - 1, l1 + 2, Block.dirt.blockID); - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 4) || world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 5) || world.isAirBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) - || world.getBlockId(j1 - k2, k1 - k5 - i7, l1 - 4) == Block.waterStill.blockID || world.getBlockId(j1 - k2, k1 - k5 - i7, l1 - 5) == Block.waterStill.blockID - || world.getBlockId(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 3, Block.stoneBrick.blockID); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 1) - j6, l1 - 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 2) - j6, l1 - 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 1) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 2) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 3) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2, ((k1 - k5) + 4) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2 - 1, k1 - k5 - j6, l1 - 5, Block.stoneBrick.blockID); - world.setBlock(j1 - k2 - 1, ((k1 - k5) + 1) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2 - 1, ((k1 - k5) + 2) - j6, l1 - 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k2 - 2, k1 - k5 - j6, l1 - 5, Block.stoneBrick.blockID); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 - k2 - 1, k1 - k5 - j6 - l4, l1 - 5, Block.dirt.blockID); - world.setBlock(j1 - k2 - 1, k1 - k5 - j6 - l4 - 1, l1 - 5, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 4) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 6) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 8) - || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 4) == Block.waterStill.blockID || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 6) == Block.waterStill.blockID - || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 8) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4 + 1, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4 + 1, ((k1 - k5) + 1) - j6, l1 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4 + 2, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4 + 3, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4 + 3, ((k1 - k5) + 1) - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4 + 4, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4 + 5, k1 - k5 - j6, l1 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 5, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 5, Block.stoneBrick.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 2) - j6, l1 + 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 7, Block.stoneBrick.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 2) - j6, l1 + 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 8, Block.stoneBrick.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 8, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 9, Block.stoneBrick.blockID, 1, 2); - l7 = random.nextInt(100); - if (l7 <= 60) { - world.setBlock(j1 + i4, k1 - k5 - j6 - l4, l1 + 7, Block.dirt.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6 - l4 - 1, l1 + 7, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 - j3, k1 - k5 - i7, l1 + i4) || world.isAirBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) || world.isAirBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) - || world.getBlockId(j1 - j3, k1 - k5 - i7, l1 + i4) == Block.waterStill.blockID || world.getBlockId(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) == Block.waterStill.blockID - || world.getBlockId((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock((j1 - j3) + 1, k1 - k5 - j6, l1 + i4, Block.stoneBrick.blockID); - world.setBlock((j1 - j3) + 1, ((k1 - k5) + 1) - j6, l1 + i4, Block.stoneBrick.blockID, 1, 2); - world.setBlock((j1 - j3) + 1, ((k1 - k5) + 2) - j6, l1 + i4, Block.stoneBrick.blockID, 1, 2); - world.setBlock((j1 - j3) + 2, k1 - k5 - j6, l1 + i4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, k1 - k5 - j6, (l1 + i4) - 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 1, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 2, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 2, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 5) - j6, (l1 + i4) - 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - j3, k1 - k5 - j6, (l1 + i4) - 3, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 3, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 3, Block.stoneBrick.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 3, Block.stoneBrick.blockID, 1, 2); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 - j3, k1 - k5 - j6 - l4, (l1 + i4) - 2, Block.dirt.blockID); - world.setBlock(j1 - j3, k1 - k5 - j6 - l4 - 1, (l1 + i4) - 2, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) || world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) || world.isAirBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) - || world.getBlockId(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) == Block.waterStill.blockID || world.getBlockId(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) == Block.waterStill.blockID - || world.getBlockId(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6, l1 - 6, Block.stoneBrick.blockID); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 2) - j6, l1 - 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6, l1 - 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 5, k1 - k5 - j6, l1 - 7, Block.stoneBrick.blockID); - world.setBlock(j1 + j3 + 5, ((k1 - k5) + 1) - j6, l1 - 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 5, ((k1 - k5) + 2) - j6, l1 - 7, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + j3 + 6, k1 - k5 - j6, l1 - 7, Block.stoneBrick.blockID); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 + j3 + 4, k1 - k5 - j6 - l4, l1 - 7, Block.dirt.blockID); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6 - l4 - 1, l1 - 7, Block.dirt.blockID); - } - } - if (i2 != 3) { - continue; - } - int l2 = random.nextInt(8) + 5; - int k3 = random.nextInt(8) + 5; - int j4 = random.nextInt(8) + 5; - int i5 = random.nextInt(4) + 3; - int l5 = 1; - int k6 = 0; - int j7 = 1; - boolean flag2 = false; - int i8 = random.nextInt(100); - int l8 = random.nextInt(100); - if (l8 <= 20) { - l5 = 0; + if (!world.isAirBlock(j1, k1, l1) || world.getBlock(j1, k1 - 1, l1) != Blocks.grass || !Blocks.pumpkin.canPlaceBlockAt(world, j1, k1, l1)) { + return false; + } + int i2 = random.nextInt(3) + 1; + if (i2 == 1) { + int i3 = random.nextInt(8) + 5; + int l3 = random.nextInt(8) + 5; + int k4 = random.nextInt(4) + 3; + int j8 = random.nextInt(100); + int j5; + if (j8 <= 20) { + j5 = 0; } else { - l5 = random.nextInt(4) + 5; + j5 = random.nextInt(4) + 5; } - world.setBlock(j1, k1 - l5, l1, Block.stoneBrick.blockID); - world.setBlock(j1 - 1, k1 - l5, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 1, (k1 - l5) + 1, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 1, (k1 - l5) + 2, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 1, (k1 - l5) + 3, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - l5) + 1, l1, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - l5) + 2, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - l5) + 3, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - l5) + 4, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, (k1 - l5) + 5, l1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - l5, l1 + 1, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - l5) + 2, l1 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - l5, l1 + 2, Block.stoneBrick.blockID); - world.setBlock(j1, (k1 - l5) + 1, l1 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1, k1 - l5 - i5, l1 + 1, Block.dirt.blockID); - world.setBlock(j1, k1 - l5 - i5 - 1, l1 + 1, Block.dirt.blockID); - j7 = 1; - k6 = 0; - flag2 = false; + setBlock(world, j1, k1 - j5, l1, Blocks.stonebrick); + setBlock(world, j1, (k1 - j5) + 2, l1, Blocks.stonebrick); + setBlock(world, j1, (k1 - j5) + 4, l1 + 1, Blocks.stonebrick); + setBlock(world, j1, (k1 - j5) + 3, l1 + 2, Blocks.stonebrick); + setBlock(world, j1, (k1 - j5) + 1, l1 + 3, Blocks.stonebrick); + setBlock(world, j1, (k1 - j5) + 2, l1 + 3, Blocks.stonebrick); + setBlockAndMetadata(world, j1, k1 - j5, l1 + 3, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 1, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 2, l1 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 3, l1 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 5, l1 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 2, l1 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - j5) + 4, l1 + 2, Blocks.stonebrick, 1); + setBlock(world, j1, k1 - j5 - k4 - 1, l1 + 2, Blocks.dirt); + setBlock(world, j1, k1 - j5 - k4, l1 + 2, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1, k1 - j5 - k4, l1 + 2)); + int l6 = 1; + int i6 = 0; + boolean flag = false; do { - if (world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) == Block.waterStill.blockID - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) == Block.waterStill.blockID - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) + || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) == Blocks.water || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) == Blocks.water + || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) == Blocks.water) { + i6++; } else { - flag2 = true; + flag = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2 + 1, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2 + 2, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2 + 3, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 1, Block.stoneBrick.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 3) - k6, l1 + j4 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 2, Block.stoneBrick.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 3, Block.stoneBrick.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 3, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 6, Block.stoneBrick.blockID); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 + k3 + l2, k1 - l5 - k6 - i5, l1 + j4 + 1, Block.dirt.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6 - i5 - 1, l1 + j4 + 1, Block.dirt.blockID); + } while (!flag && l6++ < 12); + setBlock(world, j1 + l3, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick); + setBlock(world, j1 + l3 + 2, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick); + setBlock(world, j1 + l3 + 5, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick); + setBlock(world, j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 5, Blocks.stonebrick); + setBlock(world, j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 7, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3 + 1, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3 + 1, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3 + 3, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3 + 4, k1 - j5 - i6, l1 + l3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3, k1 - j5 - i6, l1 + l3 + 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 6, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3, ((k1 - j5) + 3) - i6, l1 + l3 + 6, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3, k1 - j5 - i6, l1 + l3 + 7, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 7, Blocks.stonebrick, 1); + int k7 = random.nextInt(100); + if (k7 <= 30) { + setBlock(world, j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5); + if (spawner != null) { + spawner.func_145881_a().setEntityName(DungeonHooks.getRandomDungeonMob(random)); + } + setBlock(world, j1 + l3, k1 - j5 - i6 - k4 - 1, l1 + l3 + 5, Blocks.dirt); } - j7 = 1; - k6 = 0; - flag2 = false; + l6 = 1; + i6 = 0; + flag = false; do { - if (world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) || world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) || world.isAirBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) - || world.getBlockId(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) == Block.waterStill.blockID || world.getBlockId(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) == Block.waterStill.blockID - || world.getBlockId(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 4) || world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 5) || world.isAirBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) + || world.getBlock(j1 - i3, k1 - j5 - l6, l1 - 4) == Blocks.water || world.getBlock(j1 - i3, k1 - j5 - l6, l1 - 5) == Blocks.water + || world.getBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) == Blocks.water) { + i6++; } else { - flag2 = true; + flag = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 1, Block.stoneBrick.blockID); - world.setBlock(j1 - k3, (k1 - l5 - k6) + 1, l1 - l2 - 1, Block.stoneBrick.blockID); - world.setBlock(j1 - k3, (k1 - l5 - k6) + 2, l1 - l2 - 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 3, Block.stoneBrick.blockID); - world.setBlock(j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 3, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3 - 1, k1 - l5 - k6, l1 - l2 - 6, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - k3 - 2, k1 - l5 - k6, l1 - l2 - 6, Block.stoneBrick.blockID); - world.setBlock(j1 - k3 - 2, ((k1 - l5) + 1) - k6, l1 - l2 - 6, Block.stoneBrick.blockID); - world.setBlock(j1 - k3 - 3, k1 - l5 - k6, l1 - l2 - 6, Block.stoneBrick.blockID); - i8 = random.nextInt(100); - if (i8 <= 60) { - world.setBlock(j1 - k3 - 1, k1 - l5 - k6 - i5, l1 - l2 - 6, Block.dirt.blockID); - world.setBlock(j1 - k3 - 1, k1 - l5 - k6 - i5 - 1, l1 - l2 - 6, Block.dirt.blockID); + } while (!flag && l6++ < 12); + setBlock(world, j1 - i3, k1 - j5 - i6, l1 - 4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - i3, ((k1 - j5) + 1) - i6, l1 - 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - i3, k1 - j5 - i6, l1 - 5, Blocks.stonebrick, 1); + setBlock(world, j1 - i3 - 1, k1 - j5 - i6, l1 - 5, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - i3 - 1, ((k1 - j5) + 1) - i6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - i3 - 1, ((k1 - j5) + 2) - i6, l1 - 5, Blocks.stonebrick, 1); + setBlock(world, j1 - i3 - 2, k1 - j5 - i6, l1 - 5, Blocks.stonebrick); + k7 = random.nextInt(100); + if (k7 <= 60) { + setBlock(world, j1 - i3 - 1, k1 - j5 - i6 - k4, l1 - 5, Blocks.dirt); + setBlock(world, j1 - i3 - 1, k1 - j5 - i6 - k4 - 1, l1 - 5, Blocks.dirt); } - j7 = 1; - k6 = 0; - flag2 = false; + } + if (i2 == 2) { + int k2 = random.nextInt(8) + 5; + int j3 = random.nextInt(8) + 5; + int i4 = random.nextInt(8) + 5; + int l4 = random.nextInt(4) + 3; + int k8 = random.nextInt(100); + int k5; + if (k8 <= 20) { + k5 = 0; + } else { + k5 = random.nextInt(4) + 5; + } + setBlock(world, j1, k1 - k5, l1, Blocks.stonebrick); + setBlockAndMetadata(world, j1, k1 - k5, l1 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, k1 - k5, l1 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, k1 - k5, l1 + 3, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, k1 - k5, l1 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - k5) + 1, l1 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - k5) + 2, l1 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - k5) + 3, l1 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - k5) + 1, l1 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + 1, k1 - k5, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + 2, k1 - k5, l1, Blocks.stonebrick, 1); + setBlock(world, j1, k1 - k5 - l4, l1 + 2, Blocks.dirt); + setBlock(world, j1, k1 - k5 - l4 - 1, l1 + 2, Blocks.dirt); + int i7 = 1; + int j6 = 0; + boolean flag1 = false; do { - if (world.isAirBlock(j1 + l2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) - || world.getBlockId(j1 + l2, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID || world.getBlockId(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID - || world.getBlockId(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 4) || world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 5) || world.isAirBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) + || world.getBlock(j1 - k2, k1 - k5 - i7, l1 - 4) == Blocks.water || world.getBlock(j1 - k2, k1 - k5 - i7, l1 - 5) == Blocks.water + || world.getBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) == Blocks.water) { + j6++; } else { - flag2 = true; + flag1 = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 + l2, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + l2 + 1, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 2) - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 3) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 2, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + l2 + 2, ((k1 - l5) + 1) - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + l2 + 2, ((k1 - l5) + 2) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 3, ((k1 - l5) + 2) - k6, l1 + j4, Block.stoneBrick.blockID); - world.setBlock(j1 + l2 + 4, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 4, ((k1 - l5) + 1) - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 + l2 + 5, k1 - l5 - k6, l1 + j4, Block.stoneBrick.blockID, 1, 2); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 + l2 + 2, k1 - l5 - k6 - i5, l1 + j4, Block.dirt.blockID); - world.setBlock(j1 + l2 + 2, k1 - l5 - k6 - i5 - 1, l1 + j4, Block.dirt.blockID); + } while (!flag1 && i7++ < 12); + setBlock(world, j1 - k2, k1 - k5 - j6, l1 - 3, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - k2, k1 - k5 - j6, l1 - 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 1) - j6, l1 - 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 2) - j6, l1 - 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, k1 - k5 - j6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 1) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 2) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 3) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2, ((k1 - k5) + 4) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlock(world, j1 - k2 - 1, k1 - k5 - j6, l1 - 5, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - k2 - 1, ((k1 - k5) + 1) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k2 - 1, ((k1 - k5) + 2) - j6, l1 - 5, Blocks.stonebrick, 1); + setBlock(world, j1 - k2 - 2, k1 - k5 - j6, l1 - 5, Blocks.stonebrick); + int l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world, j1 - k2 - 1, k1 - k5 - j6 - l4, l1 - 5, Blocks.dirt); + setBlock(world, j1 - k2 - 1, k1 - k5 - j6 - l4 - 1, l1 - 5, Blocks.dirt); } - j7 = 1; - k6 = 0; - flag2 = false; + i7 = 1; + j6 = 0; + flag1 = false; do { - if (world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) - || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) == Block.waterStill.blockID || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) == Block.waterStill.blockID - || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 4) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 6) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 8) + || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 4) == Blocks.water || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 6) == Blocks.water + || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 8) == Blocks.water) { + j6++; } else { - flag2 = true; + flag1 = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3, Block.stoneBrick.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 1, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 2, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 2, Block.stoneBrick.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 3, Block.stoneBrick.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 3, Block.stoneBrick.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 4, Block.stoneBrick.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 4, Block.stoneBrick.blockID, 1, 2); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 5, Block.stoneBrick.blockID, 1, 2); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 - 3, k1 - l5 - k6 - i5 - 1, l1 + k3 + 3, Block.dirt.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3)); + } while (!flag1 && i7++ < 12); + setBlock(world, j1 + i4, k1 - k5 - j6, l1 + 4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + i4, ((k1 - k5) + 1) - j6, l1 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + i4 + 1, k1 - k5 - j6, l1 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + i4 + 1, ((k1 - k5) + 1) - j6, l1 + 4, Blocks.stonebrick, 1); + setBlock(world, j1 + i4 + 2, k1 - k5 - j6, l1 + 4, Blocks.stonebrick); + setBlock(world, j1 + i4 + 3, k1 - k5 - j6, l1 + 4, Blocks.stonebrick); + setBlock(world, j1 + i4 + 3, ((k1 - k5) + 1) - j6, l1 + 4, Blocks.stonebrick); + setBlock(world, j1 + i4 + 4, k1 - k5 - j6, l1 + 4, Blocks.stonebrick); + setBlock(world, j1 + i4 + 5, k1 - k5 - j6, l1 + 4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + i4, k1 - k5 - j6, l1 + 5, Blocks.stonebrick, 1); + setBlock(world, j1 + i4, ((k1 - k5) + 1) - j6, l1 + 5, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + i4, ((k1 - k5) + 2) - j6, l1 + 6, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + i4, k1 - k5 - j6, l1 + 7, Blocks.stonebrick, 1); + setBlock(world, j1 + i4, ((k1 - k5) + 1) - j6, l1 + 7, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + i4, ((k1 - k5) + 2) - j6, l1 + 7, Blocks.stonebrick, 1); + setBlock(world, j1 + i4, k1 - k5 - j6, l1 + 8, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + i4, ((k1 - k5) + 1) - j6, l1 + 8, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + i4, k1 - k5 - j6, l1 + 9, Blocks.stonebrick, 1); + l7 = random.nextInt(100); + if (l7 <= 60) { + setBlock(world, j1 + i4, k1 - k5 - j6 - l4, l1 + 7, Blocks.dirt); + setBlock(world, j1 + i4, k1 - k5 - j6 - l4 - 1, l1 + 7, Blocks.dirt); } + i7 = 1; + j6 = 0; + flag1 = false; + do { + if (world.isAirBlock(j1 - j3, k1 - k5 - i7, l1 + i4) || world.isAirBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) || world.isAirBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) + || world.getBlock(j1 - j3, k1 - k5 - i7, l1 + i4) == Blocks.water || world.getBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) == Blocks.water + || world.getBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world, (j1 - j3) + 1, k1 - k5 - j6, l1 + i4, Blocks.stonebrick); + setBlockAndMetadata(world, (j1 - j3) + 1, ((k1 - k5) + 1) - j6, l1 + i4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, (j1 - j3) + 1, ((k1 - k5) + 2) - j6, l1 + i4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, (j1 - j3) + 2, k1 - k5 - j6, l1 + i4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - j3, k1 - k5 - j6, (l1 + i4) - 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 1, Blocks.stonebrick, 1); + setBlock(world, j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 1, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 1, Blocks.stonebrick, 1); + setBlock(world, j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 2, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 2, Blocks.stonebrick, 1); + setBlock(world, j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 2, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 5) - j6, (l1 + i4) - 2, Blocks.stonebrick, 1); + setBlock(world, j1 - j3, k1 - k5 - j6, (l1 + i4) - 3, Blocks.stonebrick); + setBlock(world, j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 3, Blocks.stonebrick); + setBlock(world, j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 3, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 3, Blocks.stonebrick, 1); + l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world, j1 - j3, k1 - k5 - j6 - l4, (l1 + i4) - 2, Blocks.dirt); + setBlock(world, j1 - j3, k1 - k5 - j6 - l4 - 1, (l1 + i4) - 2, Blocks.dirt); + } + i7 = 1; + j6 = 0; + flag1 = false; + do { + if (world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) || world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) || world.isAirBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) + || world.getBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) == Blocks.water || world.getBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) == Blocks.water + || world.getBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world, j1 + j3 + 4, k1 - k5 - j6, l1 - 6, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 6, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + j3 + 4, ((k1 - k5) + 2) - j6, l1 - 6, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + j3 + 4, k1 - k5 - j6, l1 - 7, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 7, Blocks.stonebrick, 1); + setBlock(world, j1 + j3 + 5, k1 - k5 - j6, l1 - 7, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + j3 + 5, ((k1 - k5) + 1) - j6, l1 - 7, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + j3 + 5, ((k1 - k5) + 2) - j6, l1 - 7, Blocks.stonebrick, 1); + setBlock(world, j1 + j3 + 6, k1 - k5 - j6, l1 - 7, Blocks.stonebrick); + l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world, j1 + j3 + 4, k1 - k5 - j6 - l4, l1 - 7, Blocks.dirt); + setBlock(world, j1 + j3 + 4, k1 - k5 - j6 - l4 - 1, l1 - 7, Blocks.dirt); + } + } + if (i2 != 3) { + return true; + } + int l2 = random.nextInt(8) + 5; + int k3 = random.nextInt(8) + 5; + int j4 = random.nextInt(8) + 5; + int i5 = random.nextInt(4) + 3; + int l8 = random.nextInt(100); + int l5; + if (l8 <= 20) { + l5 = 0; + } else { + l5 = random.nextInt(4) + 5; + } + setBlock(world, j1, k1 - l5, l1, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - 1, k1 - l5, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 1, (k1 - l5) + 1, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 1, (k1 - l5) + 2, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 1, (k1 - l5) + 3, l1, Blocks.stonebrick, 1); + setBlock(world, j1, (k1 - l5) + 1, l1, Blocks.stonebrick); + setBlockAndMetadata(world, j1, (k1 - l5) + 2, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - l5) + 3, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - l5) + 4, l1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1, (k1 - l5) + 5, l1, Blocks.stonebrick, 1); + setBlock(world, j1, k1 - l5, l1 + 1, Blocks.stonebrick); + setBlockAndMetadata(world, j1, (k1 - l5) + 2, l1 + 1, Blocks.stonebrick, 1); + setBlock(world, j1, k1 - l5, l1 + 2, Blocks.stonebrick); + setBlockAndMetadata(world, j1, (k1 - l5) + 1, l1 + 2, Blocks.stonebrick, 1); + setBlock(world, j1, k1 - l5 - i5, l1 + 1, Blocks.dirt); + setBlock(world, j1, k1 - l5 - i5 - 1, l1 + 1, Blocks.dirt); + int j7 = 1; + int k6 = 0; + boolean flag2 = false; + do { + if (world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) + || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) == Blocks.water || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) == Blocks.water + || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2 + 1, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2 + 2, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2 + 3, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 1, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 3) - k6, l1 + j4 + 1, Blocks.stonebrick, 1); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 2, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 2, Blocks.stonebrick, 1); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 3, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 3, Blocks.stonebrick, 1); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 4, Blocks.stonebrick); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 6, Blocks.stonebrick); + int i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world, j1 + k3 + l2, k1 - l5 - k6 - i5, l1 + j4 + 1, Blocks.dirt); + setBlock(world, j1 + k3 + l2, k1 - l5 - k6 - i5 - 1, l1 + j4 + 1, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) || world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) || world.isAirBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) + || world.getBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) == Blocks.water || world.getBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) == Blocks.water + || world.getBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world, j1 - k3, k1 - l5 - k6, l1 - l2 - 1, Blocks.stonebrick); + setBlock(world, j1 - k3, (k1 - l5 - k6) + 1, l1 - l2 - 1, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - k3, (k1 - l5 - k6) + 2, l1 - l2 - 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k3, k1 - l5 - k6, l1 - l2 - 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 2, Blocks.stonebrick, 1); + setBlock(world, j1 - k3, k1 - l5 - k6, l1 - l2 - 3, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 3, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k3, k1 - l5 - k6, l1 - l2 - 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - k3 - 1, k1 - l5 - k6, l1 - l2 - 6, Blocks.stonebrick, 1); + setBlock(world, j1 - k3 - 2, k1 - l5 - k6, l1 - l2 - 6, Blocks.stonebrick); + setBlock(world, j1 - k3 - 2, ((k1 - l5) + 1) - k6, l1 - l2 - 6, Blocks.stonebrick); + setBlock(world, j1 - k3 - 3, k1 - l5 - k6, l1 - l2 - 6, Blocks.stonebrick); + i8 = random.nextInt(100); + if (i8 <= 60) { + setBlock(world, j1 - k3 - 1, k1 - l5 - k6 - i5, l1 - l2 - 6, Blocks.dirt); + setBlock(world, j1 - k3 - 1, k1 - l5 - k6 - i5 - 1, l1 - l2 - 6, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 + l2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) + || world.getBlock(j1 + l2, k1 - l5 - j7, l1 + j4) == Blocks.water || world.getBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) == Blocks.water + || world.getBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world, j1 + l2, k1 - l5 - k6, l1 + j4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + l2 + 1, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlock(world, j1 + l2 + 1, ((k1 - l5) + 2) - k6, l1 + j4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + l2 + 1, ((k1 - l5) + 3) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlock(world, j1 + l2 + 2, k1 - l5 - k6, l1 + j4, Blocks.stonebrick); + setBlock(world, j1 + l2 + 2, ((k1 - l5) + 1) - k6, l1 + j4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + l2 + 2, ((k1 - l5) + 2) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlock(world, j1 + l2 + 3, ((k1 - l5) + 2) - k6, l1 + j4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 + l2 + 4, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l2 + 4, ((k1 - l5) + 1) - k6, l1 + j4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 + l2 + 5, k1 - l5 - k6, l1 + j4, Blocks.stonebrick, 1); + i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world, j1 + l2 + 2, k1 - l5 - k6 - i5, l1 + j4, Blocks.dirt); + setBlock(world, j1 + l2 + 2, k1 - l5 - k6 - i5 - 1, l1 + j4, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) + || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) == Blocks.water || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) == Blocks.water + || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world, j1 - 3, k1 - l5 - k6, l1 + k3, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 1, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 3, k1 - l5 - k6, l1 + k3 + 2, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 2, Blocks.stonebrick, 1); + setBlock(world, j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 2, Blocks.stonebrick); + setBlock(world, j1 - 3, k1 - l5 - k6, l1 + k3 + 3, Blocks.stonebrick); + setBlock(world, j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 3, Blocks.stonebrick); + setBlock(world, j1 - 3, k1 - l5 - k6, l1 + k3 + 4, Blocks.stonebrick); + setBlockAndMetadata(world, j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 4, Blocks.stonebrick, 1); + setBlockAndMetadata(world, j1 - 3, k1 - l5 - k6, l1 + k3 + 5, Blocks.stonebrick, 1); + i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world, j1 - 3, k1 - l5 - k6 - i5 - 1, l1 + k3 + 3, Blocks.dirt); + setBlock(world, j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3)); } return true; } + + private void setBlock(World w, int x, int y, int z){ + func_150515_a(w, x, y, z, Blocks.air); + } + + private void setBlock(World w, int x, int y, int z, Block bl){ + func_150515_a(w, x, y, z, bl); + } + + private void setBlockAndMetadata(World w, int x, int y, int z, Block bl, int meta){ + setBlockAndNotifyAdequately(w, x, y, z, bl, meta); + } } diff --git a/common/MysticRuins/StructureRuin.java b/common/MysticRuins/StructureRuin.java index 6c906a6..c8b1dd7 100644 --- a/common/MysticRuins/StructureRuin.java +++ b/common/MysticRuins/StructureRuin.java @@ -1,434 +1,432 @@ package mysticruins; -import java.util.Random; - import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.tileentity.TileEntityMobSpawner; import net.minecraft.world.World; import net.minecraft.world.gen.feature.WorldGenerator; import net.minecraftforge.common.DungeonHooks; +import java.util.Random; + public class StructureRuin extends WorldGenerator { public StructureRuin() { } @Override public boolean generate(World world, Random random, int i, int j, int k) { - int l = random.nextInt(100); - if (l >= 10) { + int j1 = (i + random.nextInt(8)) - random.nextInt(8); + int k1 = (j + random.nextInt(4)) - random.nextInt(4); + int l1 = (k + random.nextInt(8)) - random.nextInt(8); + if (k1 <= 0) { return false; } - for (int i1 = 0; i1 < 1; i1++) { - int j1 = (i + random.nextInt(8)) - random.nextInt(8); - int k1 = (j + random.nextInt(4)) - random.nextInt(4); - int l1 = (k + random.nextInt(8)) - random.nextInt(8); - if (!world.isAirBlock(j1, k1, l1) || world.getBlockId(j1, k1 - 1, l1) != Block.grass.blockID || !Block.pumpkin.canPlaceBlockAt(world, j1, k1, l1)) { - continue; - } - int i2 = random.nextInt(3) + 1; - if (i2 == 1) { - int j2 = random.nextInt(8) + 5; - int i3 = random.nextInt(8) + 5; - int l3 = random.nextInt(8) + 5; - int k4 = random.nextInt(4) + 3; - int j5 = 1; - int i6 = 0; - int l6 = 1; - boolean flag = false; - int k7 = random.nextInt(100); - int j8 = random.nextInt(100); - if (j8 <= 20) { - j5 = 0; - } else { - j5 = random.nextInt(4) + 5; - } - world.setBlock(j1, k1 - j5, l1, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - j5) + 1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 3, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 4, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - j5) + 5, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 3, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - j5) + 4, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - j5, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - j5) + 1, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - j5) + 2, l1 + 3, Block.cobblestone.blockID); - world.setBlock(j1, k1 - j5 - k4 - 1, l1 + 2, Block.dirt.blockID); - world.setBlock(j1, k1 - j5 - k4, l1 + 2, Block.chest.blockID); - ChestFiller.fillWithValuables(world.getBlockTileEntity(j1, k1 - j5 - k4, l1 + 2)); - l6 = 1; - i6 = 0; - flag = false; - do { - if (world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) - || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) == Block.waterStill.blockID || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) == Block.waterStill.blockID - || world.getBlockId(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) == Block.waterStill.blockID) { - i6++; - } else { - flag = true; - } - } while (!flag && l6++ < 12); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3 + 1, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3 + 1, ((k1 - j5) + 1) - i6, l1 + l3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3 + 2, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + l3 + 3, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3 + 4, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3 + 5, k1 - j5 - i6, l1 + l3 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 5, Block.cobblestone.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 3) - i6, l1 + l3 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3, k1 - j5 - i6, l1 + l3 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 7, Block.cobblestone.blockID); - world.setBlock(j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 7, Block.cobblestoneMossy.blockID); - k7 = random.nextInt(100); - if (k7 <= 30) { - world.setBlock(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5, Block.mobSpawner.blockID); - TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getBlockTileEntity(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5); - if (spawner != null) { - spawner.getSpawnerLogic().setMobID(DungeonHooks.getRandomDungeonMob(random)); - } - world.setBlock(j1 + l3, k1 - j5 - i6 - k4 - 1, l1 + l3 + 5, Block.dirt.blockID); - } - l6 = 1; - i6 = 0; - flag = false; - do { - if (world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 4) || world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 5) || world.isAirBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) - || world.getBlockId(j1 - i3, k1 - j5 - l6, l1 - 4) == Block.waterStill.blockID || world.getBlockId(j1 - i3, k1 - j5 - l6, l1 - 5) == Block.waterStill.blockID - || world.getBlockId(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) == Block.waterStill.blockID) { - i6++; - } else { - flag = true; - } - } while (!flag && l6++ < 12); - world.setBlock(j1 - i3, k1 - j5 - i6, l1 - 4, Block.cobblestone.blockID); - world.setBlock(j1 - i3, ((k1 - j5) + 1) - i6, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - i3, k1 - j5 - i6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - i3 - 1, k1 - j5 - i6, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1 - i3 - 1, ((k1 - j5) + 1) - i6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - i3 - 1, ((k1 - j5) + 2) - i6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - i3 - 2, k1 - j5 - i6, l1 - 5, Block.cobblestone.blockID); - k7 = random.nextInt(100); - if (k7 <= 60) { - world.setBlock(j1 - i3 - 1, k1 - j5 - i6 - k4, l1 - 5, Block.dirt.blockID); - world.setBlock(j1 - i3 - 1, k1 - j5 - i6 - k4 - 1, l1 - 5, Block.dirt.blockID); - } - } else if (i2 == 2) { - int k2 = random.nextInt(8) + 5; - int j3 = random.nextInt(8) + 5; - int i4 = random.nextInt(8) + 5; - int l4 = random.nextInt(4) + 3; - int k5 = 1; - int j6 = 0; - int i7 = 1; - boolean flag1 = false; - int l7 = random.nextInt(100); - int k8 = random.nextInt(100); - if (k8 <= 20) { - k5 = 0; - } else { - k5 = random.nextInt(4) + 5; - } - world.setBlock(j1, k1 - k5, l1, Block.cobblestone.blockID); - world.setBlock(j1, k1 - k5, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - k5, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - k5, l1 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - k5, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - k5) + 1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - k5) + 2, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - k5) + 3, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - k5) + 1, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + 1, k1 - k5, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + 2, k1 - k5, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - k5 - l4, l1 + 2, Block.dirt.blockID); - world.setBlock(j1, k1 - k5 - l4 - 1, l1 + 2, Block.dirt.blockID); - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 4) || world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 5) || world.isAirBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) - || world.getBlockId(j1 - k2, k1 - k5 - i7, l1 - 4) == Block.waterStill.blockID || world.getBlockId(j1 - k2, k1 - k5 - i7, l1 - 5) == Block.waterStill.blockID - || world.getBlockId(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 3, Block.cobblestone.blockID); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 1) - j6, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 2) - j6, l1 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, k1 - k5 - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 1) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 2) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 3) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2, ((k1 - k5) + 4) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2 - 1, k1 - k5 - j6, l1 - 5, Block.cobblestone.blockID); - world.setBlock(j1 - k2 - 1, ((k1 - k5) + 1) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2 - 1, ((k1 - k5) + 2) - j6, l1 - 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k2 - 2, k1 - k5 - j6, l1 - 5, Block.cobblestone.blockID); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 - k2 - 1, k1 - k5 - j6 - l4, l1 - 5, Block.dirt.blockID); - world.setBlock(j1 - k2 - 1, k1 - k5 - j6 - l4 - 1, l1 - 5, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 4) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 6) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 8) - || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 4) == Block.waterStill.blockID || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 6) == Block.waterStill.blockID - || world.getBlockId(j1 + i4, k1 - k5 - i7, l1 + 8) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4 + 1, k1 - k5 - j6, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4 + 1, ((k1 - k5) + 1) - j6, l1 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4 + 2, k1 - k5 - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4 + 3, k1 - k5 - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4 + 3, ((k1 - k5) + 1) - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4 + 4, k1 - k5 - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4 + 5, k1 - k5 - j6, l1 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 5, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 5, Block.cobblestone.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 2) - j6, l1 + 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 7, Block.cobblestone.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 2) - j6, l1 + 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 8, Block.cobblestone.blockID); - world.setBlock(j1 + i4, ((k1 - k5) + 1) - j6, l1 + 8, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6, l1 + 9, Block.cobblestoneMossy.blockID); - l7 = random.nextInt(100); - if (l7 <= 60) { - world.setBlock(j1 + i4, k1 - k5 - j6 - l4, l1 + 7, Block.dirt.blockID); - world.setBlock(j1 + i4, k1 - k5 - j6 - l4 - 1, l1 + 7, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 - j3, k1 - k5 - i7, l1 + i4) || world.isAirBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) || world.isAirBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) - || world.getBlockId(j1 - j3, k1 - k5 - i7, l1 + i4) == Block.waterStill.blockID || world.getBlockId(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) == Block.waterStill.blockID - || world.getBlockId((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock((j1 - j3) + 1, k1 - k5 - j6, l1 + i4, Block.cobblestone.blockID); - world.setBlock((j1 - j3) + 1, ((k1 - k5) + 1) - j6, l1 + i4, Block.cobblestoneMossy.blockID); - world.setBlock((j1 - j3) + 1, ((k1 - k5) + 2) - j6, l1 + i4, Block.cobblestoneMossy.blockID); - world.setBlock((j1 - j3) + 2, k1 - k5 - j6, l1 + i4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, k1 - k5 - j6, (l1 + i4) - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 1, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 2, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 2, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 5) - j6, (l1 + i4) - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - j3, k1 - k5 - j6, (l1 + i4) - 3, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 3, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 3, Block.cobblestone.blockID); - world.setBlock(j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 3, Block.cobblestoneMossy.blockID); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 - j3, k1 - k5 - j6 - l4, (l1 + i4) - 2, Block.dirt.blockID); - world.setBlock(j1 - j3, k1 - k5 - j6 - l4 - 1, (l1 + i4) - 2, Block.dirt.blockID); - } - i7 = 1; - j6 = 0; - flag1 = false; - do { - if (world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) || world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) || world.isAirBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) - || world.getBlockId(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) == Block.waterStill.blockID || world.getBlockId(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) == Block.waterStill.blockID - || world.getBlockId(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) == Block.waterStill.blockID) { - j6++; - } else { - flag1 = true; - } - } while (!flag1 && i7++ < 12); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6, l1 - 6, Block.cobblestone.blockID); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 2) - j6, l1 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 5, k1 - k5 - j6, l1 - 7, Block.cobblestone.blockID); - world.setBlock(j1 + j3 + 5, ((k1 - k5) + 1) - j6, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 5, ((k1 - k5) + 2) - j6, l1 - 7, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + j3 + 6, k1 - k5 - j6, l1 - 7, Block.cobblestone.blockID); - l7 = random.nextInt(100); - if (l7 <= 30) { - world.setBlock(j1 + j3 + 4, k1 - k5 - j6 - l4, l1 - 7, Block.dirt.blockID); - world.setBlock(j1 + j3 + 4, k1 - k5 - j6 - l4 - 1, l1 - 7, Block.dirt.blockID); - } - } - if (i2 != 3) { - continue; - } - int l2 = random.nextInt(8) + 5; - int k3 = random.nextInt(8) + 5; - int j4 = random.nextInt(8) + 5; - int i5 = random.nextInt(4) + 3; - int l5 = 1; - int k6 = 0; - int j7 = 1; - boolean flag2 = false; - int i8 = random.nextInt(100); - int l8 = random.nextInt(100); - if (l8 <= 20) { - l5 = 0; + if (!world.isAirBlock(j1, k1, l1) || world.getBlock(j1, k1 - 1, l1) != Blocks.grass || !Blocks.pumpkin.canPlaceBlockAt(world, j1, k1, l1)) { + return false; + } + int i2 = random.nextInt(3) + 1; + if (i2 == 1) { + int i3 = random.nextInt(8) + 5; + int l3 = random.nextInt(8) + 5; + int k4 = random.nextInt(4) + 3; + int j5; + int j8 = random.nextInt(100); + if (j8 <= 20) { + j5 = 0; } else { - l5 = random.nextInt(4) + 5; + j5 = random.nextInt(4) + 5; } - world.setBlock(j1, k1 - l5, l1, Block.cobblestone.blockID); - world.setBlock(j1 - 1, k1 - l5, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 1, (k1 - l5) + 1, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 1, (k1 - l5) + 2, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 1, (k1 - l5) + 3, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - l5) + 1, l1, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - l5) + 2, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - l5) + 3, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - l5) + 4, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, (k1 - l5) + 5, l1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - l5, l1 + 1, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - l5) + 2, l1 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - l5, l1 + 2, Block.cobblestone.blockID); - world.setBlock(j1, (k1 - l5) + 1, l1 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1, k1 - l5 - i5, l1 + 1, Block.dirt.blockID); - world.setBlock(j1, k1 - l5 - i5 - 1, l1 + 1, Block.dirt.blockID); - j7 = 1; - k6 = 0; - flag2 = false; - do { - if (world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) == Block.waterStill.blockID - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) == Block.waterStill.blockID - || world.getBlockId(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) == Block.waterStill.blockID) { - k6++; - } else { - flag2 = true; + for (int y = k1 - j5; y < k1 - j5 + 5; y++) { + if (y < k1 - j5 + 3) { + setBlock(world,j1, y, l1, pickBlock(random)); + setBlock(world,j1, y, l1 + 3, pickBlock(random)); } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2 + 1, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2 + 2, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2 + 3, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 1, Block.cobblestone.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 3) - k6, l1 + j4 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 2, Block.cobblestone.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 3, Block.cobblestone.blockID); - world.setBlock(j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 4, Block.cobblestone.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 6, Block.cobblestone.blockID); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 + k3 + l2, k1 - l5 - k6 - i5, l1 + j4 + 1, Block.dirt.blockID); - world.setBlock(j1 + k3 + l2, k1 - l5 - k6 - i5 - 1, l1 + j4 + 1, Block.dirt.blockID); - } - j7 = 1; - k6 = 0; - flag2 = false; - do { - if (world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) || world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) || world.isAirBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) - || world.getBlockId(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) == Block.waterStill.blockID || world.getBlockId(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) == Block.waterStill.blockID - || world.getBlockId(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) == Block.waterStill.blockID) { - k6++; - } else { - flag2 = true; + if (y > k1 - j5 + 1) { + setBlock(world,j1, y, l1 + 1, pickBlock(random)); + setBlock(world,j1, y, l1 + 2, pickBlock(random)); } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 1, Block.cobblestone.blockID); - world.setBlock(j1 - k3, (k1 - l5 - k6) + 1, l1 - l2 - 1, Block.cobblestone.blockID); - world.setBlock(j1 - k3, (k1 - l5 - k6) + 2, l1 - l2 - 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 3, Block.cobblestone.blockID); - world.setBlock(j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 3, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3, k1 - l5 - k6, l1 - l2 - 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3 - 1, k1 - l5 - k6, l1 - l2 - 6, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - k3 - 2, k1 - l5 - k6, l1 - l2 - 6, Block.cobblestone.blockID); - world.setBlock(j1 - k3 - 2, ((k1 - l5) + 1) - k6, l1 - l2 - 6, Block.cobblestone.blockID); - world.setBlock(j1 - k3 - 3, k1 - l5 - k6, l1 - l2 - 6, Block.cobblestone.blockID); - i8 = random.nextInt(100); - if (i8 <= 60) { - world.setBlock(j1 - k3 - 1, k1 - l5 - k6 - i5, l1 - l2 - 6, Block.dirt.blockID); - world.setBlock(j1 - k3 - 1, k1 - l5 - k6 - i5 - 1, l1 - l2 - 6, Block.dirt.blockID); } - j7 = 1; - k6 = 0; - flag2 = false; + setBlock(world,j1, (k1 - j5) + 5, l1 + 1, pickBlock(random)); + setBlock(world,j1, k1 - j5 - k4 - 1, l1 + 2, Blocks.dirt); + setBlock(world,j1, k1 - j5 - k4, l1 + 2, Blocks.chest); + ChestFiller.fillWithValuables(world.getTileEntity(j1, k1 - j5 - k4, l1 + 2)); + int l6 = 1; + int i6 = 0; + boolean flag = false; do { - if (world.isAirBlock(j1 + l2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) - || world.getBlockId(j1 + l2, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID || world.getBlockId(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID - || world.getBlockId(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) || world.isAirBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) + || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 4) == Blocks.water || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 5) == Blocks.water + || world.getBlock(j1 + l3, k1 - j5 - l6, l1 + l3 + 6) == Blocks.water) { + i6++; } else { - flag2 = true; + flag = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 + l2, k1 - l5 - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + l2 + 1, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 2) - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + l2 + 1, ((k1 - l5) + 3) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 2, k1 - l5 - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + l2 + 2, ((k1 - l5) + 1) - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + l2 + 2, ((k1 - l5) + 2) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 3, ((k1 - l5) + 2) - k6, l1 + j4, Block.cobblestone.blockID); - world.setBlock(j1 + l2 + 4, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 4, ((k1 - l5) + 1) - k6, l1 + j4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 + l2 + 5, k1 - l5 - k6, l1 + j4, Block.cobblestoneMossy.blockID); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 + l2 + 2, k1 - l5 - k6 - i5, l1 + j4, Block.dirt.blockID); - world.setBlock(j1 + l2 + 2, k1 - l5 - k6 - i5 - 1, l1 + j4, Block.dirt.blockID); + } while (!flag && l6++ < 12); + setBlock(world,j1 + l3, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 1, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 1, ((k1 - j5) + 1) - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 2, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 3, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 4, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3 + 5, k1 - j5 - i6, l1 + l3 + 4, pickBlock(random)); + setBlock(world,j1 + l3, k1 - j5 - i6, l1 + l3 + 5, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 5, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 6, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 3) - i6, l1 + l3 + 6, pickBlock(random)); + setBlock(world,j1 + l3, k1 - j5 - i6, l1 + l3 + 7, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 1) - i6, l1 + l3 + 7, pickBlock(random)); + setBlock(world,j1 + l3, ((k1 - j5) + 2) - i6, l1 + l3 + 7, pickBlock(random)); + int k7 = random.nextInt(100); + if (k7 <= 30) { + setBlock(world,j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5, Blocks.mob_spawner); + TileEntityMobSpawner spawner = (TileEntityMobSpawner) world.getTileEntity(j1 + l3, k1 - j5 - i6 - k4, l1 + l3 + 5); + if (spawner != null) { + spawner.func_145881_a().setEntityName(DungeonHooks.getRandomDungeonMob(random)); + } + setBlock(world,j1 + l3, k1 - j5 - i6 - k4 - 1, l1 + l3 + 5, Blocks.dirt); } - j7 = 1; - k6 = 0; - flag2 = false; + l6 = 1; + i6 = 0; + flag = false; do { - if (world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) - || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) == Block.waterStill.blockID || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) == Block.waterStill.blockID - || world.getBlockId(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) == Block.waterStill.blockID) { - k6++; + if (world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 4) || world.isAirBlock(j1 - i3, k1 - j5 - l6, l1 - 5) || world.isAirBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) + || world.getBlock(j1 - i3, k1 - j5 - l6, l1 - 4) == Blocks.water || world.getBlock(j1 - i3, k1 - j5 - l6, l1 - 5) == Blocks.water + || world.getBlock(j1 - i3 - 1, k1 - j5 - l6, l1 - 5) == Blocks.water) { + i6++; } else { - flag2 = true; + flag = true; } - } while (!flag2 && j7++ < 12); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3, Block.cobblestone.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 1, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 2, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 2, Block.cobblestone.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 3, Block.cobblestone.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 3, Block.cobblestone.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 4, Block.cobblestone.blockID); - world.setBlock(j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 4, Block.cobblestoneMossy.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6, l1 + k3 + 5, Block.cobblestoneMossy.blockID); - i8 = random.nextInt(100); - if (i8 <= 30) { - world.setBlock(j1 - 3, k1 - l5 - k6 - i5 - 1, l1 + k3 + 3, Block.dirt.blockID); - world.setBlock(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3, Block.chest.blockID); - ChestFiller.fillWithRares(world.getBlockTileEntity(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3)); + } while (!flag && l6++ < 12); + setBlock(world,j1 - i3, k1 - j5 - i6, l1 - 4, pickBlock(random)); + setBlock(world,j1 - i3, ((k1 - j5) + 1) - i6, l1 - 4, pickBlock(random)); + setBlock(world,j1 - i3, k1 - j5 - i6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - i3 - 1, k1 - j5 - i6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - i3 - 1, ((k1 - j5) + 1) - i6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - i3 - 1, ((k1 - j5) + 2) - i6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - i3 - 2, k1 - j5 - i6, l1 - 5, pickBlock(random)); + k7 = random.nextInt(100); + if (k7 <= 60) { + setBlock(world,j1 - i3 - 1, k1 - j5 - i6 - k4, l1 - 5, Blocks.dirt); + setBlock(world,j1 - i3 - 1, k1 - j5 - i6 - k4 - 1, l1 - 5, Blocks.dirt); } + } else if (i2 == 2) { + int k2 = random.nextInt(8) + 5; + int j3 = random.nextInt(8) + 5; + int i4 = random.nextInt(8) + 5; + int l4 = random.nextInt(4) + 3; + int k5; + int k8 = random.nextInt(100); + if (k8 <= 20) { + k5 = 0; + } else { + k5 = random.nextInt(4) + 5; + } + setBlock(world,j1, k1 - k5, l1, pickBlock(random)); + setBlock(world,j1, k1 - k5, l1 + 1, pickBlock(random)); + setBlock(world,j1, k1 - k5, l1 + 2, pickBlock(random)); + setBlock(world,j1, k1 - k5, l1 + 3, pickBlock(random)); + setBlock(world,j1, k1 - k5, l1 + 4, pickBlock(random)); + setBlock(world,j1, (k1 - k5) + 1, l1 + 2, pickBlock(random)); + setBlock(world,j1, (k1 - k5) + 2, l1 + 2, pickBlock(random)); + setBlock(world,j1, (k1 - k5) + 3, l1 + 2, pickBlock(random)); + setBlock(world,j1, (k1 - k5) + 1, l1 + 1, pickBlock(random)); + setBlock(world,j1 + 1, k1 - k5, l1, pickBlock(random)); + setBlock(world,j1 + 2, k1 - k5, l1, pickBlock(random)); + setBlock(world,j1, k1 - k5 - l4, l1 + 2, Blocks.dirt); + setBlock(world,j1, k1 - k5 - l4 - 1, l1 + 2, Blocks.dirt); + int i7 = 1; + int j6 = 0; + boolean flag1 = false; + do { + if (world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 4) || world.isAirBlock(j1 - k2, k1 - k5 - i7, l1 - 5) || world.isAirBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) + || world.getBlock(j1 - k2, k1 - k5 - i7, l1 - 4) == Blocks.water || world.getBlock(j1 - k2, k1 - k5 - i7, l1 - 5) == Blocks.water + || world.getBlock(j1 - k2 - 1, k1 - k5 - i7, l1 - 5) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world,j1 - k2, k1 - k5 - j6, l1 - 3, pickBlock(random)); + setBlock(world,j1 - k2, k1 - k5 - j6, l1 - 4, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 1) - j6, l1 - 4, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 2) - j6, l1 - 4, pickBlock(random)); + setBlock(world,j1 - k2, k1 - k5 - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 1) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 2) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 3) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2, ((k1 - k5) + 4) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2 - 1, k1 - k5 - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2 - 1, ((k1 - k5) + 1) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2 - 1, ((k1 - k5) + 2) - j6, l1 - 5, pickBlock(random)); + setBlock(world,j1 - k2 - 2, k1 - k5 - j6, l1 - 5, pickBlock(random)); + int l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world,j1 - k2 - 1, k1 - k5 - j6 - l4, l1 - 5, Blocks.dirt); + setBlock(world,j1 - k2 - 1, k1 - k5 - j6 - l4 - 1, l1 - 5, Blocks.dirt); + } + i7 = 1; + j6 = 0; + flag1 = false; + do { + if (world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 4) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 6) || world.isAirBlock(j1 + i4, k1 - k5 - i7, l1 + 8) + || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 4) == Blocks.water || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 6) == Blocks.water + || world.getBlock(j1 + i4, k1 - k5 - i7, l1 + 8) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world,j1 + i4, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 1) - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 1, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 1, ((k1 - k5) + 1) - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 2, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 3, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 3, ((k1 - k5) + 1) - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 4, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4 + 5, k1 - k5 - j6, l1 + 4, pickBlock(random)); + setBlock(world,j1 + i4, k1 - k5 - j6, l1 + 5, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 1) - j6, l1 + 5, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 2) - j6, l1 + 6, pickBlock(random)); + setBlock(world,j1 + i4, k1 - k5 - j6, l1 + 7, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 1) - j6, l1 + 7, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 2) - j6, l1 + 7, pickBlock(random)); + setBlock(world,j1 + i4, k1 - k5 - j6, l1 + 8, pickBlock(random)); + setBlock(world,j1 + i4, ((k1 - k5) + 1) - j6, l1 + 8, pickBlock(random)); + setBlock(world,j1 + i4, k1 - k5 - j6, l1 + 9, pickBlock(random)); + l7 = random.nextInt(100); + if (l7 <= 60) { + setBlock(world,j1 + i4, k1 - k5 - j6 - l4, l1 + 7, Blocks.dirt); + setBlock(world,j1 + i4, k1 - k5 - j6 - l4 - 1, l1 + 7, Blocks.dirt); + } + i7 = 1; + j6 = 0; + flag1 = false; + do { + if (world.isAirBlock(j1 - j3, k1 - k5 - i7, l1 + i4) || world.isAirBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) || world.isAirBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) + || world.getBlock(j1 - j3, k1 - k5 - i7, l1 + i4) == Blocks.water || world.getBlock(j1 - j3, k1 - k5 - i7, (l1 + i4) - 2) == Blocks.water + || world.getBlock((j1 - j3) + 1, k1 - k5 - i7, l1 + i4) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world,(j1 - j3) + 1, k1 - k5 - j6, l1 + i4, pickBlock(random)); + setBlock(world,(j1 - j3) + 1, ((k1 - k5) + 1) - j6, l1 + i4, pickBlock(random)); + setBlock(world,(j1 - j3) + 1, ((k1 - k5) + 2) - j6, l1 + i4, pickBlock(random)); + setBlock(world,(j1 - j3) + 2, k1 - k5 - j6, l1 + i4, pickBlock(random)); + setBlock(world,j1 - j3, k1 - k5 - j6, (l1 + i4) - 1, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 1, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 1, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 1, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 1, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 2, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 2, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 4) - j6, (l1 + i4) - 2, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 5) - j6, (l1 + i4) - 2, pickBlock(random)); + setBlock(world,j1 - j3, k1 - k5 - j6, (l1 + i4) - 3, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 1) - j6, (l1 + i4) - 3, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 2) - j6, (l1 + i4) - 3, pickBlock(random)); + setBlock(world,j1 - j3, ((k1 - k5) + 3) - j6, (l1 + i4) - 3, pickBlock(random)); + l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world,j1 - j3, k1 - k5 - j6 - l4, (l1 + i4) - 2, Blocks.dirt); + setBlock(world,j1 - j3, k1 - k5 - j6 - l4 - 1, (l1 + i4) - 2, Blocks.dirt); + } + i7 = 1; + j6 = 0; + flag1 = false; + do { + if (world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) || world.isAirBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) || world.isAirBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) + || world.getBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 6) == Blocks.water || world.getBlock(j1 + j3 + 4, k1 - k5 - i7, l1 - 7) == Blocks.water + || world.getBlock(j1 + j3 + 5, k1 - k5 - i7, l1 - 7) == Blocks.water) { + j6++; + } else { + flag1 = true; + } + } while (!flag1 && i7++ < 12); + setBlock(world,j1 + j3 + 4, k1 - k5 - j6, l1 - 6, pickBlock(random)); + setBlock(world,j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 6, pickBlock(random)); + setBlock(world,j1 + j3 + 4, ((k1 - k5) + 2) - j6, l1 - 6, pickBlock(random)); + setBlock(world,j1 + j3 + 4, k1 - k5 - j6, l1 - 7, pickBlock(random)); + setBlock(world,j1 + j3 + 4, ((k1 - k5) + 1) - j6, l1 - 7, pickBlock(random)); + setBlock(world,j1 + j3 + 5, k1 - k5 - j6, l1 - 7, pickBlock(random)); + setBlock(world,j1 + j3 + 5, ((k1 - k5) + 1) - j6, l1 - 7, pickBlock(random)); + setBlock(world,j1 + j3 + 5, ((k1 - k5) + 2) - j6, l1 - 7, pickBlock(random)); + setBlock(world,j1 + j3 + 6, k1 - k5 - j6, l1 - 7, pickBlock(random)); + l7 = random.nextInt(100); + if (l7 <= 30) { + setBlock(world,j1 + j3 + 4, k1 - k5 - j6 - l4, l1 - 7, Blocks.dirt); + setBlock(world,j1 + j3 + 4, k1 - k5 - j6 - l4 - 1, l1 - 7, Blocks.dirt); + } + } + if (i2 != 3) { + return true; + } + int l2 = random.nextInt(8) + 5; + int k3 = random.nextInt(8) + 5; + int j4 = random.nextInt(8) + 5; + int i5 = random.nextInt(4) + 3; + int l5; + int l8 = random.nextInt(100); + if (l8 <= 20) { + l5 = 0; + } else { + l5 = random.nextInt(4) + 5; + } + setBlock(world,j1, k1 - l5, l1, pickBlock(random)); + setBlock(world,j1 - 1, k1 - l5, l1, pickBlock(random)); + setBlock(world,j1 - 1, (k1 - l5) + 1, l1, pickBlock(random)); + setBlock(world,j1 - 1, (k1 - l5) + 2, l1, pickBlock(random)); + setBlock(world,j1 - 1, (k1 - l5) + 3, l1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 1, l1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 2, l1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 3, l1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 4, l1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 5, l1, pickBlock(random)); + setBlock(world,j1, k1 - l5, l1 + 1, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 2, l1 + 1, pickBlock(random)); + setBlock(world,j1, k1 - l5, l1 + 2, pickBlock(random)); + setBlock(world,j1, (k1 - l5) + 1, l1 + 2, pickBlock(random)); + setBlock(world,j1, k1 - l5 - i5, l1 + 1, Blocks.dirt); + setBlock(world,j1, k1 - l5 - i5 - 1, l1 + 1, Blocks.dirt); + int j7 = 1; + int k6 = 0; + boolean flag2 = false; + do { + if (world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) || world.isAirBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) + || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 2) == Blocks.water || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 3) == Blocks.water + || world.getBlock(j1 + k3 + l2, k1 - l5 - j7, l1 + j4 + 4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2 + 1, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2 + 2, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2 + 3, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 1, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 1, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 1, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 3) - k6, l1 + j4 + 1, pickBlock(random)); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 2, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 2) - k6, l1 + j4 + 2, pickBlock(random)); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 3, pickBlock(random)); + setBlock(world,j1 + k3 + l2, ((k1 - l5) + 1) - k6, l1 + j4 + 3, pickBlock(random)); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 4, pickBlock(random)); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6, l1 + j4 + 6, pickBlock(random)); + int i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world,j1 + k3 + l2, k1 - l5 - k6 - i5, l1 + j4 + 1, Blocks.dirt); + setBlock(world,j1 + k3 + l2, k1 - l5 - k6 - i5 - 1, l1 + j4 + 1, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) || world.isAirBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) || world.isAirBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) + || world.getBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 2) == Blocks.water || world.getBlock(j1 - k3, k1 - l5 - j7, l1 - l2 - 4) == Blocks.water + || world.getBlock(j1 - k3 - 2, k1 - l5 - j7, l1 - l2 - 6) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world,j1 - k3, k1 - l5 - k6, l1 - l2 - 1, pickBlock(random)); + setBlock(world,j1 - k3, (k1 - l5 - k6) + 1, l1 - l2 - 1, pickBlock(random)); + setBlock(world,j1 - k3, (k1 - l5 - k6) + 2, l1 - l2 - 1, pickBlock(random)); + setBlock(world,j1 - k3, k1 - l5 - k6, l1 - l2 - 2, pickBlock(random)); + setBlock(world,j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 2, pickBlock(random)); + setBlock(world,j1 - k3, k1 - l5 - k6, l1 - l2 - 3, pickBlock(random)); + setBlock(world,j1 - k3, ((k1 - l5) + 1) - k6, l1 - l2 - 3, pickBlock(random)); + setBlock(world,j1 - k3, k1 - l5 - k6, l1 - l2 - 4, pickBlock(random)); + setBlock(world,j1 - k3 - 1, k1 - l5 - k6, l1 - l2 - 6, pickBlock(random)); + setBlock(world,j1 - k3 - 2, k1 - l5 - k6, l1 - l2 - 6, pickBlock(random)); + setBlock(world,j1 - k3 - 2, ((k1 - l5) + 1) - k6, l1 - l2 - 6, pickBlock(random)); + setBlock(world,j1 - k3 - 3, k1 - l5 - k6, l1 - l2 - 6, pickBlock(random)); + i8 = random.nextInt(100); + if (i8 <= 60) { + setBlock(world,j1 - k3 - 1, k1 - l5 - k6 - i5, l1 - l2 - 6, Blocks.dirt); + setBlock(world,j1 - k3 - 1, k1 - l5 - k6 - i5 - 1, l1 - l2 - 6, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 + l2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) || world.isAirBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) + || world.getBlock(j1 + l2, k1 - l5 - j7, l1 + j4) == Blocks.water || world.getBlock(j1 + l2 + 2, k1 - l5 - j7, l1 + j4) == Blocks.water + || world.getBlock(j1 + l2 + 4, k1 - l5 - j7, l1 + j4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world,j1 + l2, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 1, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 1, ((k1 - l5) + 1) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 1, ((k1 - l5) + 2) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 1, ((k1 - l5) + 3) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 2, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 2, ((k1 - l5) + 1) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 2, ((k1 - l5) + 2) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 3, ((k1 - l5) + 2) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 4, k1 - l5 - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 4, ((k1 - l5) + 1) - k6, l1 + j4, pickBlock(random)); + setBlock(world,j1 + l2 + 5, k1 - l5 - k6, l1 + j4, pickBlock(random)); + i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world,j1 + l2 + 2, k1 - l5 - k6 - i5, l1 + j4, Blocks.dirt); + setBlock(world,j1 + l2 + 2, k1 - l5 - k6 - i5 - 1, l1 + j4, Blocks.dirt); + } + j7 = 1; + k6 = 0; + flag2 = false; + do { + if (world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) || world.isAirBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) + || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 1) == Blocks.water || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 3) == Blocks.water + || world.getBlock(j1 - 3, k1 - l5 - j7, l1 + k3 + 4) == Blocks.water) { + k6++; + } else { + flag2 = true; + } + } while (!flag2 && j7++ < 12); + setBlock(world,j1 - 3, k1 - l5 - k6, l1 + k3, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 1, pickBlock(random)); + setBlock(world,j1 - 3, k1 - l5 - k6, l1 + k3 + 2, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 2, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 2) - k6, l1 + k3 + 2, pickBlock(random)); + setBlock(world,j1 - 3, k1 - l5 - k6, l1 + k3 + 3, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 3, pickBlock(random)); + setBlock(world,j1 - 3, k1 - l5 - k6, l1 + k3 + 4, pickBlock(random)); + setBlock(world,j1 - 3, ((k1 - l5) + 1) - k6, l1 + k3 + 4, pickBlock(random)); + setBlock(world,j1 - 3, k1 - l5 - k6, l1 + k3 + 5, pickBlock(random)); + i8 = random.nextInt(100); + if (i8 <= 30) { + setBlock(world,j1 - 3, k1 - l5 - k6 - i5 - 1, l1 + k3 + 3, Blocks.dirt); + setBlock(world,j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3, Blocks.chest); + ChestFiller.fillWithRares(world.getTileEntity(j1 - 3, k1 - l5 - k6 - i5, l1 + k3 + 3)); } return true; } + + private static Block pickBlock(Random random) { + return random.nextBoolean() ? Blocks.cobblestone : Blocks.mossy_cobblestone; + } + + private void setBlock(World w, int x, int y, int z){ + func_150515_a(w, x, y, z, Blocks.air); + } + + private void setBlock(World w, int x, int y, int z, Block bl){ + func_150515_a(w, x, y, z, bl); + } + + private void setBlockAndMetadata(World w, int x, int y, int z, Block bl, int meta){ + setBlockAndNotifyAdequately(w, x, y, z, bl, meta); + } } diff --git a/common/MysticStones/Blocks/BlockPlanks.java b/common/MysticStones/Blocks/BlockPlanks.java index 7b73250..43460d7 100644 --- a/common/MysticStones/Blocks/BlockPlanks.java +++ b/common/MysticStones/Blocks/BlockPlanks.java @@ -1,27 +1,28 @@ package mysticstones.blocks; -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.util.Icon; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import mysticstones.MysticStones; +import net.minecraft.block.Block; +import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.util.IIcon; public class BlockPlanks extends BlockMulti { - public BlockPlanks(int ID) { - super(ID, Material.wood); - setHardness(2.5F); - setResistance(10F); - setUnlocalizedName("BlockMysticPlanks"); - setStepSound(Block.soundWoodFootstep); + public BlockPlanks() { + super(Material.wood); + setHardness(2.5F); + setResistance(10F); + setBlockName("BlockMysticPlanks"); + setStepSound(Block.soundTypeWood); } @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[ItemPlanks.PLANK_TYPE.length]; + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[MysticStones.PLANK_TYPE.size()]; for (int i = 0; i < textures.length; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemPlanks.PLANK_TYPE[i]); + textures[i] = iconRegister.registerIcon("mysticstones:" + MysticStones.PLANK_TYPE.get(i)); } } } diff --git a/common/MysticStones/Blocks/BlockReinforced.java b/common/MysticStones/Blocks/BlockReinforced.java index 3ae80e3..f827d04 100644 --- a/common/MysticStones/Blocks/BlockReinforced.java +++ b/common/MysticStones/Blocks/BlockReinforced.java @@ -1,33 +1,33 @@ package mysticstones.blocks; -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.util.Icon; -import net.minecraft.world.World; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.block.Block; +import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.util.IIcon; +import net.minecraft.world.IBlockAccess; public class BlockReinforced extends BlockMulti { - public BlockReinforced(int ID) { - super(ID, Material.iron); - setHardness(4F); - setResistance(2000F); - setUnlocalizedName("BlockMysticReinforcedBrick"); - setStepSound(Block.soundMetalFootstep); + public BlockReinforced() { + super(Material.iron); + setHardness(4F); + setResistance(2000F); + setBlockName("BlockMysticReinforcedBrick"); + setStepSound(Block.soundTypeMetal); } @Override - public boolean isBeaconBase(World worldObj, int x, int y, int z, int beaconX, int beaconY, int beaconZ) { + public boolean isBeaconBase(IBlockAccess worldObj, int x, int y, int z, int beaconX, int beaconY, int beaconZ) { return true; } @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[ItemReinforced.BRICK_TYPE.length]; + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[ItemReinforced.BRICK_TYPE.size()]; for (int i = 0; i < textures.length; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemReinforced.BRICK_TYPE[i] + " Bricks"); + textures[i] = iconRegister.registerIcon("mysticstones:" + ItemReinforced.BRICK_TYPE.get(i)); } } } diff --git a/common/MysticStones/Blocks/BlockStoneBricks.java b/common/MysticStones/Blocks/BlockStoneBricks.java index 85e4695..9da7dbb 100644 --- a/common/MysticStones/Blocks/BlockStoneBricks.java +++ b/common/MysticStones/Blocks/BlockStoneBricks.java @@ -1,27 +1,28 @@ package mysticstones.blocks; -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.util.Icon; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import mysticstones.MysticStones; +import net.minecraft.block.Block; +import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.util.IIcon; public class BlockStoneBricks extends BlockMulti { - public BlockStoneBricks(int ID) { - super(ID, Material.rock); - setHardness(2F); - setResistance(5F); - setUnlocalizedName("BlockMysticStoneBricks"); - setStepSound(Block.soundStoneFootstep); + public BlockStoneBricks() { + super(Material.rock); + setHardness(2F); + setResistance(5F); + setBlockName("BlockMysticStoneBricks"); + setStepSound(Block.soundTypeStone); } @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[ItemStoneBricks.STONEBRICK_TYPES.length]; + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[MysticStones.STONEBRICK_TYPES.size()]; for (int i = 0; i < textures.length; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemStoneBricks.STONEBRICK_TYPES[i]); + textures[i] = iconRegister.registerIcon("mysticstones:" + MysticStones.STONEBRICK_TYPES.get(i)); } } } diff --git a/common/MysticStones/Blocks/BlockStones.java b/common/MysticStones/Blocks/BlockStones.java index 9f1b2c5..3b15dad 100644 --- a/common/MysticStones/Blocks/BlockStones.java +++ b/common/MysticStones/Blocks/BlockStones.java @@ -1,22 +1,23 @@ package mysticstones.blocks; -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.util.MovingObjectPosition; -import net.minecraft.world.World; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import mysticstones.MysticStones; +import net.minecraft.block.Block; +import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.item.ItemStack; +import net.minecraft.util.IIcon; +import net.minecraft.util.MovingObjectPosition; +import net.minecraft.world.World; public class BlockStones extends BlockMulti { - public BlockStones(int ID) { - super(ID, Material.rock); - setHardness(1F); - setResistance(5F); - setUnlocalizedName("BlockMysticStones"); - setStepSound(Block.soundStoneFootstep); + public BlockStones() { + super(Material.rock); + setHardness(1F); + setResistance(5F); + setBlockName("BlockMysticStones"); + setStepSound(Block.soundTypeStone); } @Override @@ -48,15 +49,10 @@ public class BlockStones extends BlockMulti { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[ItemStones.STONE_TYPES.length]; + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[MysticStones.STONE_TYPES.size()]; for (int i = 0; i < textures.length; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemStones.STONE_TYPES[i]); + textures[i] = iconRegister.registerIcon("mysticstones:" + MysticStones.STONE_TYPES.get(i)); } } - - @Override - protected boolean canSilkHarvest() { - return true; - } } diff --git a/common/MysticStones/Blocks/ItemPlanks.java b/common/MysticStones/Blocks/ItemPlanks.java deleted file mode 100644 index 03f0608..0000000 --- a/common/MysticStones/Blocks/ItemPlanks.java +++ /dev/null @@ -1,11 +0,0 @@ -package mysticstones.blocks; - -import mysticstones.MysticStones; - -public class ItemPlanks extends ItemBlockMulti { - public static final String[] PLANK_TYPE = new String[] { "Purple Planks", "Green Planks", "Black Planks", "Orange Planks", "Red Planks", "Blue Planks", "Yellow Planks" }; - - public ItemPlanks(int par1) { - super(par1, MysticStones.Planks, PLANK_TYPE); - } -} diff --git a/common/MysticStones/Blocks/ItemReinforced.java b/common/MysticStones/Blocks/ItemReinforced.java index c16eeac..508dbb9 100644 --- a/common/MysticStones/Blocks/ItemReinforced.java +++ b/common/MysticStones/Blocks/ItemReinforced.java @@ -1,24 +1,27 @@ package mysticstones.blocks; -import java.util.List; - -import mysticstones.MysticStones; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemStack; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.block.Block; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.item.ItemStack; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; public class ItemReinforced extends ItemBlockMulti { - public static final String[] BRICK_TYPE = new String[] { "Mithril Bricks", "Verdite Bricks", "Iridium Bricks", "Adamantine Bricks", "Tourmaline Bricks", "Topaz Bricks", "Amethyst Bricks", - "Agate Bricks" }; + public static final ArrayList BRICK_TYPE = new ArrayList(Arrays.asList("Mithril Bricks", "Verdite Bricks", "Iridium Bricks", "Adamantine Bricks", "Tourmaline Bricks", "Topaz Bricks", "Amethyst Bricks", + "Agate Bricks")); - public ItemReinforced(int par1) { - super(par1, MysticStones.ReinforcedBricks, BRICK_TYPE); + public ItemReinforced(Block block) { + super(block, BRICK_TYPE); } @Override @SideOnly(Side.CLIENT) public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List, boolean par4) { + super.addInformation(par1ItemStack, par2EntityPlayer, par3List, par4); if (par4) { par3List.add("Works As A Beacon Block Too!"); } diff --git a/common/MysticStones/Blocks/ItemStoneBricks.java b/common/MysticStones/Blocks/ItemStoneBricks.java deleted file mode 100644 index eaed36f..0000000 --- a/common/MysticStones/Blocks/ItemStoneBricks.java +++ /dev/null @@ -1,12 +0,0 @@ -package mysticstones.blocks; - -import mysticstones.MysticStones; - -public class ItemStoneBricks extends ItemBlockMulti { - public static final String[] STONEBRICK_TYPES = new String[] { "Anorthosite Bricks", "Limestone Bricks", "Marble Bricks", "Migmatite Bricks", "Orthogneiss Bricks", "Slate Bricks", - "Travertine Bricks" }; - - public ItemStoneBricks(int par1) { - super(par1, MysticStones.StoneBricks, STONEBRICK_TYPES); - } -} diff --git a/common/MysticStones/Blocks/ItemStones.java b/common/MysticStones/Blocks/ItemStones.java deleted file mode 100644 index 2a60dd4..0000000 --- a/common/MysticStones/Blocks/ItemStones.java +++ /dev/null @@ -1,12 +0,0 @@ -package mysticstones.blocks; - -import mysticstones.MysticStones; - -public class ItemStones extends ItemBlockMulti { - public static final String[] STONE_TYPES = new String[] { "Smooth Anorthosite", "Anorthosite", "Smooth Limestone", "Limestone", "Smooth Marble", "Marble", "Smooth Migmatite", "Migmatite", - "Smooth Orthogneiss", "Orthogneiss", "Smooth Slate", "Slate", "Smooth Travertine", "Travertine" }; - - public ItemStones(int par1) { - super(par1, MysticStones.Stones, STONE_TYPES); - } -} diff --git a/common/MysticStones/MysticStones.java b/common/MysticStones/MysticStones.java index 0b1b240..9d269c8 100644 --- a/common/MysticStones/MysticStones.java +++ b/common/MysticStones/MysticStones.java @@ -1,51 +1,62 @@ package mysticstones; -import mysticstones.blocks.BlockPlanks; -import mysticstones.blocks.BlockReinforced; -import mysticstones.blocks.BlockStoneBricks; -import mysticstones.blocks.BlockStones; -import mysticstones.blocks.ItemPlanks; -import mysticstones.blocks.ItemReinforced; -import mysticstones.blocks.ItemStoneBricks; -import mysticstones.blocks.ItemStones; -import mysticstones.util.Config; -import mysticstones.util.Localizations; -import mysticstones.util.RecipeHandler; -import mysticstones.util.TabMysticStones; -import mysticstones.worldgen.WorldGeneratorStones; -import net.minecraft.block.Block; -import net.minecraft.creativetab.CreativeTabs; import cpw.mods.fml.common.Mod; import cpw.mods.fml.common.Mod.EventHandler; import cpw.mods.fml.common.Mod.Instance; import cpw.mods.fml.common.event.FMLPreInitializationEvent; -import cpw.mods.fml.common.network.NetworkMod; import cpw.mods.fml.common.registry.GameRegistry; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import mysticstones.blocks.*; +import mysticstones.util.Config; +import mysticstones.util.RecipeHandler; +import mysticstones.worldgen.WorldGeneratorStones; +import net.minecraft.block.Block; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.item.Item; -@Mod(modid = "Mystic Stones", name = "Mystic Stones", version = "0.1") -@NetworkMod(clientSideRequired = true) -public class MysticStones { - @Instance("Mystic Stones") +import java.util.ArrayList; +import java.util.Arrays; + +@Mod(modid = "mysticstones", name = "Mystic Stones", version = "0.2") +public final class MysticStones { + @Instance("mysticstones") public static MysticStones instance; - public static Block Planks, Stones, StoneBricks, ReinforcedBricks; - public static final CreativeTabs MysticStonesTab = new TabMysticStones("MysticStonesTab"); + public static boolean ENABLE = true; + public static Block planks, stones, stoneBricks, reinforcedBricks; + public static CreativeTabs MysticStonesTab; + public static final ArrayList PLANK_TYPE = new ArrayList(Arrays.asList("Purple Planks", "Green Planks", "Black Planks", "Orange Planks", "Red Planks", "Blue Planks", "Yellow Planks")); + public static final ArrayList STONEBRICK_TYPES = new ArrayList(Arrays.asList("Anorthosite Bricks", "Limestone Bricks", "Marble Bricks", "Migmatite Bricks", "Orthogneiss Bricks", "Slate Bricks", + "Travertine Bricks")); + public static final ArrayList STONE_TYPES = new ArrayList(Arrays.asList("Smooth Anorthosite", "Anorthosite", "Smooth Limestone", "Limestone", "Smooth Marble", "Marble", "Smooth Migmatite", "Migmatite", + "Smooth Orthogneiss", "Orthogneiss", "Smooth Slate", "Slate", "Smooth Travertine", "Travertine")); - @EventHandler + + @EventHandler public void preInit(FMLPreInitializationEvent event) { Config.initialize(event.getSuggestedConfigurationFile()); - Planks = new BlockPlanks(Config.PlanksID); - Stones = new BlockStones(Config.StonesID); - StoneBricks = new BlockStoneBricks(Config.StoneBricksID); - ReinforcedBricks = new BlockReinforced(Config.ReinforcedBricksID); - GameRegistry.registerBlock(Planks, ItemPlanks.class, "Planks"); - GameRegistry.registerBlock(Stones, ItemStones.class, "Stones"); - GameRegistry.registerBlock(StoneBricks, ItemStoneBricks.class, "StoneBricks"); - GameRegistry.registerBlock(ReinforcedBricks, ItemReinforced.class, "Reinforcedbricks"); - Localizations.Initialize(); - RecipeHandler.CraftPlanks(); - RecipeHandler.CraftStoneBricks(); - RecipeHandler.CraftReinforced(); - RecipeHandler.CraftElse(); - GameRegistry.registerWorldGenerator(new WorldGeneratorStones()); + if(ENABLE){ + MysticStonesTab = new CreativeTabs("MysticStonesTab") { + @Override + @SideOnly(Side.CLIENT) + public int func_151243_f() + { + return 4; + } + @Override + public Item getTabIconItem() { + return Item.getItemFromBlock(MysticStones.reinforcedBricks); + } + }; + planks = GameRegistry.registerBlock(new BlockPlanks(), ItemBlockMulti.class, "Planks", PLANK_TYPE); + stones = GameRegistry.registerBlock(new BlockStones(), ItemBlockMulti.class, "Stones", STONE_TYPES); + stoneBricks = GameRegistry.registerBlock(new BlockStoneBricks(), ItemBlockMulti.class, "StoneBricks", STONEBRICK_TYPES); + reinforcedBricks = GameRegistry.registerBlock(new BlockReinforced(), ItemReinforced.class, "Reinforcedbricks"); + RecipeHandler.craftPlanks(); + RecipeHandler.craftStoneBricks(); + RecipeHandler.craftReinforced(); + RecipeHandler.craftElse(); + GameRegistry.registerWorldGenerator(new WorldGeneratorStones(), 1); + } } } diff --git a/common/MysticStones/Util/Config.java b/common/MysticStones/Util/Config.java index 45210ed..438de39 100644 --- a/common/MysticStones/Util/Config.java +++ b/common/MysticStones/Util/Config.java @@ -1,27 +1,23 @@ package mysticstones.util; -import java.util.List; +import mysticstones.MysticStones; +import net.minecraftforge.common.config.Configuration; + import java.io.File; import java.util.ArrayList; - -import net.minecraftforge.common.Configuration; +import java.util.List; public class Config { - public static int PlanksID; - public static int StonesID; - public static int StoneBricksID; - public static int ReinforcedBricksID; - public static int Rare; - public static List allowed = new ArrayList(); + public static final String[] keys = { "anorthosite", "limestone", "marble", "migmatite", "orthogneiss", "slate", "travertine" }; + public static int[] rare = new int[keys.length]; + public static List allowed = new ArrayList(); public static void initialize(File file) { Configuration config = new Configuration(file); - config.load(); - PlanksID = config.getBlock("Plank IDs", 509).getInt(); - StonesID = config.getBlock("Stone IDs", 510).getInt(); - StoneBricksID = config.getBlock("Stone Brick IDs", 511).getInt(); - ReinforcedBricksID = config.getBlock("Reinforced Brick IDs", 512).getInt(); - Rare = config.get("Generation", "Rarity of Stones", 3).getInt(); + MysticStones.ENABLE = config.get("General", "Enable", true).getBoolean(true); + for (int i = 0; i < rare.length; i++) { + rare[i] = config.get("Generation", "Rarity of " + keys[i], 3).getInt(); + } for (String id : config.get("Generation", "Allowed Dimension ID", "0,").getString().split(",")) { try { allowed.add(Integer.parseInt(id.trim())); diff --git a/common/MysticStones/Util/Localizations.java b/common/MysticStones/Util/Localizations.java deleted file mode 100644 index bd81ec7..0000000 --- a/common/MysticStones/Util/Localizations.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticstones.util; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Enumeration; -import java.util.regex.Matcher; -import java.util.regex.Pattern; -import java.util.zip.ZipEntry; -import java.util.zip.ZipException; -import java.util.zip.ZipFile; - -import mysticstones.MysticStones; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.registry.LanguageRegistry; - -/* - * - * All credits go to copygirl (or copy....boy) for this one - * Couldn't have done any of this without your - * repository, many thanks friend c: - * - */ -public class Localizations { - private Localizations() { - } - - public static void Initialize() { - File source = Loader.instance().getReversedModObjectList().get(MysticStones.instance).getSource(); - Pattern pattern = Pattern.compile(".*(assets/" + "mysticmods/lang/(.+)\\.(.+))"); - for (String file : getResources(source, pattern)) { - Matcher matcher = pattern.matcher(file); - matcher.find(); - String resource = "/" + matcher.group(1); - String lang = matcher.group(2); - boolean isXML = matcher.group(3).equalsIgnoreCase("XML"); - LanguageRegistry.instance().loadLocalization(resource, lang, isXML); - } - } - - private static Collection getResources(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - if (file.isDirectory()) - retval.addAll(getResourcesFromDirectory(file, pattern)); - else - retval.addAll(getResourcesFromJarFile(file, pattern)); - return retval; - } - - private static Collection getResourcesFromDirectory(File directory, Pattern pattern) { - ArrayList retval = new ArrayList(); - File[] FileList = directory.listFiles(); - for (File file : FileList) { - if (file.isDirectory()) { - retval.addAll(getResourcesFromDirectory(file, pattern)); - } else - try { - String fileName = file.getCanonicalPath().replace('\\', '/'); - boolean accept = pattern.matcher(fileName).matches(); - if (accept) - retval.add(fileName); - } catch (final IOException e) { - throw new Error(e); - } - } - return retval; - } - - private static Collection getResourcesFromJarFile(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - ZipFile Zip; - try { - Zip = new ZipFile(file); - } catch (ZipException Ex) { - throw new Error(Ex); - } catch (IOException Ex) { - throw new Error(Ex); - } - Enumeration entries = Zip.entries(); - while (entries.hasMoreElements()) { - ZipEntry ZipE = entries.nextElement(); - String FileName = ZipE.getName(); - boolean accept = pattern.matcher(FileName).matches(); - if (accept) - retval.add(FileName); - } - try { - Zip.close(); - } catch (IOException Ex) { - throw new Error(Ex); - } - return retval; - } -} diff --git a/common/MysticStones/Util/RecipeHandler.java b/common/MysticStones/Util/RecipeHandler.java index 3e6520d..8012f2d 100644 --- a/common/MysticStones/Util/RecipeHandler.java +++ b/common/MysticStones/Util/RecipeHandler.java @@ -1,48 +1,45 @@ package mysticstones.util; +import cpw.mods.fml.common.registry.GameRegistry; import mysticstones.MysticStones; import net.minecraft.item.ItemStack; import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraftforge.oredict.OreDictionary; import net.minecraftforge.oredict.ShapedOreRecipe; import net.minecraftforge.oredict.ShapelessOreRecipe; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.registry.GameRegistry; public class RecipeHandler { public static final String[] MATERIALS = { "ingotMithril", "ingotVerdite", "ingotIridium", "ingotAdamantine", "gemTourmaline", "gemTopaz", "gemAmethyst", "gemAgate" }; public static final String[] STONES = { "anorthositeSmooth", "Anorthosite", "limestoneSmooth", "limestone", "marbleSmooth", "marble", "migmatiteSmooth", "migmatite", "orthogneissSmooth", "orthogneiss", "slateSmooth", "slate", "travertineSmooth", "travertine" }; - public static void CraftElse() { + public static void craftElse() { //smelting for (int i = 1; i < 14; i += 2) { - FurnaceRecipes.smelting().addSmelting(MysticStones.Stones.blockID, i, new ItemStack(MysticStones.Stones, 1, i - 1), 0.1F); + FurnaceRecipes.smelting().func_151394_a(new ItemStack(MysticStones.stones, 1, i), new ItemStack(MysticStones.stones, 1, i - 1), 0.1F); } } - public static void CraftPlanks() { + public static void craftPlanks() { for (int i = 0; i < 7; i++) { - ItemStack stack = new ItemStack(MysticStones.Planks, 1, i); + ItemStack stack = new ItemStack(MysticStones.planks, 1, i); OreDictionary.registerOre("plankWood", stack); - OreDictionary.registerOre(STONES[2 * i], new ItemStack(MysticStones.Stones, 1, 2 * i)); - OreDictionary.registerOre(STONES[2 * i + 1], new ItemStack(MysticStones.Stones, 1, 2 * i + 1)); + OreDictionary.registerOre(STONES[2 * i], new ItemStack(MysticStones.stones, 1, 2 * i)); + OreDictionary.registerOre(STONES[2 * i + 1], new ItemStack(MysticStones.stones, 1, 2 * i + 1)); GameRegistry.addRecipe(new ShapelessOreRecipe(stack, "plankWood", STONES[2 * i])); GameRegistry.addRecipe(new ShapelessOreRecipe(stack, "plankWood", STONES[2 * i + 1])); } } - public static void CraftReinforced() { - if (Loader.isModLoaded("MysticOres")) { - for (int i = 0; i < MATERIALS.length; i++) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(MysticStones.ReinforcedBricks, 1, i), true, "#$#", "$$$", "#$#", '$', MATERIALS[i], '#', "stone")); - } - } + public static void craftReinforced() { + for (int i = 0; i < MATERIALS.length; i++) { + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(MysticStones.reinforcedBricks, 1, i), true, "#$#", "$$$", "#$#", '$', MATERIALS[i], '#', "stone")); + } } - public static void CraftStoneBricks() { + public static void craftStoneBricks() { for (int i = 0; i < 7; i++) { - GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(MysticStones.StoneBricks, 4, i), "##", "##", '#', STONES[2 * i])); + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(MysticStones.stoneBricks, 4, i), "##", "##", '#', STONES[2 * i])); } } } diff --git a/common/MysticStones/Util/TabMysticStones.java b/common/MysticStones/Util/TabMysticStones.java deleted file mode 100644 index 33d30ba..0000000 --- a/common/MysticStones/Util/TabMysticStones.java +++ /dev/null @@ -1,16 +0,0 @@ -package mysticstones.util; - -import mysticstones.MysticStones; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.ItemStack; - -public class TabMysticStones extends CreativeTabs { - public TabMysticStones(String par2Str) { - super(par2Str); - } - - @Override - public ItemStack getIconItemStack() { - return new ItemStack(MysticStones.ReinforcedBricks, 1, 4); - } -} diff --git a/common/MysticWorld/Biome/BiomeGenBasic.java b/common/MysticWorld/Biome/BiomeGenBasic.java index 1498d6c..bbb927b 100644 --- a/common/MysticWorld/Biome/BiomeGenBasic.java +++ b/common/MysticWorld/Biome/BiomeGenBasic.java @@ -1,25 +1,26 @@ package mysticworld.biome; -import java.util.Random; - -import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.monster.EntityGhast; -import net.minecraft.entity.monster.EntityGiantZombie; +import net.minecraft.block.Block; import net.minecraft.world.biome.BiomeGenBase; -import net.minecraft.world.biome.SpawnListEntry; -import net.minecraft.world.gen.feature.WorldGenerator; public class BiomeGenBasic extends BiomeGenBase { - - public BiomeGenBasic(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, int blockTop, int blockFiller) { + public BiomeGenBasic(int id, Block blockTop, Block blockFiller) { + super(id); + this.topBlock = blockTop; + this.fillerBlock = blockFiller; + } + + public BiomeGenBasic(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk) { super(id); - this.topBlock = (byte) blockTop; - this.fillerBlock = (byte) blockFiller; this.theBiomeDecorator.treesPerChunk = treesChunk; this.theBiomeDecorator.grassPerChunk = grassChunk; this.theBiomeDecorator.flowersPerChunk = flowerChunk; - this.theBiomeDecorator.reedsPerChunk = reedsChunk;; + this.theBiomeDecorator.reedsPerChunk = reedsChunk; } - -} + public BiomeGenBasic(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, Block blockTop, Block blockFiller) { + this(id, treesChunk, grassChunk, flowerChunk, reedsChunk); + this.topBlock = blockTop; + this.fillerBlock = blockFiller; + } +} diff --git a/common/MysticWorld/Biome/BiomeGenGlacier.java b/common/MysticWorld/Biome/BiomeGenGlacier.java index 50e406b..b220fcd 100644 --- a/common/MysticWorld/Biome/BiomeGenGlacier.java +++ b/common/MysticWorld/Biome/BiomeGenGlacier.java @@ -1,29 +1,10 @@ package mysticworld.biome; -import java.util.Random; +import net.minecraft.block.Block; -import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.monster.EntityGhast; -import net.minecraft.entity.monster.EntityGiantZombie; -import net.minecraft.world.biome.BiomeGenBase; -import net.minecraft.world.biome.SpawnListEntry; -import net.minecraft.world.gen.feature.WorldGenerator; - -public class BiomeGenGlacier extends BiomeGenBase { - - public BiomeGenGlacier(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, int blockTop, int blockFiller) { - super(id); - this.topBlock = (byte) blockTop; - this.fillerBlock = (byte) blockFiller; - this.theBiomeDecorator.treesPerChunk = treesChunk; - this.theBiomeDecorator.grassPerChunk = grassChunk; - this.theBiomeDecorator.flowersPerChunk = flowerChunk; - this.theBiomeDecorator.reedsPerChunk = reedsChunk;; - this.spawnableCreatureList.clear(); - this.spawnableMonsterList.clear(); - this.spawnableWaterCreatureList.clear(); - this.spawnableCreatureList.add(new SpawnListEntry(net.minecraft.entity.passive.EntityWolf.class, 5, 4, 4)); - this.waterColorMultiplier = 15397370; - } +public class BiomeGenGlacier extends BiomeGenTundra { + public BiomeGenGlacier(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, Block blockTop, Block blockFiller) { + super(id, treesChunk, grassChunk, flowerChunk, reedsChunk, blockTop, blockFiller); + this.waterColorMultiplier = 15397370; + } } - diff --git a/common/MysticWorld/Biome/BiomeGenJungle.java b/common/MysticWorld/Biome/BiomeGenJungle.java index 98a4025..dbb0fff 100644 --- a/common/MysticWorld/Biome/BiomeGenJungle.java +++ b/common/MysticWorld/Biome/BiomeGenJungle.java @@ -1,58 +1,19 @@ package mysticworld.biome; -import java.util.Random; -import net.minecraft.block.Block; -import net.minecraft.entity.passive.EntityChicken; -import net.minecraft.entity.passive.EntityOcelot; -import net.minecraft.world.World; -import net.minecraft.world.biome.BiomeGenBase; -import net.minecraft.world.biome.SpawnListEntry; -import net.minecraft.world.gen.feature.WorldGenHugeTrees; -import net.minecraft.world.gen.feature.WorldGenShrub; -import net.minecraft.world.gen.feature.WorldGenTallGrass; +import net.minecraft.world.gen.feature.WorldGenAbstractTree; +import net.minecraft.world.gen.feature.WorldGenMegaJungle; import net.minecraft.world.gen.feature.WorldGenTrees; -import net.minecraft.world.gen.feature.WorldGenVines; -import net.minecraft.world.gen.feature.WorldGenerator; -public class BiomeGenJungle extends BiomeGenBase -{ - public BiomeGenJungle(int par1) - { - super(par1); - this.theBiomeDecorator.treesPerChunk = 50; - this.theBiomeDecorator.grassPerChunk = 25; - this.theBiomeDecorator.flowersPerChunk = 4; - this.spawnableMonsterList.add(new SpawnListEntry(EntityOcelot.class, 2, 1, 1)); - this.spawnableCreatureList.add(new SpawnListEntry(EntityChicken.class, 10, 4, 4)); - } +import java.util.Random; - /** - * Gets a WorldGen appropriate for this biome. - */ - public WorldGenerator getRandomWorldGenForTrees(Random par1Random) - { - return (WorldGenerator)(par1Random.nextInt(10) == 0 ? this.worldGeneratorBigTree : (par1Random.nextInt(2) == 0 ? new WorldGenHugeTrees(false, 10 + par1Random.nextInt(20), 3, 3) : new WorldGenTrees(false, 4 + par1Random.nextInt(7), 3, 3, true))); - } +public class BiomeGenJungle extends net.minecraft.world.biome.BiomeGenJungle { + public BiomeGenJungle(int par1) { + super(par1, false); + } - /** - * Gets a WorldGen appropriate for this biome. - */ - public WorldGenerator getRandomWorldGenForGrass(Random par1Random) - { - return par1Random.nextInt(4) == 0 ? new WorldGenTallGrass(Block.tallGrass.blockID, 2) : new WorldGenTallGrass(Block.tallGrass.blockID, 1); - } - - public void decorate(World par1World, Random par2Random, int par3, int par4) - { - super.decorate(par1World, par2Random, par3, par4); - WorldGenVines worldgenvines = new WorldGenVines(); - - for (int k = 0; k < 50; ++k) - { - int l = par3 + par2Random.nextInt(16) + 8; - byte b0 = 64; - int i1 = par4 + par2Random.nextInt(16) + 8; - worldgenvines.generate(par1World, par2Random, l, b0, i1); - } - } + @Override + public WorldGenAbstractTree func_150567_a(Random par1Random) { + return par1Random.nextInt(10) == 0 ? this.worldGeneratorBigTree : (par1Random.nextInt(2) == 0 ? new WorldGenMegaJungle(false, 10, 20, 3, 3) : new WorldGenTrees(false, + 4 + par1Random.nextInt(7), 3, 3, true)); + } } diff --git a/common/MysticWorld/Biome/BiomeGenMountain.java b/common/MysticWorld/Biome/BiomeGenMountain.java deleted file mode 100644 index 0b97b09..0000000 --- a/common/MysticWorld/Biome/BiomeGenMountain.java +++ /dev/null @@ -1,23 +0,0 @@ -package mysticworld.biome; - -import java.util.Random; - -import net.minecraft.block.Block; -import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.monster.EntityGhast; -import net.minecraft.entity.monster.EntityGiantZombie; -import net.minecraft.world.World; -import net.minecraft.world.biome.BiomeGenBase; -import net.minecraft.world.biome.SpawnListEntry; -import net.minecraft.world.gen.feature.WorldGenerator; - -public class BiomeGenMountain extends BiomeGenBase { - - public BiomeGenMountain(int id, int blockTop, int blockFiller) - { - super(id); - this.topBlock = (byte) blockTop; - this.fillerBlock = (byte) blockFiller; - } -} - diff --git a/common/MysticWorld/Biome/BiomeGenTundra.java b/common/MysticWorld/Biome/BiomeGenTundra.java index c25326a..4a0fc0e 100644 --- a/common/MysticWorld/Biome/BiomeGenTundra.java +++ b/common/MysticWorld/Biome/BiomeGenTundra.java @@ -1,28 +1,13 @@ package mysticworld.biome; -import java.util.Random; +import net.minecraft.block.Block; -import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.monster.EntityGhast; -import net.minecraft.entity.monster.EntityGiantZombie; -import net.minecraft.world.biome.BiomeGenBase; -import net.minecraft.world.biome.SpawnListEntry; -import net.minecraft.world.gen.feature.WorldGenerator; - -public class BiomeGenTundra extends BiomeGenBase { - - public BiomeGenTundra(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, int blockTop, int blockFiller) { - super(id); - this.topBlock = (byte) blockTop; - this.fillerBlock = (byte) blockFiller; - this.theBiomeDecorator.treesPerChunk = treesChunk; - this.theBiomeDecorator.grassPerChunk = grassChunk; - this.theBiomeDecorator.flowersPerChunk = flowerChunk; - this.theBiomeDecorator.reedsPerChunk = reedsChunk;; +public class BiomeGenTundra extends BiomeGenBasic { + public BiomeGenTundra(int id, int treesChunk, int grassChunk, int flowerChunk, int reedsChunk, Block blockTop, Block blockFiller) { + super(id, treesChunk, grassChunk, flowerChunk, reedsChunk, blockTop, blockFiller); this.spawnableCreatureList.clear(); this.spawnableMonsterList.clear(); this.spawnableWaterCreatureList.clear(); - this.spawnableCreatureList.add(new SpawnListEntry(net.minecraft.entity.passive.EntityWolf.class, 5, 4, 4)); - } + this.spawnableCreatureList.add(new SpawnListEntry(net.minecraft.entity.passive.EntityWolf.class, 5, 4, 4)); + } } - diff --git a/common/MysticWorld/Biome/BiomeHandler.java b/common/MysticWorld/Biome/BiomeHandler.java index 9f245d7..f5d2b78 100644 --- a/common/MysticWorld/Biome/BiomeHandler.java +++ b/common/MysticWorld/Biome/BiomeHandler.java @@ -1,10 +1,9 @@ package mysticworld.biome; import mysticworld.lib.Booleans; -import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.world.biome.BiomeGenBase; import net.minecraftforge.common.BiomeManager; -import cpw.mods.fml.common.registry.GameRegistry; public class BiomeHandler { public static BiomeGenBase Mountain; @@ -13,49 +12,33 @@ public class BiomeHandler { public static BiomeGenBase Glacier; public static BiomeGenBase Jungle; - public static void init() { - initializeBiomes(); - registerBiomes(); - } - - public static void initializeBiomes() { - Mountain = new BiomeGenMountain(23, Block.stone.blockID, Block.stone.blockID).setColor(9286496).setBiomeName("Mountain").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) - .setMinMaxHeight(0.5F, 1.0F); - Tundra = new BiomeGenTundra(24, 0, 0, 0, 0, Block.blockSnow.blockID, Block.blockSnow.blockID).setColor(9286496).setBiomeName("Tundra").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) - .setMinMaxHeight(0.8F, 0.4F); - Steppe = new BiomeGenBasic(25, 0, 2, 2, 3, Block.grass.blockID, Block.dirt.blockID).setColor(5470985).setBiomeName("Steppe").setMinMaxHeight(0.1F, 0.1F); - Glacier = new BiomeGenGlacier(26, 0, 0, 0, 0, Block.ice.blockID, Block.ice.blockID).setColor(9474208).setBiomeName("Glacier").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) - .setMinMaxHeight(0.5F, 0.7F); - Jungle = new BiomeGenJungle(27).setColor(5470985).setBiomeName("Jungle").func_76733_a(5470985).setTemperatureRainfall(1.2F, 0.9F).setMinMaxHeight(0.2F, 0.4F); - ; - } - - public static void registerBiomes() { + public static void init(){ if (Booleans.ENABLE_JUNGLE_REWRITE) { - GameRegistry.removeBiome(BiomeGenBase.jungle); - GameRegistry.removeBiome(BiomeGenBase.jungleHills); - GameRegistry.addBiome(Jungle); + Jungle = new BiomeGenJungle(21).setColor(5470985).setBiomeName("Jungle").func_76733_a(5470985).setTemperatureRainfall(1.2F, 0.9F).setHeight(new BiomeGenBase.Height(0.2F, 0.4F)); BiomeManager.addSpawnBiome(Jungle); BiomeManager.addStrongholdBiome(Jungle); } - if (Booleans.ENABLE_GLACIER_GEN) { - GameRegistry.addBiome(Glacier); - BiomeManager.addStrongholdBiome(Glacier); - } if (Booleans.ENABLE_MOUNTAIN_GEN) { - GameRegistry.addBiome(Mountain); + Mountain = new BiomeGenBasic(53, Blocks.stone, Blocks.stone).setColor(9286496).setBiomeName("Mountain").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) + .setHeight(new BiomeGenBase.Height(0.5F, 1.0F)); BiomeManager.addSpawnBiome(Mountain); BiomeManager.addStrongholdBiome(Mountain); } if (Booleans.ENABLE_TUNDRA_GEN) { - GameRegistry.addBiome(Tundra); + Tundra = new BiomeGenTundra(54, 0, 0, 0, 0, Blocks.snow, Blocks.snow).setColor(9286496).setBiomeName("Tundra").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) + .setHeight(new BiomeGenBase.Height(0.8F, 0.4F)); BiomeManager.addStrongholdBiome(Tundra); } if (Booleans.ENABLE_STEPPE_GEN) { - GameRegistry.addBiome(Steppe); + Steppe = new BiomeGenBasic(55, 0, 2, 2, 3, Blocks.grass, Blocks.dirt).setColor(5470985).setBiomeName("Steppe").setHeight(new BiomeGenBase.Height(0.1F, 0.1F)); BiomeManager.addSpawnBiome(Steppe); BiomeManager.addVillageBiome(Steppe, true); BiomeManager.addStrongholdBiome(Steppe); } + if (Booleans.ENABLE_GLACIER_GEN) { + Glacier = new BiomeGenGlacier(56, 0, 0, 0, 0, Blocks.ice, Blocks.ice).setColor(9474208).setBiomeName("Glacier").setEnableSnow().setTemperatureRainfall(0.05F, 0.8F) + .setHeight(new BiomeGenBase.Height(0.5F, 0.7F)); + BiomeManager.addStrongholdBiome(Glacier); + } } } diff --git a/common/MysticWorld/Blocks/BlockBush.java b/common/MysticWorld/Blocks/BlockBush.java deleted file mode 100644 index 6762982..0000000 --- a/common/MysticWorld/Blocks/BlockBush.java +++ /dev/null @@ -1,170 +0,0 @@ -package mysticworld.blocks; - -import java.util.List; -import java.util.Random; - -import mysticworld.MysticWorld; -import mysticworld.items.ItemHandler; -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.player.EntityPlayer; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.world.ColorizerFoliage; -import net.minecraft.world.ColorizerGrass; -import net.minecraft.world.IBlockAccess; -import net.minecraft.world.World; -import net.minecraftforge.common.EnumPlantType; -import net.minecraftforge.common.ForgeDirection; -import net.minecraftforge.common.IPlantable; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class BlockBush extends Block implements IPlantable { - Icon[] textures; - - public BlockBush(int id) { - super(id, Material.leaves); - setCreativeTab(MysticWorld.MysticWorldTab); - setHardness(0.3F); - setResistance(0.1F); - setStepSound(Block.soundGrassFootstep); - setBlockBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.5F, 0.75F); - } - - @Override - public boolean canBlockStay(World par1World, int par2, int par3, int par4) { - Block soil = blocksList[par1World.getBlockId(par2, par3 - 1, par4)]; - return (par1World.getFullBlockLightValue(par2, par3, par4) >= 8 || par1World.canBlockSeeTheSky(par2, par3, par4)) - && (soil != null && soil.canSustainPlant(par1World, par2, par3 - 1, par4, ForgeDirection.UP, this)); - } - - //Plant Specific Stuff - @Override - public boolean canPlaceBlockAt(World par1World, int par2, int par3, int par4) { - return super.canPlaceBlockAt(par1World, par2, par3, par4) && canBlockStay(par1World, par2, par3, par4); - } - - @Override - @SideOnly(Side.CLIENT) - public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4) { - int l = par1IBlockAccess.getBlockMetadata(par2, par3, par4); - return l == -1 ? 16777215 : par1IBlockAccess.getBiomeGenForCoords(par2, par4).getBiomeGrassColor(); - } - - @Override - public int damageDropped(int j) { - return j; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBlockColor() { - double d0 = 0.5D; - double d1 = 1.0D; - return ColorizerGrass.getGrassColor(d0, d1); - } - - @Override - public int getDamageValue(World par1World, int par2, int par3, int par4) { - return par1World.getBlockMetadata(par2, par3, par4); - } - - //Sprite Inits - @Override - public Icon getIcon(int side, int meta) { - return textures[meta]; - } - - @Override - public int getPlantID(World world, int x, int y, int z) { - return 0; - } - - @Override - public int getPlantMetadata(World world, int x, int y, int z) { - return 0; - } - - @Override - public EnumPlantType getPlantType(World world, int x, int y, int z) { - return EnumPlantType.Plains; - } - - @Override - @SideOnly(Side.CLIENT) - public int getRenderColor(int par1) { - return par1 == -1 ? 16777215 : ColorizerFoliage.getFoliageColorBasic(); - } - - @Override - public void getSubBlocks(int i, CreativeTabs tab, List list) { - for (int j = 0; j < 12; j++) { - list.add(new ItemStack(i, 1, j)); - } - } - - @Override - public void harvestBlock(World par1World, EntityPlayer par2EntityPlayer, int par3, int par4, int par5, int par6) { - super.harvestBlock(par1World, par2EntityPlayer, par3, par4, par5, par6); - } - - @Override - public int idDropped(int par1, Random par2Random, int par3) { - return ItemHandler.bushFruit.itemID; - } - - @Override - public int idPicked(World par1World, int par2, int par3, int par4) { - return blockID; - } - - @Override - public boolean isOpaqueCube() { - return false; - } - - @Override - public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, int par5) { - super.onNeighborBlockChange(par1World, par2, par3, par4, par5); - this.checkBushChange(par1World, par2, par3, par4); - } - - //Meta Inits - @Override - public int quantityDroppedWithBonus(int par1, Random par2Random) { - return 1 + par2Random.nextInt(par1 * 2 + 1); - } - - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[16]; - for (int i = 0; i < 12; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemBush.BUSH_TYPES[i]); - } - } - - @Override - public boolean renderAsNormalBlock() { - return false; - } - - @Override - public void updateTick(World par1World, int par2, int par3, int par4, Random par5Random) { - this.checkBushChange(par1World, par2, par3, par4); - } - - protected boolean canThisPlantGrowOnThisBlockID(int par1) { - return par1 == Block.grass.blockID || par1 == Block.dirt.blockID; - } - - protected final void checkBushChange(World par1World, int par2, int par3, int par4) { - if (!this.canBlockStay(par1World, par2, par3, par4)) { - this.dropBlockAsItem(par1World, par2, par3, par4, par1World.getBlockMetadata(par2, par3, par4), 0); - par1World.setBlockToAir(par2, par3, par4); - } - } -} diff --git a/common/MysticWorld/Blocks/BlockHandler.java b/common/MysticWorld/Blocks/BlockHandler.java index cbc0abe..c1ec825 100644 --- a/common/MysticWorld/Blocks/BlockHandler.java +++ b/common/MysticWorld/Blocks/BlockHandler.java @@ -1,38 +1,25 @@ package mysticworld.blocks; -import mysticworld.lib.BlockIds; +import cpw.mods.fml.common.registry.GameRegistry; import mysticworld.lib.Strings; import net.minecraft.block.Block; -import cpw.mods.fml.common.registry.GameRegistry; + +import java.util.ArrayList; +import java.util.Arrays; public class BlockHandler { - public static Block oreImbuedStone; - public static Block bush; - public static Block lightCube; - public static Block pillarPlatform; - public static Block pillar; - public static Block pillarInsert; + public static final ArrayList IMBUED_STONE_TYPE = new ArrayList(Arrays.asList(Strings.IMBUED_STONE_NAME+"Fire", Strings.IMBUED_STONE_NAME+"Water", Strings.IMBUED_STONE_NAME+"Earth", Strings.IMBUED_STONE_NAME+"Air", Strings.IMBUED_STONE_NAME+"Energy")); + public static final ArrayList BUSH_TYPES = new ArrayList(Arrays.asList(Strings.BUSH_NAME, Strings.POISON_BUSH_NAME, Strings.WEAKNESS_BUSH_NAME, Strings.SLOWNESS_BUSH_NAME, Strings.HARMING_BUSH_NAME, + Strings.WITHER_BUSH_NAME, Strings.HEALTH_BUSH_NAME, Strings.SPEED_BUSH_NAME, Strings.FIRE_RESISTANCE_BUSH_NAME, Strings.REGEN_BUSH_NAME, Strings.NIGHT_VISION_BUSH_NAME, + Strings.INVISIBILITY_BUSH_NAME)); + public static Block oreImbuedStone, bush, lightCube, pillarPlatform, pillar, pillarInsert; public static void init() { - oreImbuedStone = new BlockImbuedStone(BlockIds.ORE_STONE_1).setUnlocalizedName(Strings.IMBUED_STONE_NAME); - bush = new BlockBush(BlockIds.BUSH).setUnlocalizedName(Strings.BUSH_NAME); - lightCube = new BlockLightCube(BlockIds.LIGHT_CUBE).setUnlocalizedName(Strings.LIGHT_CUBE_NAME); - pillarPlatform = new BlockPlatform(BlockIds.PLATFORM).setUnlocalizedName(Strings.PLATFORM_NAME); - pillar = new BlockPillar(BlockIds.PILLAR).setUnlocalizedName(Strings.PILLAR_NAME); - pillarInsert = new BlockPillarInsert(BlockIds.PILLAR_INSERT).setUnlocalizedName(Strings.PILLAR_INSERT_NAME); - registerBlocks(); - setBlockHarvestLevels(); - } - - private static void registerBlocks() { - GameRegistry.registerBlock(oreImbuedStone, ItemImbuedStone.class, Strings.IMBUED_STONE_NAME); - GameRegistry.registerBlock(bush, ItemBush.class, Strings.BUSH_NAME); - GameRegistry.registerBlock(lightCube, Strings.LIGHT_CUBE_NAME); - GameRegistry.registerBlock(pillarPlatform, Strings.PLATFORM_NAME); - GameRegistry.registerBlock(pillar, Strings.PILLAR_NAME); - GameRegistry.registerBlock(pillarInsert, Strings.PILLAR_INSERT_NAME); - } - - private static void setBlockHarvestLevels() { + oreImbuedStone = GameRegistry.registerBlock(new BlockImbuedStone().setBlockName(Strings.IMBUED_STONE_NAME), ItemBlockMulti.class, Strings.IMBUED_STONE_NAME, IMBUED_STONE_TYPE); + bush = GameRegistry.registerBlock(new BlockBushes().setBlockName(Strings.BUSH_NAME), ItemBlockMulti.class, Strings.BUSH_NAME, BUSH_TYPES); + lightCube = GameRegistry.registerBlock(new BlockLightCube().setBlockName(Strings.LIGHT_CUBE_NAME).setBlockTextureName("mysticworld:lightCube"), Strings.LIGHT_CUBE_NAME); + pillarPlatform = GameRegistry.registerBlock(new BlockPlatform().setBlockName(Strings.PLATFORM_NAME).setBlockTextureName("mysticworld:Platform"), Strings.PLATFORM_NAME); + pillar = GameRegistry.registerBlock(new BlockPillar().setBlockName(Strings.PILLAR_NAME).setBlockTextureName("mysticworld:Pillar"), Strings.PILLAR_NAME); + pillarInsert = GameRegistry.registerBlock(new BlockPillarInsert().setBlockName(Strings.PILLAR_INSERT_NAME), Strings.PILLAR_INSERT_NAME); } } diff --git a/common/MysticWorld/Blocks/BlockImbuedStone.java b/common/MysticWorld/Blocks/BlockImbuedStone.java index a47d591..03f32e5 100644 --- a/common/MysticWorld/Blocks/BlockImbuedStone.java +++ b/common/MysticWorld/Blocks/BlockImbuedStone.java @@ -1,36 +1,37 @@ package mysticworld.blocks; -import java.util.List; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; import mysticworld.items.ItemHandler; import net.minecraft.block.Block; import net.minecraft.block.BlockFence; import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; +import java.util.Random; public class BlockImbuedStone extends Block { - Icon[] textures; + IIcon[] textures; - public BlockImbuedStone(int ID) { - super(ID, Material.rock); - setHardness(0.5F); - setResistance(5F); + public BlockImbuedStone() { + super(Material.rock); + setHardness(0.5F); + setResistance(5F); setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.125F, 0.75F); - setLightValue(0.625f); + setBlockBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.125F, 0.75F); + setLightLevel(0.625f); } @Override public boolean canPlaceBlockAt(World par1World, int par2, int par3, int par4) { - return par1World.doesBlockHaveSolidTopSurface(par2, par3 - 1, par4); + return World.doesBlockHaveSolidTopSurface(par1World, par2, par3 - 1, par4); } @Override @@ -44,30 +45,22 @@ public class BlockImbuedStone extends Block { } @Override - public Icon getIcon(int side, int meta) { + @SideOnly(Side.CLIENT) + public IIcon getIcon(int side, int meta) { return textures[meta]; } @Override - public void getSubBlocks(int i, CreativeTabs tab, List list) { + @SideOnly(Side.CLIENT) + public void getSubBlocks(Item i, CreativeTabs tab, List list) { for (int j = 0; j < 5; j++) { list.add(new ItemStack(i, 1, j)); } } @Override - public int idDropped(int par1, Random par2Random, int par3) { - return ItemHandler.imbuedShard.itemID; - } - - @Override - public int idPicked(World par1World, int par2, int par3, int par4) { - return blockID; - } - - @Override - public boolean isOpaqueCube() { - return false; + public Item getItemDropped(int par1, Random par2Random, int par3) { + return ItemHandler.imbuedShard; } @Override @@ -76,9 +69,9 @@ public class BlockImbuedStone extends Block { } @Override - public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, int par5) { + public void onNeighborBlockChange(World par1World, int par2, int par3, int par4, Block par5) { boolean flag = false; - if (!par1World.doesBlockHaveSolidTopSurface(par2, par3 - 1, par4) && !BlockFence.isIdAFence(par1World.getBlockId(par2, par3 - 1, par4))) { + if (!World.doesBlockHaveSolidTopSurface(par1World, par2, par3 - 1, par4) && !BlockFence.func_149825_a(par1World.getBlock(par2, par3 - 1, par4))) { flag = true; } if (flag) { @@ -89,24 +82,24 @@ public class BlockImbuedStone extends Block { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - textures = new Icon[16]; + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[16]; for (int i = 0; i < 5; i++) { - textures[i] = iconRegister.registerIcon("MysticMods" + ":" + ItemImbuedStone.IMBUED_STONE_TYPE[i] + " Imbued Stone"); + textures[i] = iconRegister.registerIcon("mysticworld:" + BlockHandler.IMBUED_STONE_TYPE.get(i).substring(11) + " Imbued Stone"); } } - @Override - public boolean renderAsNormalBlock() { - return false; - } + @Override + public boolean renderAsNormalBlock(){ + return false; + } + + @Override + public boolean isOpaqueCube(){ + return false; + } public int xpDropAmount(int j) { return 5; } - - @Override - protected boolean canSilkHarvest() { - return true; - } } \ No newline at end of file diff --git a/common/MysticWorld/Blocks/BlockLightCube.java b/common/MysticWorld/Blocks/BlockLightCube.java index 87e1d8b..498dd65 100644 --- a/common/MysticWorld/Blocks/BlockLightCube.java +++ b/common/MysticWorld/Blocks/BlockLightCube.java @@ -1,52 +1,42 @@ package mysticworld.blocks; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; import net.minecraft.block.Block; import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.item.Item; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.Random; public class BlockLightCube extends Block { - public BlockLightCube(int id) { - super(id, Material.circuits); - setBlockBounds(0.25F, 0.25F, 0.25F, 0.75F, 0.75F, 0.75F); - setLightValue(1.0F); - this.setTickRandomly(true); + public BlockLightCube() { + super(Material.circuits); + setBlockBounds(0.25F, 0.25F, 0.25F, 0.75F, 0.75F, 0.75F); + setLightLevel(1.0F); + setTickRandomly(true); } @Override - public int idDropped(int par1, Random par2Random, int par3) { - return 0; - } - - @Override - public boolean isOpaqueCube() { - return false; + public Item getItemDropped(int par1, Random par2Random, int par3) { + return null; } @Override + @SideOnly(Side.CLIENT) public void randomDisplayTick(World world, int x, int y, int z, Random random) { MysticWorld.proxy.lightCubeFX(world, x + random.nextDouble(), y + 0.75D, z + random.nextDouble(), 0.0D, 0.0D, 0.0D, 1.0F); MysticWorld.proxy.lightCubeFX(world, x + random.nextDouble(), y + 0.75D, z + random.nextDouble(), 0.0D, 0.0D, 0.0D, 1.0F); } - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - this.blockIcon = iconRegister.registerIcon("MysticMods" + ":" + "lightCube"); - } + @Override + public boolean renderAsNormalBlock(){ + return false; + } - @Override - public boolean renderAsNormalBlock() { - return false; - } - - @Override - protected boolean canSilkHarvest() { - return true; - } + @Override + public boolean isOpaqueCube(){ + return false; + } } diff --git a/common/MysticWorld/Blocks/BlockPillar.java b/common/MysticWorld/Blocks/BlockPillar.java index 0ac068d..52dcdff 100644 --- a/common/MysticWorld/Blocks/BlockPillar.java +++ b/common/MysticWorld/Blocks/BlockPillar.java @@ -3,32 +3,23 @@ package mysticworld.blocks; import mysticworld.MysticWorld; import net.minecraft.block.Block; import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; public class BlockPillar extends Block { - public BlockPillar(int id) { - super(id, Material.rock); - setBlockUnbreakable(); - setResistance(6000000.0F); + public BlockPillar() { + super(Material.rock); + setBlockUnbreakable(); + setResistance(6000000.0F); setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.15F, 0.0F, 0.15F, 0.85F, 1.0F, 0.85F); + setBlockBounds(0.15F, 0.0F, 0.15F, 0.85F, 1.0F, 0.85F); } - @Override - public boolean isOpaqueCube() { - return false; - } + @Override + public boolean isOpaqueCube(){ + return false; + } - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - this.blockIcon = iconRegister.registerIcon("MysticMods" + ":" + "Pillar"); - } - - @Override - public boolean renderAsNormalBlock() { - return false; - } + @Override + public boolean renderAsNormalBlock(){ + return false; + } } diff --git a/common/MysticWorld/Blocks/BlockPillarInsert.java b/common/MysticWorld/Blocks/BlockPillarInsert.java index 9fd0841..2d9ae2b 100644 --- a/common/MysticWorld/Blocks/BlockPillarInsert.java +++ b/common/MysticWorld/Blocks/BlockPillarInsert.java @@ -1,32 +1,41 @@ package mysticworld.blocks; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; import mysticworld.tiles.TileEntityPillarInsert; -import net.minecraft.block.BlockContainer; +import net.minecraft.block.Block; import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.Item; +import net.minecraft.init.Items; import net.minecraft.tileentity.TileEntity; import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; -public class BlockPillarInsert extends BlockContainer { +public class BlockPillarInsert extends Block { public static int RENDER_PILLAR_INSERT; - public BlockPillarInsert(int id) { - super(id, Material.rock); + public BlockPillarInsert() { + super(Material.rock); this.setBlockUnbreakable(); this.setResistance(6000000.0F); this.setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.125F, 0.0F, 0.125F, 0.875F, 1.0F, 0.875F); + setBlockBounds(0.125F, 0.0F, 0.125F, 0.875F, 1.0F, 0.875F); } + @Override + public boolean hasTileEntity(int i){ + return true; + } + @Override - public TileEntity createNewTileEntity(World world) { + public TileEntity createTileEntity(World world, int i) { return new TileEntityPillarInsert(); } @Override + @SideOnly(Side.CLIENT) public int getRenderBlockPass() { return 1; } @@ -36,27 +45,33 @@ public class BlockPillarInsert extends BlockContainer { return RENDER_PILLAR_INSERT; } - @Override - public boolean isOpaqueCube() { - return false; - } - @Override public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer entityPlayer, int par6, float par7, float par8, float par9) { if (!world.isRemote) { - if (Item.enderPearl.itemID == entityPlayer.inventory.getCurrentItem().itemID) { - TileEntity te = world.getBlockTileEntity(x, y, z); + if (Items.ender_pearl == entityPlayer.inventory.getCurrentItem().getItem()) { + TileEntity te = world.getTileEntity(x, y, z); } } return false; } @Override - public boolean renderAsNormalBlock() { - return false; + @SideOnly(Side.CLIENT) + public void registerBlockIcons(IIconRegister par1IconRegister) { } @Override + public boolean renderAsNormalBlock(){ + return false; + } + + @Override + public boolean isOpaqueCube(){ + return false; + } + + @Override + @SideOnly(Side.CLIENT) public boolean shouldSideBeRendered(IBlockAccess blockAccess, int x, int y, int z, int i) { return false; } diff --git a/common/MysticWorld/Blocks/BlockPillarPlatform.java b/common/MysticWorld/Blocks/BlockPillarPlatform.java index cac0fdb..875af74 100644 --- a/common/MysticWorld/Blocks/BlockPillarPlatform.java +++ b/common/MysticWorld/Blocks/BlockPillarPlatform.java @@ -1,26 +1,23 @@ package mysticworld.blocks; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.entity.Entity; import net.minecraft.world.World; +import java.util.Random; + public class BlockPillarPlatform extends Block { - public BlockPillarPlatform(int id) { - super(id, Material.rock); + public BlockPillarPlatform() { + super(Material.rock); this.setBlockUnbreakable(); this.setResistance(6000000.0F); this.setTickRandomly(true); setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.15F, 1.0F); - } - - @Override - public boolean isOpaqueCube() { - return false; + setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.15F, 1.0F); } @Override @@ -31,6 +28,7 @@ public class BlockPillarPlatform extends Block { } @Override + @SideOnly(Side.CLIENT) public void randomDisplayTick(World world, int x, int y, int z, Random rand) { double posX = x; double posY = y; @@ -40,10 +38,15 @@ public class BlockPillarPlatform extends Block { } } - @Override - public boolean renderAsNormalBlock() { - return false; - } + @Override + public boolean renderAsNormalBlock(){ + return false; + } + + @Override + public boolean isOpaqueCube(){ + return false; + } @Override public int tickRate(World par1World) { @@ -57,11 +60,11 @@ public class BlockPillarPlatform extends Block { } private boolean isTowersNearby(World world, int x, int y, int z) { - int block = BlockHandler.pillar.blockID; - if (world.getBlockId(x - 2, y, z - 2) == block && world.getBlockId(x - 2, y, z + 2) == block && world.getBlockId(x + 2, y, z + 2) == block && world.getBlockId(x + 2, y, z - 2) == block - && world.getBlockId(x - 2, y + 1, z - 2) == block && world.getBlockId(x - 2, y + 1, z + 2) == block && world.getBlockId(x + 2, y + 1, z + 2) == block - && world.getBlockId(x + 2, y + 1, z - 2) == block && world.getBlockId(x - 2, y + 2, z - 2) == block && world.getBlockId(x - 2, y + 2, z + 2) == block - && world.getBlockId(x + 2, y + 2, z + 2) == block && world.getBlockId(x + 2, y + 2, z - 2) == block) { + Block block = BlockHandler.pillar; + if (world.getBlock(x - 2, y, z - 2) == block && world.getBlock(x - 2, y, z + 2) == block && world.getBlock(x + 2, y, z + 2) == block && world.getBlock(x + 2, y, z - 2) == block + && world.getBlock(x - 2, y + 1, z - 2) == block && world.getBlock(x - 2, y + 1, z + 2) == block && world.getBlock(x + 2, y + 1, z + 2) == block + && world.getBlock(x + 2, y + 1, z - 2) == block && world.getBlock(x - 2, y + 2, z - 2) == block && world.getBlock(x - 2, y + 2, z + 2) == block + && world.getBlock(x + 2, y + 2, z + 2) == block && world.getBlock(x + 2, y + 2, z - 2) == block) { return true; } return false; diff --git a/common/MysticWorld/Blocks/BlockPillarTower.java b/common/MysticWorld/Blocks/BlockPillarTower.java index 08103ba..fe67465 100644 --- a/common/MysticWorld/Blocks/BlockPillarTower.java +++ b/common/MysticWorld/Blocks/BlockPillarTower.java @@ -5,21 +5,21 @@ import net.minecraft.block.Block; import net.minecraft.block.material.Material; public class BlockPillarTower extends Block { - public BlockPillarTower(int id) { - super(id, Material.rock); - setBlockUnbreakable(); - setResistance(6000000.0F); - setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.15F, 0.0F, 0.15F, 0.85F, 1.0F, 0.85F); + public BlockPillarTower() { + super(Material.rock); + setBlockUnbreakable(); + setResistance(6000000.0F); + setCreativeTab(MysticWorld.MysticWorldTab); + setBlockBounds(0.15F, 0.0F, 0.15F, 0.85F, 1.0F, 0.85F); } - @Override - public boolean isOpaqueCube() { - return false; - } + @Override + public boolean isOpaqueCube(){ + return false; + } - @Override - public boolean renderAsNormalBlock() { - return false; - } + @Override + public boolean renderAsNormalBlock(){ + return false; + } } diff --git a/common/MysticWorld/Blocks/BlockPlatform.java b/common/MysticWorld/Blocks/BlockPlatform.java index dcebb63..3595409 100644 --- a/common/MysticWorld/Blocks/BlockPlatform.java +++ b/common/MysticWorld/Blocks/BlockPlatform.java @@ -1,39 +1,37 @@ package mysticworld.blocks; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; import net.minecraft.block.Block; import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.entity.Entity; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.Random; public class BlockPlatform extends Block { - public BlockPlatform(int id) { - super(id, Material.rock); - this.setBlockUnbreakable(); - this.setResistance(6000000.0F); - this.setTickRandomly(true); + public BlockPlatform() { + super(Material.rock); + setBlockUnbreakable(); + setResistance(6000000.0F); + setTickRandomly(true); setCreativeTab(MysticWorld.MysticWorldTab); - setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.15F, 1.0F); + setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.15F, 1.0F); } - @Override - public boolean isOpaqueCube() { - return false; - } - - @Override - public void onEntityWalking(World world, int x, int y, int z, Entity entity) { - super.onEntityWalking(world, x, y, z, entity); - } + @Override + public boolean isOpaqueCube(){ + return false; + } + + @Override + public boolean renderAsNormalBlock(){ + return false; + } @Override + @SideOnly(Side.CLIENT) public void randomDisplayTick(World world, int x, int y, int z, Random rand) { - int block = BlockHandler.pillar.blockID; double posX = x; double posY = y; double posZ = z; @@ -48,17 +46,6 @@ public class BlockPlatform extends Block { } } - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - this.blockIcon = iconRegister.registerIcon("MysticMods" + ":" + "Platform"); - } - - @Override - public boolean renderAsNormalBlock() { - return false; - } - @Override public int tickRate(World par1World) { return 30; @@ -69,12 +56,12 @@ public class BlockPlatform extends Block { } private boolean isTowersNearby(World world, int x, int y, int z) { - int pillar = BlockHandler.pillar.blockID; - int insert = BlockHandler.pillarInsert.blockID; - if (world.getBlockId(x - 2, y, z - 2) == pillar && world.getBlockId(x - 2, y, z + 2) == pillar && world.getBlockId(x + 2, y, z + 2) == pillar && world.getBlockId(x + 2, y, z - 2) == pillar - && world.getBlockId(x - 2, y + 1, z - 2) == insert && world.getBlockId(x - 2, y + 1, z + 2) == insert && world.getBlockId(x + 2, y + 1, z + 2) == insert - && world.getBlockId(x + 2, y + 1, z - 2) == insert && world.getBlockId(x - 2, y + 2, z - 2) == pillar && world.getBlockId(x - 2, y + 2, z + 2) == pillar - && world.getBlockId(x + 2, y + 2, z + 2) == pillar && world.getBlockId(x + 2, y + 2, z - 2) == pillar) { + Block pillar = BlockHandler.pillar; + Block insert = BlockHandler.pillarInsert; + if (world.getBlock(x - 2, y, z - 2) == pillar && world.getBlock(x - 2, y, z + 2) == pillar && world.getBlock(x + 2, y, z + 2) == pillar && world.getBlock(x + 2, y, z - 2) == pillar + && world.getBlock(x - 2, y + 1, z - 2) == insert && world.getBlock(x - 2, y + 1, z + 2) == insert && world.getBlock(x + 2, y + 1, z + 2) == insert + && world.getBlock(x + 2, y + 1, z - 2) == insert && world.getBlock(x - 2, y + 2, z - 2) == pillar && world.getBlock(x - 2, y + 2, z + 2) == pillar + && world.getBlock(x + 2, y + 2, z + 2) == pillar && world.getBlock(x + 2, y + 2, z - 2) == pillar) { return true; } return false; diff --git a/common/MysticWorld/Blocks/ItemBush.java b/common/MysticWorld/Blocks/ItemBush.java deleted file mode 100644 index c7118e2..0000000 --- a/common/MysticWorld/Blocks/ItemBush.java +++ /dev/null @@ -1,38 +0,0 @@ -package mysticworld.blocks; - -import mysticworld.lib.Strings; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class ItemBush extends ItemBlock { - public static String[] BUSH_TYPES = new String[] { Strings.BUSH_NAME, Strings.POISON_BUSH_NAME, Strings.WEAKNESS_BUSH_NAME, Strings.SLOWNESS_BUSH_NAME, Strings.HARMING_BUSH_NAME, - Strings.WITHER_BUSH_NAME, Strings.HEALTH_BUSH_NAME, Strings.SPEED_BUSH_NAME, Strings.FIRE_RESISTANCE_BUSH_NAME, Strings.REGEN_BUSH_NAME, Strings.NIGHT_VISION_BUSH_NAME, - Strings.INVISIBILITY_BUSH_NAME }; - - public ItemBush(int par1) { - super(par1); - setMaxDamage(0); - setHasSubtypes(true); - } - - @Override - @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int par1) { - return BlockHandler.bush.getIcon(2, par1); - } - - @Override - public int getMetadata(int par1) { - return par1; - } - - @Override - public String getUnlocalizedName(ItemStack itemStack) { - int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, BUSH_TYPES.length); - return BUSH_TYPES[meta]; - } -} diff --git a/common/MysticWorld/Blocks/ItemImbuedStone.java b/common/MysticWorld/Blocks/ItemImbuedStone.java deleted file mode 100644 index 7453aa1..0000000 --- a/common/MysticWorld/Blocks/ItemImbuedStone.java +++ /dev/null @@ -1,43 +0,0 @@ -package mysticworld.blocks; - -import java.util.List; - - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.util.MathHelper; - -public class ItemImbuedStone extends ItemBlock { - - public static String[] IMBUED_STONE_TYPE = new String[] {"Fire", "Water", "Earth", "Air", "Energy"}; - - public ItemImbuedStone(int par1) { - super(par1); - setMaxDamage(0); - setHasSubtypes(true); - } - - - @Override - public String getUnlocalizedName(ItemStack itemStack) { - int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, IMBUED_STONE_TYPE.length); - return super.getUnlocalizedName() + IMBUED_STONE_TYPE[meta]; - } - - - public int getMetadata(int par1) - { - return par1; - } - - @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int par1) - { - return BlockHandler.oreImbuedStone.getIcon(2, par1); - } - -} diff --git a/common/MysticWorld/Client/ClientProxy.java b/common/MysticWorld/Client/ClientProxy.java index 9a8ff63..0622d39 100644 --- a/common/MysticWorld/Client/ClientProxy.java +++ b/common/MysticWorld/Client/ClientProxy.java @@ -1,70 +1,49 @@ package mysticworld.client; +import cpw.mods.fml.client.registry.ClientRegistry; +import cpw.mods.fml.client.registry.RenderingRegistry; +import mysticworld.CommonProxy; import mysticworld.blocks.BlockHandler; import mysticworld.blocks.BlockPillarInsert; import mysticworld.client.fx.LightCubeFX; import mysticworld.client.fx.PowerAirFX; -import mysticworld.client.fx.PowerEarthFX; -import mysticworld.client.fx.PowerEnergyFX; -import mysticworld.client.fx.PowerFireFX; -import mysticworld.client.fx.PowerWaterFX; -import mysticworld.entity.EntityChargeAir; -import mysticworld.entity.EntityChargeEarth; -import mysticworld.entity.EntityChargeEnergy; -import mysticworld.entity.EntityChargeFire; -import mysticworld.entity.EntityChargeWater; +import mysticworld.client.fx.PowerFX; +import mysticworld.entity.*; import mysticworld.items.ItemHandler; -import mysticworld.renderer.BlockPillarInsertRenderer; -import mysticworld.renderer.ItemOrbAirRenderer; -import mysticworld.renderer.ItemOrbEarthRenderer; -import mysticworld.renderer.ItemOrbEnergyRenderer; -import mysticworld.renderer.ItemOrbFireRenderer; -import mysticworld.renderer.ItemOrbWaterRenderer; -import mysticworld.renderer.ItemStaffAirRenderer; -import mysticworld.renderer.ItemStaffEarthRenderer; -import mysticworld.renderer.ItemStaffEnergyRenderer; -import mysticworld.renderer.ItemStaffFireRenderer; -import mysticworld.renderer.ItemStaffWaterRenderer; -import mysticworld.renderer.RenderStaffPower; -import mysticworld.renderer.TileEntityPillarInsertRenderer; +import mysticworld.renderer.*; import mysticworld.tiles.TileEntityPillarInsert; -import mysticworld.util.CommonProxy; import net.minecraft.client.Minecraft; +import net.minecraft.item.Item; +import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; import net.minecraftforge.client.MinecraftForgeClient; -import cpw.mods.fml.client.registry.ClientRegistry; -import cpw.mods.fml.client.registry.RenderingRegistry; public class ClientProxy extends CommonProxy { public final Minecraft mc = Minecraft.getMinecraft(); - - @Override - public int addArmor(String armor) { - return RenderingRegistry.addNewArmourRendererPrefix(armor); - } + public static final ResourceLocation particle = new ResourceLocation("textures/particle/particles.png"); //particles @Override public void airFeetFX(World worldObj, double x, double y, double z, float scale, int age) { - PowerAirFX airFX = new PowerAirFX(worldObj, x, y, z, scale, age); + PowerFX airFX = new PowerAirFX(worldObj, x, y, z, scale, age); mc.effectRenderer.addEffect(airFX); } @Override public void earthFX(World worldObj, double x, double y, double z, float scale) { - PowerEarthFX earthFX = new PowerEarthFX(worldObj, x, y, z, scale); + PowerFX earthFX = new PowerFX(worldObj, x, y, z, scale).setTexture("earth"); mc.effectRenderer.addEffect(earthFX); } @Override public void energyFX(World worldObj, double x, double y, double z, float scale) { - PowerEnergyFX energyFX = new PowerEnergyFX(worldObj, x, y, z, scale); + PowerFX energyFX = new PowerFX(worldObj, x, y, z, scale).setTexture("energy"); mc.effectRenderer.addEffect(energyFX); } @Override public void fireFX(World worldObj, double x, double y, double z, float scale) { - PowerFireFX fireFX = new PowerFireFX(worldObj, x, y, z, scale); + PowerFX fireFX = new PowerFX(worldObj, x, y, z, scale).setTexture("fire"); mc.effectRenderer.addEffect(fireFX); } @@ -77,28 +56,28 @@ public class ClientProxy extends CommonProxy { @Override public void registerRenders() { BlockPillarInsert.RENDER_PILLAR_INSERT = RenderingRegistry.getNextAvailableRenderId(); - MinecraftForgeClient.registerItemRenderer(BlockHandler.pillarInsert.blockID, new BlockPillarInsertRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.fireStaff.itemID, new ItemStaffFireRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.earthStaff.itemID, new ItemStaffEarthRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.airStaff.itemID, new ItemStaffAirRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.energyStaff.itemID, new ItemStaffEnergyRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.waterStaff.itemID, new ItemStaffWaterRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.fireOrb.itemID, new ItemOrbFireRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.earthOrb.itemID, new ItemOrbEarthRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.airOrb.itemID, new ItemOrbAirRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.energyOrb.itemID, new ItemOrbEnergyRenderer()); - MinecraftForgeClient.registerItemRenderer(ItemHandler.waterOrb.itemID, new ItemOrbWaterRenderer()); - RenderingRegistry.registerEntityRenderingHandler(EntityChargeFire.class, new RenderStaffPower(0)); - RenderingRegistry.registerEntityRenderingHandler(EntityChargeWater.class, new RenderStaffPower(1)); - RenderingRegistry.registerEntityRenderingHandler(EntityChargeEarth.class, new RenderStaffPower(2)); - RenderingRegistry.registerEntityRenderingHandler(EntityChargeAir.class, new RenderStaffPower(3)); - RenderingRegistry.registerEntityRenderingHandler(EntityChargeEnergy.class, new RenderStaffPower(4)); + MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(BlockHandler.pillarInsert), new BlockPillarInsertRenderer()); + MinecraftForgeClient.registerItemRenderer(ItemHandler.fireStaff, new StaffItemRenderer("Fire")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.waterStaff, new StaffItemRenderer("Water")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.earthStaff, new StaffItemRenderer("Earth")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.airStaff, new StaffItemRenderer("Air")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.energyStaff, new StaffItemRenderer("Energy")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.fireOrb, new OrbItemRenderer("Fire")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.waterOrb, new OrbItemRenderer("Water")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.earthOrb, new OrbItemRenderer("Earth")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.airOrb, new OrbItemRenderer("Air")); + MinecraftForgeClient.registerItemRenderer(ItemHandler.energyOrb, new OrbItemRenderer("Energy")); + RenderingRegistry.registerEntityRenderingHandler(EntityChargeFire.class, new RenderStaffPower("Fire")); + RenderingRegistry.registerEntityRenderingHandler(EntityChargeWater.class, new RenderStaffPower("Water")); + RenderingRegistry.registerEntityRenderingHandler(EntityChargeEarth.class, new RenderStaffPower("Earth")); + RenderingRegistry.registerEntityRenderingHandler(EntityChargeAir.class, new RenderStaffPower("Air")); + RenderingRegistry.registerEntityRenderingHandler(EntityChargeEnergy.class, new RenderStaffPower("Energy")); ClientRegistry.bindTileEntitySpecialRenderer(TileEntityPillarInsert.class, new TileEntityPillarInsertRenderer()); } @Override public void waterFX(World worldObj, double x, double y, double z, float scale) { - PowerWaterFX waterFX = new PowerWaterFX(worldObj, x, y, z, scale); + PowerFX waterFX = new PowerFX(worldObj, x, y, z, scale).setTexture("water"); mc.effectRenderer.addEffect(waterFX); } } diff --git a/common/MysticWorld/Client/FX/LightCubeFX.java b/common/MysticWorld/Client/FX/LightCubeFX.java index 27afd94..2dae6ee 100644 --- a/common/MysticWorld/Client/FX/LightCubeFX.java +++ b/common/MysticWorld/Client/FX/LightCubeFX.java @@ -1,21 +1,15 @@ package mysticworld.client.fx; -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class LightCubeFX extends EntityFX { +public class LightCubeFX extends PowerFX { public LightCubeFX(World world, double x, double y, double z) { super(world, x, y, z); + this.setTexture("lightCube"); } public LightCubeFX(World world, double x, double y, double z, double motionX, double motionY, double motionZ, float scale) { - super(world, x, y, z); + this(world, x, y, z); this.motionX *= 0.10000000149011612D; this.motionY *= 0.10000000149011612D; this.motionZ *= 0.10000000149011612D; @@ -29,55 +23,4 @@ public class LightCubeFX extends EntityFX { this.noClip = true; this.particleMaxAge = rand.nextInt(25); } - - @Override - public void onUpdate() { - this.prevPosX = this.posX; - this.prevPosY = this.posY; - this.prevPosZ = this.posZ; - if (this.particleAge++ >= this.particleMaxAge) { - this.setDead(); - } - this.motionY += 0.004D; - this.moveEntity(this.motionX, this.motionY, this.motionZ); - if (this.posY == this.prevPosY) { - this.motionX *= 1.1D; - this.motionZ *= 1.1D; - } - this.motionX *= 0.9599999785423279D; - this.motionY *= 0.9599999785423279D; - this.motionZ *= 0.9599999785423279D; - if (this.onGround) { - this.motionX *= 0.699999988079071D; - this.motionZ *= 0.699999988079071D; - } - } - - @Override - public void renderParticle(Tessellator tessellator, float par2, float par3, float par4, float par5, float par6, float par7) { - tessellator.draw(); - GL11.glPushMatrix(); - GL11.glDepthMask(false); - GL11.glEnable(3042); - GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/lightCubeFX.png")); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); - float scale = 0.1F * this.particleScale; - float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); - float yPos = (float) (this.prevPosY + (this.posY - this.prevPosY) * par2 - interpPosY); - float zPos = (float) (this.prevPosZ + (this.posZ - this.prevPosZ) * par2 - interpPosZ); - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - tessellator.setColorOpaque_F(this.particleRed, this.particleGreen, this.particleBlue); - tessellator.addVertexWithUV(xPos - par3 * scale - par6 * scale, yPos - par4 * scale, zPos - par5 * scale - par7 * scale, 0D, 1D); - tessellator.addVertexWithUV(xPos - par3 * scale + par6 * scale, yPos + par4 * scale, zPos - par5 * scale + par7 * scale, 1D, 1D); - tessellator.addVertexWithUV(xPos + par3 * scale + par6 * scale, yPos + par4 * scale, zPos + par5 * scale + par7 * scale, 1D, 0D); - tessellator.addVertexWithUV(xPos + par3 * scale - par6 * scale, yPos - par4 * scale, zPos + par5 * scale - par7 * scale, 0D, 0D); - tessellator.draw(); - GL11.glDisable(3042); - GL11.glDepthMask(true); - GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); - tessellator.startDrawingQuads(); - } } diff --git a/common/MysticWorld/Client/FX/PowerAirFX.java b/common/MysticWorld/Client/FX/PowerAirFX.java index 392f391..1d3ffaa 100644 --- a/common/MysticWorld/Client/FX/PowerAirFX.java +++ b/common/MysticWorld/Client/FX/PowerAirFX.java @@ -1,22 +1,16 @@ package mysticworld.client.fx; -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; import net.minecraft.util.MathHelper; -import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class PowerAirFX extends EntityFX { +public class PowerAirFX extends PowerFX { public PowerAirFX(World world, double x, double y, double z) { super(world, x, y, z); + this.setTexture("air"); } public PowerAirFX(World world, double x, double y, double z, double motionX, double motionY, double motionZ, float rotPitch, float rotYaw) { - super(world, x, y, z); + this(world, x, y, z); this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); @@ -31,7 +25,7 @@ public class PowerAirFX extends EntityFX { } public PowerAirFX(World world, double x, double y, double z, float scale, int age) { - super(world, x, y, z); + this(world, x, y, z); this.motionX += motionX; this.motionY += motionY; this.motionZ += motionZ; @@ -48,56 +42,10 @@ public class PowerAirFX extends EntityFX { @Override public void onUpdate() { - this.prevPosX = this.posX; - this.prevPosY = this.posY; - this.prevPosZ = this.posZ; - if (this.particleAge++ >= this.particleMaxAge) { - this.setDead(); - } - this.motionY += 0.004D; - this.moveEntity(this.motionX, this.motionY, this.motionZ); - if (this.posY == this.prevPosY) { - this.motionX *= 1.1D; - this.motionZ *= 1.1D; - } - this.motionX *= 0.9599999785423279D; - this.motionY *= 0.9599999785423279D; - this.motionZ *= 0.9599999785423279D; - if (this.onGround) { - this.motionX *= 0.699999988079071D; - this.motionZ *= 0.699999988079071D; - } + super.onUpdate(); this.posX += this.motionX; this.posY += this.motionY; this.posZ += this.motionZ; this.setPosition(this.posX, this.posY, this.posZ); } - - @Override - public void renderParticle(Tessellator tessellator, float par2, float par3, float par4, float par5, float par6, float par7) { - tessellator.draw(); - GL11.glPushMatrix(); - GL11.glDepthMask(false); - GL11.glEnable(3042); - GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/airFX.png")); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); - float scale = 0.1F * this.particleScale; - float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); - float yPos = (float) (this.prevPosY + (this.posY - this.prevPosY) * par2 - interpPosY); - float zPos = (float) (this.prevPosZ + (this.posZ - this.prevPosZ) * par2 - interpPosZ); - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - tessellator.setColorOpaque_F(this.particleRed, this.particleGreen, this.particleBlue); - tessellator.addVertexWithUV(xPos - par3 * scale - par6 * scale, yPos - par4 * scale, zPos - par5 * scale - par7 * scale, 0D, 1D); - tessellator.addVertexWithUV(xPos - par3 * scale + par6 * scale, yPos + par4 * scale, zPos - par5 * scale + par7 * scale, 1D, 1D); - tessellator.addVertexWithUV(xPos + par3 * scale + par6 * scale, yPos + par4 * scale, zPos + par5 * scale + par7 * scale, 1D, 0D); - tessellator.addVertexWithUV(xPos + par3 * scale - par6 * scale, yPos - par4 * scale, zPos + par5 * scale - par7 * scale, 0D, 0D); - tessellator.draw(); - GL11.glDisable(3042); - GL11.glDepthMask(true); - GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); - tessellator.startDrawingQuads(); - } } \ No newline at end of file diff --git a/common/MysticWorld/Client/FX/PowerEarthFX.java b/common/MysticWorld/Client/FX/PowerEarthFX.java deleted file mode 100644 index c319c31..0000000 --- a/common/MysticWorld/Client/FX/PowerEarthFX.java +++ /dev/null @@ -1,83 +0,0 @@ -package mysticworld.client.fx; - -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import net.minecraft.world.World; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class PowerEarthFX extends EntityFX { - public PowerEarthFX(World world, double x, double y, double z) { - super(world, x, y, z); - } - - public PowerEarthFX(World world, double x, double y, double z, float scale) { - super(world, x, y, z); - this.motionX *= 0.019999999552965164D; - this.motionY *= 0.019999999552965164D; - this.motionZ *= 0.019999999552965164D; - this.motionX += motionX; - this.motionY += motionY; - this.motionZ += motionZ; - this.particleRed = 1.0F; - this.particleGreen = 1.0F; - this.particleBlue = 1.0F; - this.particleScale = scale; - this.noClip = true; - this.particleMaxAge = 15; - } - - @Override - public void onUpdate() { - this.prevPosX = this.posX; - this.prevPosY = this.posY; - this.prevPosZ = this.posZ; - if (this.particleAge++ >= this.particleMaxAge) { - this.setDead(); - } - this.motionY += 0.004D; - this.moveEntity(this.motionX, this.motionY, this.motionZ); - if (this.posY == this.prevPosY) { - this.motionX *= 1.1D; - this.motionZ *= 1.1D; - } - this.motionX *= 0.9599999785423279D; - this.motionY *= 0.9599999785423279D; - this.motionZ *= 0.9599999785423279D; - if (this.onGround) { - this.motionX *= 0.699999988079071D; - this.motionZ *= 0.699999988079071D; - } - } - - @Override - public void renderParticle(Tessellator tessellator, float par2, float par3, float par4, float par5, float par6, float par7) { - tessellator.draw(); - GL11.glPushMatrix(); - GL11.glDepthMask(false); - GL11.glEnable(3042); - GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/earthFX.png")); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); - float scale = 0.1F * this.particleScale; - float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); - float yPos = (float) (this.prevPosY + (this.posY - this.prevPosY) * par2 - interpPosY); - float zPos = (float) (this.prevPosZ + (this.posZ - this.prevPosZ) * par2 - interpPosZ); - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - tessellator.setColorOpaque_F(this.particleRed, this.particleGreen, this.particleBlue); - tessellator.addVertexWithUV(xPos - par3 * scale - par6 * scale, yPos - par4 * scale, zPos - par5 * scale - par7 * scale, 0D, 1D); - tessellator.addVertexWithUV(xPos - par3 * scale + par6 * scale, yPos + par4 * scale, zPos - par5 * scale + par7 * scale, 1D, 1D); - tessellator.addVertexWithUV(xPos + par3 * scale + par6 * scale, yPos + par4 * scale, zPos + par5 * scale + par7 * scale, 1D, 0D); - tessellator.addVertexWithUV(xPos + par3 * scale - par6 * scale, yPos - par4 * scale, zPos + par5 * scale - par7 * scale, 0D, 0D); - tessellator.draw(); - GL11.glDisable(3042); - GL11.glDepthMask(true); - GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); - tessellator.startDrawingQuads(); - } -} diff --git a/common/MysticWorld/Client/FX/PowerFireFX.java b/common/MysticWorld/Client/FX/PowerFireFX.java deleted file mode 100644 index 1ebdb17..0000000 --- a/common/MysticWorld/Client/FX/PowerFireFX.java +++ /dev/null @@ -1,83 +0,0 @@ -package mysticworld.client.fx; - -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import net.minecraft.world.World; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class PowerFireFX extends EntityFX { - public PowerFireFX(World world, double x, double y, double z) { - super(world, x, y, z); - } - - public PowerFireFX(World world, double x, double y, double z, float scale) { - super(world, x, y, z); - this.motionX *= 0.019999999552965164D; - this.motionY *= 0.019999999552965164D; - this.motionZ *= 0.019999999552965164D; - this.motionX += motionX; - this.motionY += motionY; - this.motionZ += motionZ; - this.particleRed = 1.0F; - this.particleGreen = 1.0F; - this.particleBlue = 1.0F; - this.particleScale = scale; - this.noClip = true; - this.particleMaxAge = 15; - } - - @Override - public void onUpdate() { - this.prevPosX = this.posX; - this.prevPosY = this.posY; - this.prevPosZ = this.posZ; - if (this.particleAge++ >= this.particleMaxAge) { - this.setDead(); - } - this.motionY += 0.004D; - this.moveEntity(this.motionX, this.motionY, this.motionZ); - if (this.posY == this.prevPosY) { - this.motionX *= 1.1D; - this.motionZ *= 1.1D; - } - this.motionX *= 0.9599999785423279D; - this.motionY *= 0.9599999785423279D; - this.motionZ *= 0.9599999785423279D; - if (this.onGround) { - this.motionX *= 0.699999988079071D; - this.motionZ *= 0.699999988079071D; - } - } - - @Override - public void renderParticle(Tessellator tessellator, float par2, float par3, float par4, float par5, float par6, float par7) { - tessellator.draw(); - GL11.glPushMatrix(); - GL11.glDepthMask(false); - GL11.glEnable(3042); - GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/fireFX.png")); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); - float scale = 0.1F * this.particleScale; - float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); - float yPos = (float) (this.prevPosY + (this.posY - this.prevPosY) * par2 - interpPosY); - float zPos = (float) (this.prevPosZ + (this.posZ - this.prevPosZ) * par2 - interpPosZ); - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - tessellator.setColorOpaque_F(this.particleRed, this.particleGreen, this.particleBlue); - tessellator.addVertexWithUV(xPos - par3 * scale - par6 * scale, yPos - par4 * scale, zPos - par5 * scale - par7 * scale, 0D, 1D); - tessellator.addVertexWithUV(xPos - par3 * scale + par6 * scale, yPos + par4 * scale, zPos - par5 * scale + par7 * scale, 1D, 1D); - tessellator.addVertexWithUV(xPos + par3 * scale + par6 * scale, yPos + par4 * scale, zPos + par5 * scale + par7 * scale, 1D, 0D); - tessellator.addVertexWithUV(xPos + par3 * scale - par6 * scale, yPos - par4 * scale, zPos + par5 * scale - par7 * scale, 0D, 0D); - tessellator.draw(); - GL11.glDisable(3042); - GL11.glDepthMask(true); - GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); - tessellator.startDrawingQuads(); - } -} diff --git a/common/MysticWorld/Client/FX/PowerWaterFX.java b/common/MysticWorld/Client/FX/PowerWaterFX.java deleted file mode 100644 index a8917de..0000000 --- a/common/MysticWorld/Client/FX/PowerWaterFX.java +++ /dev/null @@ -1,83 +0,0 @@ -package mysticworld.client.fx; - -import net.minecraft.client.particle.EntityFX; -import net.minecraft.client.renderer.Tessellator; -import net.minecraft.util.ResourceLocation; -import net.minecraft.world.World; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class PowerWaterFX extends EntityFX { - public PowerWaterFX(World world, double x, double y, double z) { - super(world, x, y, z); - } - - public PowerWaterFX(World world, double x, double y, double z, float scale) { - super(world, x, y, z); - this.motionX *= 0.019999999552965164D; - this.motionY *= 0.019999999552965164D; - this.motionZ *= 0.019999999552965164D; - this.motionX += motionX; - this.motionY += motionY; - this.motionZ += motionZ; - this.particleRed = 1.0F; - this.particleGreen = 1.0F; - this.particleBlue = 1.0F; - this.particleScale = scale; - this.noClip = true; - this.particleMaxAge = 15; - } - - @Override - public void onUpdate() { - this.prevPosX = this.posX; - this.prevPosY = this.posY; - this.prevPosZ = this.posZ; - if (this.particleAge++ >= this.particleMaxAge) { - this.setDead(); - } - this.motionY += 0.004D; - this.moveEntity(this.motionX, this.motionY, this.motionZ); - if (this.posY == this.prevPosY) { - this.motionX *= 1.1D; - this.motionZ *= 1.1D; - } - this.motionX *= 0.9599999785423279D; - this.motionY *= 0.9599999785423279D; - this.motionZ *= 0.9599999785423279D; - if (this.onGround) { - this.motionX *= 0.699999988079071D; - this.motionZ *= 0.699999988079071D; - } - } - - @Override - public void renderParticle(Tessellator tessellator, float par2, float par3, float par4, float par5, float par6, float par7) { - tessellator.draw(); - GL11.glPushMatrix(); - GL11.glDepthMask(false); - GL11.glEnable(3042); - GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/waterFX.png")); - GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); - float scale = 0.1F * this.particleScale; - float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); - float yPos = (float) (this.prevPosY + (this.posY - this.prevPosY) * par2 - interpPosY); - float zPos = (float) (this.prevPosZ + (this.posZ - this.prevPosZ) * par2 - interpPosZ); - tessellator.startDrawingQuads(); - tessellator.setBrightness(240); - tessellator.setColorOpaque_F(this.particleRed, this.particleGreen, this.particleBlue); - tessellator.addVertexWithUV(xPos - par3 * scale - par6 * scale, yPos - par4 * scale, zPos - par5 * scale - par7 * scale, 0D, 1D); - tessellator.addVertexWithUV(xPos - par3 * scale + par6 * scale, yPos + par4 * scale, zPos - par5 * scale + par7 * scale, 1D, 1D); - tessellator.addVertexWithUV(xPos + par3 * scale + par6 * scale, yPos + par4 * scale, zPos + par5 * scale + par7 * scale, 1D, 0D); - tessellator.addVertexWithUV(xPos + par3 * scale - par6 * scale, yPos - par4 * scale, zPos + par5 * scale - par7 * scale, 0D, 0D); - tessellator.draw(); - GL11.glDisable(3042); - GL11.glDepthMask(true); - GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); - tessellator.startDrawingQuads(); - } -} diff --git a/common/MysticWorld/Entity/EntityChargeAir.java b/common/MysticWorld/Entity/EntityChargeAir.java index 4ee9183..5dc256b 100644 --- a/common/MysticWorld/Entity/EntityChargeAir.java +++ b/common/MysticWorld/Entity/EntityChargeAir.java @@ -1,29 +1,12 @@ package mysticworld.entity; -import java.util.List; -import java.util.Random; - import mysticworld.MysticWorld; -import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.MathHelper; import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -public class EntityChargeAir extends Entity { - public EntityPlayer shootingEntity; - private boolean inGround = false; - private int xTile = -1; - private int yTile = -1; - private int zTile = -1; - private int inTile = 0; - private int ticksAlive; - private int ticksInAir = 0; +public class EntityChargeAir extends EntityCharge { private float particleScale = 1.0f; private double powerHeight = 0.75D; @@ -32,110 +15,19 @@ public class EntityChargeAir extends Entity { } public EntityChargeAir(World par1World, EntityPlayer par2EntityPlayer, float pScale, double pHeight) { - super(par1World); - this.setSize(0.25F, 0.25F); - this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); - this.setPosition(this.posX, this.posY, this.posZ); - this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); - this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.shootingEntity = par2EntityPlayer; + super(par1World,par2EntityPlayer); this.particleScale = pScale; this.powerHeight = pHeight; } @Override - public boolean canBeCollidedWith() { - return true; - } - - @Override - public float getBrightness(float par1) { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBrightnessForRender(float par1) { - return 15728880; - } - - @Override - public float getCollisionBorderSize() { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public float getShadowSize() { - return 0.0F; - } - - @Override - public void onUpdate() { - if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { - this.setDead(); - } else { - super.onUpdate(); - Vec3 vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - Vec3 vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition movingobjectposition = this.worldObj.rayTraceBlocks_do_do(vec3, vec31, true, true); - vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (movingobjectposition != null) { - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); - } - Entity entity = null; - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); - double d0 = 0.0D; - for (int j = 0; j < list.size(); ++j) { - Entity entity1 = (Entity) list.get(j); - if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { - float f = 0.3F; - AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(f, f, f); - MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); - if (movingobjectposition1 != null) { - double d1 = vec3.distanceTo(movingobjectposition1.hitVec); - if (d1 < d0 || d0 == 0.0D) { - entity = entity1; - d0 = d1; - } - } - } - } - if (entity != null) { - movingobjectposition = new MovingObjectPosition(entity); - } - if (movingobjectposition != null) { - this.onImpact(movingobjectposition); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - float f2 = this.getMotionFactor(); - if (this.isInWater()) { - for (int k = 0; k < 4; ++k) { - float f3 = 0.25F; - this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); - } - f2 = 0.8F; - } - MysticWorld.proxy.airFeetFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), particleScale, 15); - MysticWorld.proxy.airFeetFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), particleScale, 15); - this.setPosition(this.posX, this.posY, this.posZ); - } - } - - @Override - protected void entityInit() { - } - - protected float getMotionFactor() { - return 0.95F; + public void chargeFX() { + MysticWorld.proxy.airFeetFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), particleScale, 15); + MysticWorld.proxy.airFeetFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), particleScale, 15); } + @Override protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { - Random rand = new Random(); if (!this.worldObj.isRemote) { this.worldObj.playSoundEffect(this.posX, this.posY, this.posZ, "random.explode", 4.0F, (1.0F + (this.worldObj.rand.nextFloat() - this.worldObj.rand.nextFloat()) * 0.2F) * 0.7F); if (par1MovingObjectPosition.entityHit != null) { @@ -143,7 +35,7 @@ public class EntityChargeAir extends Entity { if (f3 > 0.0F) { par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 2 * 0.6000000238418579D / f3, 1.0D + powerHeight, this.motionZ * 2 * 0.6000000238418579D / f3); } - } else { + } /*else { int i = par1MovingObjectPosition.blockX; int j = par1MovingObjectPosition.blockY; int k = par1MovingObjectPosition.blockZ; @@ -166,16 +58,8 @@ public class EntityChargeAir extends Entity { case 5: ++i; } - } + }*/ this.setDead(); } } - - @Override - protected void readEntityFromNBT(NBTTagCompound nbttagcompound) { - } - - @Override - protected void writeEntityToNBT(NBTTagCompound nbttagcompound) { - } } \ No newline at end of file diff --git a/common/MysticWorld/Entity/EntityChargeEarth.java b/common/MysticWorld/Entity/EntityChargeEarth.java index 3326ce3..720a1de 100644 --- a/common/MysticWorld/Entity/EntityChargeEarth.java +++ b/common/MysticWorld/Entity/EntityChargeEarth.java @@ -1,144 +1,33 @@ package mysticworld.entity; -import java.util.List; -import java.util.Random; - import mysticworld.MysticWorld; -import net.minecraft.block.Block; -import net.minecraft.entity.Entity; -import net.minecraft.entity.boss.EntityDragon; -import net.minecraft.entity.boss.EntityWither; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.Item; +import net.minecraft.init.Blocks; +import net.minecraft.init.Items; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.DamageSource; import net.minecraft.util.MathHelper; import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -public class EntityChargeEarth extends Entity { - public EntityPlayer shootingEntity; - public EntityPlayer entityPlayer; - public EntityDragon entityDragon; - public EntityWither entityWither; - private boolean inGround = false; - private int xTile = -1; - private int yTile = -1; - private int zTile = -1; - private int inTile = 0; - private int ticksAlive; - private int ticksInAir = 0; +import java.util.Random; +public class EntityChargeEarth extends EntityCharge { public EntityChargeEarth(World par1World) { super(par1World); } public EntityChargeEarth(World par1World, EntityPlayer par2EntityPlayer) { - super(par1World); - this.setSize(0.25F, 0.25F); - this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); - this.setPosition(this.posX, this.posY, this.posZ); - this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); - this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.shootingEntity = par2EntityPlayer; + super(par1World,par2EntityPlayer); } @Override - public boolean canBeCollidedWith() { - return true; - } - - @Override - public float getBrightness(float par1) { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBrightnessForRender(float par1) { - return 15728880; - } - - @Override - public float getCollisionBorderSize() { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public float getShadowSize() { - return 0.0F; - } - - @Override - public void onUpdate() { - if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { - this.setDead(); - } else { - super.onUpdate(); - Vec3 vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - Vec3 vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition movingobjectposition = this.worldObj.rayTraceBlocks_do_do(vec3, vec31, true, true); - vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (movingobjectposition != null) { - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); - } - Entity entity = null; - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); - double d0 = 0.0D; - for (int j = 0; j < list.size(); ++j) { - Entity entity1 = (Entity) list.get(j); - if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { - float f = 0.3F; - AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(f, f, f); - MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); - if (movingobjectposition1 != null) { - double d1 = vec3.distanceTo(movingobjectposition1.hitVec); - if (d1 < d0 || d0 == 0.0D) { - entity = entity1; - d0 = d1; - } - } - } - } - if (entity != null) { - movingobjectposition = new MovingObjectPosition(entity); - } - if (movingobjectposition != null) { - this.onImpact(movingobjectposition); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - float f2 = this.getMotionFactor(); - if (this.isInWater()) { - for (int k = 0; k < 4; ++k) { - float f3 = 0.25F; - this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); - } - f2 = 0.8F; - } - MysticWorld.proxy.earthFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); - this.setPosition(this.posX, this.posY, this.posZ); - } - } - - @Override - protected void entityInit() { - } - - protected float getMotionFactor() { - return 0.95F; + public void chargeFX() { + MysticWorld.proxy.earthFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); } + @Override protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { Random rand = new Random(); if (!this.worldObj.isRemote) { @@ -146,19 +35,19 @@ public class EntityChargeEarth extends Entity { if (par1MovingObjectPosition.entityHit != null) { double f3 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ); if (f3 > 0.0F) { - par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 1 * 0.6000000238418579D / f3, 0.1D, this.motionZ * 1 * 0.6000000238418579D / f3); + par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 0.6000000238418579D / f3, 0.1D, this.motionZ * 0.6000000238418579D / f3); } par1MovingObjectPosition.entityHit.attackEntityFrom(DamageSource.magic, 20); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Item.seeds, rand.nextInt(4)))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Block.mushroomBrown, rand.nextInt(2)))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Item.appleRed, rand.nextInt(2)))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Block.sapling, rand.nextInt(2), 0))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Item.pumpkinSeeds, rand.nextInt(2)))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Block.sapling, rand.nextInt(2), 1))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Block.sapling, rand.nextInt(2), 2))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Block.sapling, rand.nextInt(2), 3))); - this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Item.melonSeeds, rand.nextInt(3)))); - } else { + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Items.wheat_seeds, rand.nextInt(4)))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Blocks.brown_mushroom, rand.nextInt(2)))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Items.apple, rand.nextInt(2)))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Blocks.sapling, rand.nextInt(2), 0))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Items.pumpkin_seeds, rand.nextInt(2)))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Blocks.sapling, rand.nextInt(2), 1))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Blocks.sapling, rand.nextInt(2), 2))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Blocks.sapling, rand.nextInt(2), 3))); + this.worldObj.spawnEntityInWorld(new EntityItem(worldObj, this.posX, this.posY, this.posZ, new ItemStack(Items.melon_seeds, rand.nextInt(3)))); + }/* else { int i = par1MovingObjectPosition.blockX; int j = par1MovingObjectPosition.blockY; int k = par1MovingObjectPosition.blockZ; @@ -181,16 +70,8 @@ public class EntityChargeEarth extends Entity { case 5: ++i; } - } + }*/ this.setDead(); } } - - @Override - protected void readEntityFromNBT(NBTTagCompound nbttagcompound) { - } - - @Override - protected void writeEntityToNBT(NBTTagCompound nbttagcompound) { - } } diff --git a/common/MysticWorld/Entity/EntityChargeEnergy.java b/common/MysticWorld/Entity/EntityChargeEnergy.java index 20a5935..e6ba12c 100644 --- a/common/MysticWorld/Entity/EntityChargeEnergy.java +++ b/common/MysticWorld/Entity/EntityChargeEnergy.java @@ -1,134 +1,27 @@ package mysticworld.entity; -import java.util.List; - import mysticworld.MysticWorld; -import net.minecraft.entity.Entity; import net.minecraft.entity.effect.EntityLightningBolt; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.MathHelper; import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class EntityChargeEnergy extends Entity { - public EntityPlayer shootingEntity; - private boolean inGround = false; - private int xTile = -1; - private int yTile = -1; - private int zTile = -1; - private int inTile = 0; - private int ticksAlive; - private int ticksInAir = 0; +public class EntityChargeEnergy extends EntityCharge { public EntityChargeEnergy(World par1World) { super(par1World); } public EntityChargeEnergy(World par1World, EntityPlayer par2EntityPlayer) { - super(par1World); - this.setSize(0.25F, 0.25F); - this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); - this.setPosition(this.posX, this.posY, this.posZ); - this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); - this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.shootingEntity = par2EntityPlayer; + super(par1World,par2EntityPlayer); } @Override - public boolean canBeCollidedWith() { - return true; - } - - @Override - public float getBrightness(float par1) { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBrightnessForRender(float par1) { - return 15728880; - } - - @Override - public float getCollisionBorderSize() { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public float getShadowSize() { - return 0.0F; - } - - @Override - public void onUpdate() { - if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { - this.setDead(); - } else { - super.onUpdate(); - Vec3 vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - Vec3 vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition movingobjectposition = this.worldObj.rayTraceBlocks_do_do(vec3, vec31, true, true); - vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (movingobjectposition != null) { - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); - } - Entity entity = null; - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); - double d0 = 0.0D; - for (int j = 0; j < list.size(); ++j) { - Entity entity1 = (Entity) list.get(j); - if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { - float f = 0.3F; - AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(f, f, f); - MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); - if (movingobjectposition1 != null) { - double d1 = vec3.distanceTo(movingobjectposition1.hitVec); - if (d1 < d0 || d0 == 0.0D) { - entity = entity1; - d0 = d1; - } - } - } - } - if (entity != null) { - movingobjectposition = new MovingObjectPosition(entity); - } - if (movingobjectposition != null) { - this.onImpact(movingobjectposition); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - float f2 = this.getMotionFactor(); - if (this.isInWater()) { - for (int k = 0; k < 4; ++k) { - float f3 = 0.25F; - this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); - } - f2 = 0.8F; - } - MysticWorld.proxy.energyFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); - this.setPosition(this.posX, this.posY, this.posZ); - } - } - - @Override - protected void entityInit() { - } - - protected float getMotionFactor() { - return 0.95F; + public void chargeFX() { + MysticWorld.proxy.energyFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); } + @Override protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { int i = par1MovingObjectPosition.blockX; int j = par1MovingObjectPosition.blockY; @@ -142,7 +35,7 @@ public class EntityChargeEnergy extends Entity { worldObj.addWeatherEffect(new EntityLightningBolt(worldObj, par1MovingObjectPosition.entityHit.posX, par1MovingObjectPosition.entityHit.posY, par1MovingObjectPosition.entityHit.posZ)); } else { worldObj.addWeatherEffect(new EntityLightningBolt(worldObj, i, j, k)); - switch (par1MovingObjectPosition.sideHit) { + /*switch (par1MovingObjectPosition.sideHit) { case 0: --j; break; @@ -160,17 +53,9 @@ public class EntityChargeEnergy extends Entity { break; case 5: ++i; - } + }*/ } this.setDead(); } } - - @Override - protected void readEntityFromNBT(NBTTagCompound nbttagcompound) { - } - - @Override - protected void writeEntityToNBT(NBTTagCompound nbttagcompound) { - } } \ No newline at end of file diff --git a/common/MysticWorld/Entity/EntityChargeFire.java b/common/MysticWorld/Entity/EntityChargeFire.java index a58a2d1..1cd722a 100644 --- a/common/MysticWorld/Entity/EntityChargeFire.java +++ b/common/MysticWorld/Entity/EntityChargeFire.java @@ -1,142 +1,35 @@ package mysticworld.entity; -import java.util.List; - import mysticworld.MysticWorld; -import net.minecraft.block.Block; -import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.AxisAlignedBB; +import net.minecraft.init.Blocks; import net.minecraft.util.DamageSource; import net.minecraft.util.MathHelper; import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class EntityChargeFire extends Entity { - public EntityPlayer shootingEntity; - private boolean inGround = false; - private int xTile = -1; - private int yTile = -1; - private int zTile = -1; - private int inTile = 0; - private int ticksAlive; - private int ticksInAir = 0; +public class EntityChargeFire extends EntityCharge { public EntityChargeFire(World par1World) { super(par1World); } public EntityChargeFire(World par1World, EntityPlayer par2EntityPlayer) { - super(par1World); - this.setSize(0.25F, 0.25F); - this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); - this.setPosition(this.posX, this.posY, this.posZ); - this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); - this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.shootingEntity = par2EntityPlayer; + super(par1World,par2EntityPlayer); } @Override - public boolean canBeCollidedWith() { - return true; - } - - @Override - public float getBrightness(float par1) { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBrightnessForRender(float par1) { - return 15728880; - } - - @Override - public float getCollisionBorderSize() { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public float getShadowSize() { - return 0.0F; - } - - @Override - public void onUpdate() { - if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { - this.setDead(); - } else { - super.onUpdate(); - Vec3 vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - Vec3 vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition movingobjectposition = this.worldObj.rayTraceBlocks_do_do(vec3, vec31, true, true); - vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (movingobjectposition != null) { - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); - } - Entity entity = null; - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); - double d0 = 0.0D; - for (int j = 0; j < list.size(); ++j) { - Entity entity1 = (Entity) list.get(j); - if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { - float f = 0.3F; - AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(f, f, f); - MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); - if (movingobjectposition1 != null) { - double d1 = vec3.distanceTo(movingobjectposition1.hitVec); - if (d1 < d0 || d0 == 0.0D) { - entity = entity1; - d0 = d1; - } - } - } - } - if (entity != null) { - movingobjectposition = new MovingObjectPosition(entity); - } - if (movingobjectposition != null) { - this.onImpact(movingobjectposition); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - float f2 = this.getMotionFactor(); - if (this.isInWater()) { - for (int k = 0; k < 4; ++k) { - float f3 = 0.25F; - this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); - } - f2 = 0.8F; - } - MysticWorld.proxy.fireFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); - this.setPosition(this.posX, this.posY, this.posZ); - } - } - - @Override - protected void entityInit() { - } - - protected float getMotionFactor() { - return 0.95F; + public void chargeFX() { + MysticWorld.proxy.fireFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); } + @Override protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { if (!this.worldObj.isRemote) { this.worldObj.playSoundEffect(this.posX, this.posY, this.posZ, "random.explode", 4.0F, (1.0F + (this.worldObj.rand.nextFloat() - this.worldObj.rand.nextFloat()) * 0.2F) * 0.7F); if (par1MovingObjectPosition.entityHit != null) { double f3 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ); if (f3 > 0.0F) { - par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 1 * 0.6000000238418579D / f3, 0.1D, this.motionZ * 1 * 0.6000000238418579D / f3); + par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 0.6000000238418579D / f3, 0.1D, this.motionZ * 0.6000000238418579D / f3); } if (!par1MovingObjectPosition.entityHit.isImmuneToFire()) { par1MovingObjectPosition.entityHit.setFire(5); @@ -166,18 +59,10 @@ public class EntityChargeFire extends Entity { ++i; } if (this.worldObj.isAirBlock(i, j, k)) { - this.worldObj.setBlock(i, j, k, Block.fire.blockID); + this.worldObj.setBlock(i, j, k, Blocks.fire); } } this.setDead(); } } - - @Override - protected void readEntityFromNBT(NBTTagCompound nbttagcompound) { - } - - @Override - protected void writeEntityToNBT(NBTTagCompound nbttagcompound) { - } } diff --git a/common/MysticWorld/Entity/EntityChargeWater.java b/common/MysticWorld/Entity/EntityChargeWater.java index b8b24a0..c77c2b0 100644 --- a/common/MysticWorld/Entity/EntityChargeWater.java +++ b/common/MysticWorld/Entity/EntityChargeWater.java @@ -1,141 +1,34 @@ package mysticworld.entity; -import java.util.List; - import mysticworld.MysticWorld; -import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.util.AxisAlignedBB; import net.minecraft.util.DamageSource; import net.minecraft.util.MathHelper; import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class EntityChargeWater extends Entity { - public EntityPlayer shootingEntity; - private boolean inGround = false; - private int xTile = -1; - private int yTile = -1; - private int zTile = -1; - private int inTile = 0; - private int ticksAlive; - private int ticksInAir = 0; +public class EntityChargeWater extends EntityCharge { public EntityChargeWater(World par1World) { super(par1World); } public EntityChargeWater(World par1World, EntityPlayer par2EntityPlayer) { - super(par1World); - this.setSize(0.25F, 0.25F); - this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); - this.setPosition(this.posX, this.posY, this.posZ); - this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); - this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); - this.shootingEntity = par2EntityPlayer; + super(par1World,par2EntityPlayer); } @Override - public boolean canBeCollidedWith() { - return true; - } - - @Override - public float getBrightness(float par1) { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public int getBrightnessForRender(float par1) { - return 15728880; - } - - @Override - public float getCollisionBorderSize() { - return 1.0F; - } - - @Override - @SideOnly(Side.CLIENT) - public float getShadowSize() { - return 0.0F; - } - - @Override - public void onUpdate() { - if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { - this.setDead(); - } else { - super.onUpdate(); - Vec3 vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - Vec3 vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition movingobjectposition = this.worldObj.rayTraceBlocks_do_do(vec3, vec31, true, true); - vec3 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX, this.posY, this.posZ); - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (movingobjectposition != null) { - vec31 = this.worldObj.getWorldVec3Pool().getVecFromPool(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); - } - Entity entity = null; - List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); - double d0 = 0.0D; - for (int j = 0; j < list.size(); ++j) { - Entity entity1 = (Entity) list.get(j); - if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { - float f = 0.3F; - AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(f, f, f); - MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); - if (movingobjectposition1 != null) { - double d1 = vec3.distanceTo(movingobjectposition1.hitVec); - if (d1 < d0 || d0 == 0.0D) { - entity = entity1; - d0 = d1; - } - } - } - } - if (entity != null) { - movingobjectposition = new MovingObjectPosition(entity); - } - if (movingobjectposition != null) { - this.onImpact(movingobjectposition); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - float f2 = this.getMotionFactor(); - if (this.isInWater()) { - for (int k = 0; k < 4; ++k) { - float f3 = 0.25F; - this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); - } - f2 = 0.8F; - } - MysticWorld.proxy.waterFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); - this.setPosition(this.posX, this.posY, this.posZ); - } - } - - @Override - protected void entityInit() { - } - - protected float getMotionFactor() { - return 0.95F; + public void chargeFX() { + MysticWorld.proxy.waterFX(this.worldObj, this.posX + (rand.nextDouble() / 2), this.posY + 0.5D, this.posZ + (rand.nextDouble() / 2), 1.0F); } + @Override protected void onImpact(MovingObjectPosition par1MovingObjectPosition) { if (!this.worldObj.isRemote) { this.worldObj.playSoundEffect(this.posX, this.posY, this.posZ, "random.explode", 4.0F, (1.0F + (this.worldObj.rand.nextFloat() - this.worldObj.rand.nextFloat()) * 0.2F) * 0.7F); if (par1MovingObjectPosition.entityHit != null) { double f3 = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ); if (f3 > 0.0F) { - par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 1 * 0.6000000238418579D / f3, 0.1D, this.motionZ * 1 * 0.6000000238418579D / f3); + par1MovingObjectPosition.entityHit.addVelocity(this.motionX * 0.6000000238418579D / f3, 0.1D, this.motionZ * 0.6000000238418579D / f3); } if (par1MovingObjectPosition.entityHit.isImmuneToFire()) { par1MovingObjectPosition.entityHit.attackEntityFrom(DamageSource.magic, 20); @@ -143,8 +36,8 @@ public class EntityChargeWater extends Entity { if (par1MovingObjectPosition.entityHit.isBurning()) { par1MovingObjectPosition.entityHit.extinguish(); } - } else { - int i = par1MovingObjectPosition.blockX; + }/* else { + /*int i = par1MovingObjectPosition.blockX; int j = par1MovingObjectPosition.blockY; int k = par1MovingObjectPosition.blockZ; switch (par1MovingObjectPosition.sideHit) { @@ -166,16 +59,8 @@ public class EntityChargeWater extends Entity { case 5: ++i; } - } + }*/ this.setDead(); } } - - @Override - protected void readEntityFromNBT(NBTTagCompound nbttagcompound) { - } - - @Override - protected void writeEntityToNBT(NBTTagCompound nbttagcompound) { - } } diff --git a/common/MysticWorld/Entity/EntityHandler.java b/common/MysticWorld/Entity/EntityHandler.java index b3ea704..fc68361 100644 --- a/common/MysticWorld/Entity/EntityHandler.java +++ b/common/MysticWorld/Entity/EntityHandler.java @@ -1,20 +1,21 @@ package mysticworld.entity; -import mysticworld.MysticWorld; -import mysticworld.lib.EntityIds; -import mysticworld.lib.Strings; import cpw.mods.fml.common.registry.EntityRegistry; +import mysticworld.MysticWorld; +import mysticworld.lib.Strings; public class EntityHandler { + //Entity IDs + public static final int ENTITY_AIR_CHARGE = 1; + public static final int ENTITY_FIREBALL = 2; + public static final int ENTITY_EARTH_CHARGE = 3; + public static final int ENTITY_ENERGY_CHARGE = 4; + public static final int ENTITY_WATER_CHARGE = 5; public static void init() { - registerEntities(); - } - - public static void registerEntities() { - EntityRegistry.registerModEntity(EntityChargeAir.class, Strings.ENTITY_AIR_CHARGE_NAME, EntityIds.ENTITY_AIR_CHARGE, MysticWorld.instance, 80, 3, false); - EntityRegistry.registerModEntity(EntityChargeFire.class, Strings.ENTITY_FIREBALL_NAME, EntityIds.ENTITY_FIREBALL, MysticWorld.instance, 80, 3, false); - EntityRegistry.registerModEntity(EntityChargeEarth.class, Strings.ENTITY_EARTH_CHARGE_NAME, EntityIds.ENTITY_EARTH_CHARGE, MysticWorld.instance, 80, 3, false); - EntityRegistry.registerModEntity(EntityChargeEnergy.class, Strings.ENTITY_ENERGY_CHARGE_NAME, EntityIds.ENTITY_ENERGY_CHARGE, MysticWorld.instance, 80, 3, false); - EntityRegistry.registerModEntity(EntityChargeWater.class, Strings.ENTITY_WATER_CHARGE_NAME, EntityIds.ENTITY_WATER_CHARGE, MysticWorld.instance, 80, 3, false); + EntityRegistry.registerModEntity(EntityChargeAir.class, Strings.ENTITY_AIR_CHARGE_NAME, ENTITY_AIR_CHARGE, MysticWorld.instance, 80, 3, false); + EntityRegistry.registerModEntity(EntityChargeFire.class, Strings.ENTITY_FIREBALL_NAME, ENTITY_FIREBALL, MysticWorld.instance, 80, 3, false); + EntityRegistry.registerModEntity(EntityChargeEarth.class, Strings.ENTITY_EARTH_CHARGE_NAME, ENTITY_EARTH_CHARGE, MysticWorld.instance, 80, 3, false); + EntityRegistry.registerModEntity(EntityChargeEnergy.class, Strings.ENTITY_ENERGY_CHARGE_NAME, ENTITY_ENERGY_CHARGE, MysticWorld.instance, 80, 3, false); + EntityRegistry.registerModEntity(EntityChargeWater.class, Strings.ENTITY_WATER_CHARGE_NAME, ENTITY_WATER_CHARGE, MysticWorld.instance, 80, 3, false); } } diff --git a/common/MysticWorld/Items/EnumArmor.java b/common/MysticWorld/Items/EnumArmor.java index 89d822d..cdf8a99 100644 --- a/common/MysticWorld/Items/EnumArmor.java +++ b/common/MysticWorld/Items/EnumArmor.java @@ -1,12 +1,12 @@ package mysticworld.items; -import net.minecraft.item.EnumArmorMaterial; -import net.minecraftforge.common.EnumHelper; +import net.minecraft.item.ItemArmor; +import net.minecraftforge.common.util.EnumHelper; public class EnumArmor { - static EnumArmorMaterial Verdite = EnumHelper.addArmorMaterial("Verdite", 262, new int[]{2, 5, 4, 1}, 5); - static EnumArmorMaterial Mithril = EnumHelper.addArmorMaterial("Mithril", 500, new int[]{2, 7, 6, 2}, 9); - static EnumArmorMaterial Adamantine = EnumHelper.addArmorMaterial("Adamantine", 3000, new int[]{4, 9, 6, 4}, 13); - static EnumArmorMaterial Iridium = EnumHelper.addArmorMaterial("Iridium", 4000, new int[]{4, 10, 7, 5}, 15); + public static final ItemArmor.ArmorMaterial Verdite = EnumHelper.addArmorMaterial("Verdite", 262, new int[]{2, 5, 4, 1}, 5); + public static final ItemArmor.ArmorMaterial Mithril = EnumHelper.addArmorMaterial("Mithril", 500, new int[]{2, 7, 6, 2}, 9); + public static final ItemArmor.ArmorMaterial Adamantine = EnumHelper.addArmorMaterial("Adamantine", 3000, new int[]{4, 9, 6, 4}, 13); + public static final ItemArmor.ArmorMaterial Iridium = EnumHelper.addArmorMaterial("Iridium", 4000, new int[]{4, 10, 7, 5}, 15); } diff --git a/common/MysticWorld/Items/ItemArmorAdamantine.java b/common/MysticWorld/Items/ItemArmorAdamantine.java deleted file mode 100644 index 7dd45b0..0000000 --- a/common/MysticWorld/Items/ItemArmorAdamantine.java +++ /dev/null @@ -1,47 +0,0 @@ -package mysticworld.items; - -import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.entity.Entity; -import net.minecraft.item.EnumArmorMaterial; -import net.minecraft.item.ItemArmor; -import net.minecraft.item.ItemStack; - -public class ItemArmorAdamantine extends ItemArmor { - int ArmorType; - String ArmorFile_1; - String ArmorFile_2; - - public ItemArmorAdamantine(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { - super(par1, par2EnumArmorMaterial, par3, par4); - this.ArmorType = par4; - this.setMaxDamage(3000); - this.setCreativeTab(MysticWorld.MysticWorldTab); - this.ArmorFile_1 = "/MysticMods/textures/armor/adamantine_1.png"; - this.ArmorFile_2 = "/MysticMods/textures/armor/adamantine_2.png"; - } - - @Override - public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { - int suffix = this.armorType == 2 ? 2 : 1; - return "MysticMods:textures" + "/models/armor/Adamantine_layer_" + suffix + ".png"; - } - - @Override - public void registerIcons(IconRegister iconRegister) { - switch (ArmorType) { - case 0: - itemIcon = iconRegister.registerIcon("MysticMods:AdamantineArmor_0"); - break; - case 1: - itemIcon = iconRegister.registerIcon("MysticMods:AdamantineArmor_1"); - break; - case 2: - itemIcon = iconRegister.registerIcon("MysticMods:AdamantineArmor_2"); - break; - case 3: - itemIcon = iconRegister.registerIcon("MysticMods:AdamantineArmor_3"); - break; - } - } -} diff --git a/common/MysticWorld/Items/ItemArmorIridium.java b/common/MysticWorld/Items/ItemArmorIridium.java index 6c0746c..fdaae09 100644 --- a/common/MysticWorld/Items/ItemArmorIridium.java +++ b/common/MysticWorld/Items/ItemArmorIridium.java @@ -1,82 +1,45 @@ package mysticworld.items; -import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.EnumArmorMaterial; -import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.world.World; -public class ItemArmorIridium extends ItemArmor { - int ArmorType; - String ArmorFile_1; - String ArmorFile_2; - - public ItemArmorIridium(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { - super(par1, par2EnumArmorMaterial, par3, par4); - this.ArmorType = par4; +public class ItemArmorIridium extends ItemMaterialArmor { + public ItemArmorIridium(ArmorMaterial par2EnumArmorMaterial, int par4) { + super(par2EnumArmorMaterial, par4); this.setMaxDamage(4000); - this.setCreativeTab(MysticWorld.MysticWorldTab); - this.ArmorFile_1 = "/assets/MysticMods/textures/armor/iridium_1.png"; - this.ArmorFile_2 = "/assets/MysticMods/textures/armor/iridium_2.png"; } @Override - public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { - int suffix = this.armorType == 2 ? 2 : 1; - return "MysticMods:textures" + "/models/armor/Iridium_layer_" + suffix + ".png"; - } - - @Override - public void onArmorTickUpdate(World world, EntityPlayer player, ItemStack itemStack) { - ItemStack helmet = player.getCurrentItemOrArmor(4); - ItemStack plate = player.getCurrentItemOrArmor(3); - ItemStack legs = player.getCurrentItemOrArmor(2); - ItemStack boots = player.getCurrentItemOrArmor(1); + public void onArmorTick(World world, EntityPlayer player, ItemStack itemStack) { + ItemStack helmet = player.getEquipmentInSlot(4); if (helmet != null) { - if (helmet.itemID == ItemHandler.iridiumHelmet.itemID) { - player.addPotionEffect((new PotionEffect(Potion.nightVision.getId(), 200, 0))); + if (helmet.getItem() == ItemHandler.iridiumHelmet) { + player.addPotionEffect((new PotionEffect(Potion.nightVision.getId(), 210, 0))); } } + ItemStack plate = player.getEquipmentInSlot(3); if (plate != null) { - if (plate.itemID == ItemHandler.iridiumChestplate.itemID) { + if (plate.getItem() == ItemHandler.iridiumChestplate) { player.addPotionEffect((new PotionEffect(Potion.regeneration.getId(), 200, 0))); } } + ItemStack legs = player.getEquipmentInSlot(2); if (legs != null) { - if (legs.itemID == ItemHandler.iridiumLeggings.itemID) { + if (legs.getItem() == ItemHandler.iridiumLeggings) { player.addPotionEffect((new PotionEffect(Potion.moveSpeed.getId(), 200, 2))); player.addVelocity(0.0005, 0, 0.0005); player.stepHeight = 1.001F; } } + ItemStack boots = player.getEquipmentInSlot(1); if (boots != null) { - if (boots.itemID == ItemHandler.iridiumBoots.itemID) { + if (boots.getItem() == ItemHandler.iridiumBoots) { player.fallDistance = 0.0F; player.addPotionEffect((new PotionEffect(Potion.jump.getId(), 200, 2))); } } } - - @Override - public void registerIcons(IconRegister iconRegister) { - switch (ArmorType) { - case 0: - itemIcon = iconRegister.registerIcon("MysticMods:IridiumArmor_0"); - break; - case 1: - itemIcon = iconRegister.registerIcon("MysticMods:IridiumArmor_1"); - break; - case 2: - itemIcon = iconRegister.registerIcon("MysticMods:IridiumArmor_2"); - break; - case 3: - itemIcon = iconRegister.registerIcon("MysticMods:IridiumArmor_3"); - break; - } - } } \ No newline at end of file diff --git a/common/MysticWorld/Items/ItemArmorMithril.java b/common/MysticWorld/Items/ItemArmorMithril.java deleted file mode 100644 index 4706c40..0000000 --- a/common/MysticWorld/Items/ItemArmorMithril.java +++ /dev/null @@ -1,47 +0,0 @@ -package mysticworld.items; - -import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.entity.Entity; -import net.minecraft.item.EnumArmorMaterial; -import net.minecraft.item.ItemArmor; -import net.minecraft.item.ItemStack; - -public class ItemArmorMithril extends ItemArmor { - int ArmorType; - String ArmorFile_1; - String ArmorFile_2; - - public ItemArmorMithril(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { - super(par1, par2EnumArmorMaterial, par3, par4); - this.ArmorType = par4; - this.setMaxDamage(500); - this.setCreativeTab(MysticWorld.MysticWorldTab); - this.ArmorFile_1 = "/assets/MysticMods/textures/armor/mithril_1.png"; - this.ArmorFile_2 = "/assets/MysticMods/textures/armor/mithril_2.png"; - } - - @Override - public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { - int suffix = this.armorType == 2 ? 2 : 1; - return "MysticMods:textures" + "/models/armor/Mithril_layer_" + suffix + ".png"; - } - - @Override - public void registerIcons(IconRegister iconRegister) { - switch (ArmorType) { - case 0: - itemIcon = iconRegister.registerIcon("MysticMods:MithrilArmor_0"); - break; - case 1: - itemIcon = iconRegister.registerIcon("MysticMods:MithrilArmor_1"); - break; - case 2: - itemIcon = iconRegister.registerIcon("MysticMods:MithrilArmor_2"); - break; - case 3: - itemIcon = iconRegister.registerIcon("MysticMods:MithrilArmor_3"); - break; - } - } -} diff --git a/common/MysticWorld/Items/ItemArmorVerdite.java b/common/MysticWorld/Items/ItemArmorVerdite.java deleted file mode 100644 index aed9f4f..0000000 --- a/common/MysticWorld/Items/ItemArmorVerdite.java +++ /dev/null @@ -1,47 +0,0 @@ -package mysticworld.items; - -import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.entity.Entity; -import net.minecraft.item.EnumArmorMaterial; -import net.minecraft.item.ItemArmor; -import net.minecraft.item.ItemStack; - -public class ItemArmorVerdite extends ItemArmor { - int ArmorType; - String ArmorFile_1; - String ArmorFile_2; - - public ItemArmorVerdite(int par1, EnumArmorMaterial par2EnumArmorMaterial, int par3, int par4) { - super(par1, par2EnumArmorMaterial, par3, par4); - this.ArmorType = par4; - this.setMaxDamage(262); - this.setCreativeTab(MysticWorld.MysticWorldTab); - this.ArmorFile_1 = "/assets/MysticMods/textures/armor/verdite_1.png"; - this.ArmorFile_2 = "/assets/MysticMods/textures/armor/verdite_2.png"; - } - - @Override - public String getArmorTexture(ItemStack stack, Entity entity, int slot, int layer) { - int suffix = this.armorType == 2 ? 2 : 1; - return "MysticMods:textures" + "/models/armor/Verdite_layer_" + suffix + ".png"; - } - - @Override - public void registerIcons(IconRegister iconRegister) { - switch (ArmorType) { - case 0: - itemIcon = iconRegister.registerIcon("MysticMods:VerditeArmor_0"); - break; - case 1: - itemIcon = iconRegister.registerIcon("MysticMods:VerditeArmor_1"); - break; - case 2: - itemIcon = iconRegister.registerIcon("MysticMods:VerditeArmor_2"); - break; - case 3: - itemIcon = iconRegister.registerIcon("MysticMods:VerditeArmor_3"); - break; - } - } -} diff --git a/common/MysticWorld/Items/ItemBushFruit.java b/common/MysticWorld/Items/ItemBushFruit.java index f1f5808..d7bcb5b 100644 --- a/common/MysticWorld/Items/ItemBushFruit.java +++ b/common/MysticWorld/Items/ItemBushFruit.java @@ -1,38 +1,38 @@ package mysticworld.items; -import java.util.List; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.item.Item; import net.minecraft.item.ItemFood; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.util.MathHelper; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; public class ItemBushFruit extends ItemFood { - private Icon[] icons; + private IIcon[] icons; private static final String[] FRUIT_TYPES = new String[] { "Mundane", "Poison", "Weakness", "Slowness", "Harming", "Wither", "Health", "Speed", "FireResistance", "Regen", "NightVision", "Invisibility" }; - public ItemBushFruit(int id, int health) { - super(id, health, 0.6F, false); + public ItemBushFruit(int health) { + super(health, 0.6F, false); this.setHasSubtypes(true); this.setCreativeTab(MysticWorld.MysticWorldTab); maxStackSize = 64; setAlwaysEdible(); - setUnlocalizedName("bushFruit"); } @Override @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int meta) { + public IIcon getIconFromDamage(int meta) { int j = MathHelper.clamp_int(meta, 0, FRUIT_TYPES.length); return icons[j]; } @@ -44,7 +44,7 @@ public class ItemBushFruit extends ItemFood { @Override @SideOnly(Side.CLIENT) - public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List) { + public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List) { for (int var4 = 0; var4 < FRUIT_TYPES.length; var4++) { par3List.add(new ItemStack(par1, 1, var4)); } @@ -60,10 +60,10 @@ public class ItemBushFruit extends ItemFood { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - icons = new Icon[FRUIT_TYPES.length]; + public void registerIcons(IIconRegister iconRegister) { + icons = new IIcon[FRUIT_TYPES.length]; for (int i = 0; i < FRUIT_TYPES.length; ++i) { - icons[i] = iconRegister.registerIcon("MysticMods:Fruit" + FRUIT_TYPES[i]); + icons[i] = iconRegister.registerIcon("mysticworld:Fruit" + FRUIT_TYPES[i]); } } @@ -76,77 +76,77 @@ public class ItemBushFruit extends ItemFood { case 1: potion = player.getActivePotionEffect(Potion.poison); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.poison.id, duration + 160, 0)); break; case 2: potion = player.getActivePotionEffect(Potion.weakness); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.weakness.id, duration + 160, 0)); break; case 3: potion = player.getActivePotionEffect(Potion.moveSlowdown); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.moveSlowdown.id, duration + 160, 0)); break; case 4: potion = player.getActivePotionEffect(Potion.harm); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.harm.id, duration + 1, 0)); break; case 5: potion = player.getActivePotionEffect(Potion.wither); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.wither.id, duration + 160, 0)); break; case 6: potion = player.getActivePotionEffect(Potion.heal); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.heal.id, duration + 1, 0)); break; case 7: potion = player.getActivePotionEffect(Potion.moveSpeed); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.moveSpeed.id, duration + 160, 0)); break; case 8: potion = player.getActivePotionEffect(Potion.fireResistance); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.fireResistance.id, duration + 160, 0)); break; case 9: potion = player.getActivePotionEffect(Potion.regeneration); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.regeneration.id, duration + 160, 0)); break; case 10: potion = player.getActivePotionEffect(Potion.nightVision); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.nightVision.id, duration + 160, 0)); break; case 11: potion = player.getActivePotionEffect(Potion.invisibility); if (potion != null) { - duration = potion.duration; + duration = potion.getDuration(); } player.addPotionEffect(new PotionEffect(Potion.invisibility.id, duration + 160, 0)); break; diff --git a/common/MysticWorld/Items/ItemImbuedShard.java b/common/MysticWorld/Items/ItemImbuedShard.java index 2c14c2b..0a75b8f 100644 --- a/common/MysticWorld/Items/ItemImbuedShard.java +++ b/common/MysticWorld/Items/ItemImbuedShard.java @@ -1,39 +1,37 @@ package mysticworld.items; -import java.util.List; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; -import mysticworld.lib.Strings; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; public class ItemImbuedShard extends Item { - private Icon[] icons; + private IIcon[] icons; private static final String[] SHARD_TYPES = new String[] { "Fire", "Water", "Earth", "Air", "Energy" }; - public ItemImbuedShard(int id) { - super(id); + public ItemImbuedShard() { + super(); this.setHasSubtypes(true); - this.setUnlocalizedName(Strings.IMBUED_SHARD_NAME); this.setCreativeTab(MysticWorld.MysticWorldTab); } @Override @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int meta) { + public IIcon getIconFromDamage(int meta) { int j = MathHelper.clamp_int(meta, 0, 5); return icons[j]; } @Override @SideOnly(Side.CLIENT) - public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List) { + public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List) { for (int var4 = 0; var4 < SHARD_TYPES.length; var4++) { par3List.add(new ItemStack(par1, 1, var4)); } @@ -47,10 +45,10 @@ public class ItemImbuedShard extends Item { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - icons = new Icon[SHARD_TYPES.length]; + public void registerIcons(IIconRegister iconRegister) { + icons = new IIcon[SHARD_TYPES.length]; for (int i = 0; i < SHARD_TYPES.length; ++i) { - icons[i] = iconRegister.registerIcon("MysticMods:Shard" + SHARD_TYPES[i]); + icons[i] = iconRegister.registerIcon("mysticworld:Shard" + SHARD_TYPES[i]); } } } diff --git a/common/MysticWorld/Items/ItemOrb.java b/common/MysticWorld/Items/ItemOrb.java index fc80577..291f3bb 100644 --- a/common/MysticWorld/Items/ItemOrb.java +++ b/common/MysticWorld/Items/ItemOrb.java @@ -1,17 +1,21 @@ package mysticworld.items; -import java.util.Random; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.item.Item; public class ItemOrb extends Item { - Random rand = new Random(); - - public ItemOrb(int id) { - super(id); + public ItemOrb() { + super(); this.setMaxStackSize(1); this.setMaxDamage(200); this.setCreativeTab(MysticWorld.MysticWorldTab); } + + @Override + @SideOnly(Side.CLIENT) + public void registerIcons(IIconRegister par1IconRegister) { + } } diff --git a/common/MysticWorld/Items/ItemOrbAir.java b/common/MysticWorld/Items/ItemOrbAir.java index e5249eb..62e0702 100644 --- a/common/MysticWorld/Items/ItemOrbAir.java +++ b/common/MysticWorld/Items/ItemOrbAir.java @@ -5,95 +5,86 @@ import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.potion.Potion; +import net.minecraft.potion.PotionEffect; import net.minecraft.util.MathHelper; import net.minecraft.world.World; -import org.lwjgl.input.Mouse; - public class ItemOrbAir extends ItemOrb { - public ItemOrbAir(int id) { - super(id); + public ItemOrbAir() { + super(); } @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer player) { - if (itemStack.stackTagCompound == null) - itemStack.setTagCompound(new NBTTagCompound()); - if (itemStack.stackTagCompound.getBoolean("charging") == false) { - itemStack.stackTagCompound.setBoolean("charging", true); - } - return itemStack; + player.setItemInUse(itemStack, this.getMaxItemUseDuration(itemStack)); + return itemStack; } + @Override + public int getMaxItemUseDuration(ItemStack itemStack){ + return 5*20; + } + + @Override + public void onPlayerStoppedUsing(ItemStack itemStack, World world, EntityPlayer player, int time) { + int charge = getMaxItemUseDuration(itemStack)-time; + if (charge > 0) { + if (player.onGround) { + world.playSoundEffect(player.posX, player.posY, player.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); + if(!world.isRemote){ + player.addPotionEffect(new PotionEffect(Potion.jump.getId(), 50, charge*25/getMaxItemUseDuration(itemStack))); + } + itemStack.damageItem(1, player); + } + resetData(itemStack); + } + } + @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - if (itemStack.stackTagCompound == null) - itemStack.setTagCompound(new NBTTagCompound()); - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - itemStack.stackTagCompound.setInteger("maxChargeTime", 5 * 20); - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.fallDistance = 0.0F; - chargeEffect(itemStack, world, player); - if (!Mouse.isButtonDown(1)) { - if (itemStack.stackTagCompound.getInteger("chargeTime") > 0) { - if (player.onGround) { - world.playSoundEffect(player.posX, player.posY, player.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - player.setVelocity(0.0D, 1.0D + (itemStack.stackTagCompound.getInteger("chargeTime")) * (2.5D * (1.0D / itemStack.stackTagCompound.getInteger("maxChargeTime"))), 0.0D); - itemStack.damageItem(1, player); - } - } - resetData(itemStack); - } else { - if (itemStack.stackTagCompound.getBoolean("charging") == true) { - incrementData(itemStack); - } - spiralEffect(itemStack, world, player); - } - } - } else { - resetData(itemStack); - itemStack.stackTagCompound.setFloat("angle", 0); - itemStack.stackTagCompound.setDouble("radius", 0); - } - if (itemStack.stackTagCompound.getInteger("chargeTime") > itemStack.stackTagCompound.getInteger("maxChargeTime")) { - itemStack.stackTagCompound.setInteger("chargeTime", itemStack.stackTagCompound.getInteger("maxChargeTime")); - } - if (itemStack.stackTagCompound.getDouble("radius") > 2.5D) { - itemStack.stackTagCompound.setDouble("radius", 2.5D); - } - if (itemStack.stackTagCompound.getFloat("angle") > 6.0f) { - itemStack.stackTagCompound.setFloat("angle", 0.0f); - } + if (par5) { + entity.fallDistance = 0.0F; + chargeEffect(itemStack, world, entity); + } } - private void chargeEffect(ItemStack itemStack, World world, EntityPlayer player) { - double particleX = (player.posX - 0.5D) + rand.nextDouble(); - double particleZ = (player.posZ - 0.5D) + rand.nextDouble(); - if (!world.isRemote) - MysticWorld.proxy.airFeetFX(world, particleX, player.posY, particleZ, 1.0f, 15); + @Override + public void onUsingTick(ItemStack stack, EntityPlayer player, int count){ + if (stack.stackTagCompound == null){ + stack.setTagCompound(new NBTTagCompound()); + } + incrementData(stack, getMaxItemUseDuration(stack) - count); + spiralEffect(stack, player.worldObj, player, getMaxItemUseDuration(stack) - count); + } + + private void chargeEffect(ItemStack itemStack, World world, Entity player) { + double particleX = (player.posX - 0.5D) + itemRand.nextDouble(); + double particleZ = (player.posZ - 0.5D) + itemRand.nextDouble(); + MysticWorld.proxy.airFeetFX(world, particleX, player.posY, particleZ, 1.0f, 15); } - private void incrementData(ItemStack itemStack) { - itemStack.stackTagCompound.setInteger("chargeTime", itemStack.stackTagCompound.getInteger("chargeTime") + 1); + private void incrementData(ItemStack itemStack, int charge) { itemStack.stackTagCompound.setFloat("angle", itemStack.stackTagCompound.getFloat("angle") + 0.2f); - itemStack.stackTagCompound.setDouble("radius", itemStack.stackTagCompound.getInteger("chargeTime") * 0.025D); + itemStack.stackTagCompound.setDouble("radius", charge * 0.025D); + if (itemStack.stackTagCompound.getDouble("radius") > 2.5D) { + itemStack.stackTagCompound.setDouble("radius", 2.5D); + } + if (itemStack.stackTagCompound.getFloat("angle") > 6.0f) { + itemStack.stackTagCompound.setFloat("angle", 0.0f); + } } private void resetData(ItemStack itemStack) { - itemStack.stackTagCompound.setInteger("chargeTime", 0); - itemStack.stackTagCompound.setBoolean("charging", false); itemStack.stackTagCompound.setFloat("angle", 0); itemStack.stackTagCompound.setDouble("radius", 0); } - private void spiralEffect(ItemStack itemStack, World world, EntityPlayer player) { + private void spiralEffect(ItemStack itemStack, World world, EntityPlayer player, int charge) { double particleX = player.posX + (MathHelper.cos(itemStack.stackTagCompound.getFloat("angle"))) * itemStack.stackTagCompound.getDouble("radius"); double particleY = player.posY; double particleZ = player.posZ + (MathHelper.sin(itemStack.stackTagCompound.getFloat("angle"))) * itemStack.stackTagCompound.getDouble("radius"); - float particleScale = ((itemStack.stackTagCompound.getInteger("chargeTime")) * (5.0f * (1 / (float) itemStack.stackTagCompound.getInteger("maxChargeTime")))); - if (!world.isRemote) - MysticWorld.proxy.airFeetFX(world, particleX, particleY, particleZ, 1.0f + particleScale, 15); + float particleScale = charge * 5.0f / getMaxItemUseDuration(itemStack); + MysticWorld.proxy.airFeetFX(world, particleX, particleY, particleZ, 1.0f + particleScale, 15); } } diff --git a/common/MysticWorld/Items/ItemOrbEarth.java b/common/MysticWorld/Items/ItemOrbEarth.java index 77b6da5..d5f514c 100644 --- a/common/MysticWorld/Items/ItemOrbEarth.java +++ b/common/MysticWorld/Items/ItemOrbEarth.java @@ -1,26 +1,19 @@ package mysticworld.items; +import cpw.mods.fml.common.eventhandler.Event; import mysticworld.MysticWorld; import net.minecraft.block.Block; -import net.minecraft.block.BlockCocoa; -import net.minecraft.block.BlockCrops; -import net.minecraft.block.BlockDirectional; -import net.minecraft.block.BlockMushroom; -import net.minecraft.block.BlockSapling; -import net.minecraft.block.BlockStem; +import net.minecraft.block.IGrowable; import net.minecraft.entity.Entity; -import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.world.World; -import net.minecraftforge.common.ForgeHooks; import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.event.Event.Result; import net.minecraftforge.event.entity.player.BonemealEvent; public class ItemOrbEarth extends ItemOrb { - public ItemOrbEarth(int id) { - super(id); + public ItemOrbEarth() { + super(); } @Override @@ -41,124 +34,35 @@ public class ItemOrbEarth extends ItemOrb { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - MysticWorld.proxy.earthFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (par5) { + MysticWorld.proxy.earthFX(world, (player.posX - 0.5D) + itemRand.nextDouble(), player.posY, (player.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } - public static boolean applyBonemeal(ItemStack itemStack, World par1World, int par2, int par3, int par4, EntityPlayer player) { - int l = par1World.getBlockId(par2, par3, par4); - BonemealEvent event = new BonemealEvent(player, par1World, l, par2, par3, par4); - if (MinecraftForge.EVENT_BUS.post(event)) { - return false; - } - if (event.getResult() == Result.ALLOW) { - itemStack.damageItem(1, player); - return true; - } - if (l == Block.sapling.blockID) { - if (!par1World.isRemote) { - if (par1World.rand.nextFloat() < 0.45D) { - ((BlockSapling) Block.sapling).markOrGrowMarked(par1World, par2, par3, par4, par1World.rand); - } - itemStack.damageItem(1, player); - } - return true; - } else if (l == Block.cobblestone.blockID) { - if (!par1World.isRemote) { - par1World.setBlock(par2, par3, par4, Block.cobblestoneMossy.blockID); - } - itemStack.damageItem(1, player); - } else if (l == Block.deadBush.blockID) { - if (!par1World.isRemote) { - par1World.setBlock(par2, par3, par4, 0); - par1World.spawnEntityInWorld(new EntityItem(par1World, par2, par3, par4, new ItemStack(Block.sapling, 1))); - } - itemStack.damageItem(1, player); - } else if (l != Block.mushroomBrown.blockID && l != Block.mushroomRed.blockID) { - if (l != Block.melonStem.blockID && l != Block.pumpkinStem.blockID) { - if (l > 0 && Block.blocksList[l] instanceof BlockCrops) { - if (par1World.getBlockMetadata(par2, par3, par4) == 7) { - return false; - } else { - if (!par1World.isRemote) { - ((BlockCrops) Block.blocksList[l]).fertilize(par1World, par2, par3, par4); - itemStack.damageItem(1, player); - } - return true; - } - } else { - int i1; - int j1; - int k1; - if (l == Block.cocoaPlant.blockID) { - i1 = par1World.getBlockMetadata(par2, par3, par4); - j1 = BlockDirectional.getDirection(i1); - k1 = BlockCocoa.func_72219_c(i1); - if (k1 >= 2) { - return false; - } else { - if (!par1World.isRemote) { - ++k1; - par1World.setBlockMetadataWithNotify(par2, par3, par4, k1 << 2 | j1, 2); - itemStack.damageItem(1, player); - } - return true; - } - } else if (l != Block.grass.blockID) { - return false; - } else { - if (!par1World.isRemote) { - itemStack.damageItem(1, player); - label102: for (i1 = 0; i1 < 128; ++i1) { - j1 = par2; - k1 = par3 + 1; - int l1 = par4; - for (int i2 = 0; i2 < i1 / 16; ++i2) { - j1 += itemRand.nextInt(3) - 1; - k1 += (itemRand.nextInt(3) - 1) * itemRand.nextInt(3) / 2; - l1 += itemRand.nextInt(3) - 1; - if (par1World.getBlockId(j1, k1 - 1, l1) != Block.grass.blockID || par1World.isBlockNormalCube(j1, k1, l1)) { - continue label102; - } - } - if (par1World.getBlockId(j1, k1, l1) == 0) { - if (itemRand.nextInt(10) != 0) { - if (Block.tallGrass.canBlockStay(par1World, j1, k1, l1)) { - par1World.setBlock(j1, k1, l1, Block.tallGrass.blockID, 1, 3); - } - } else { - ForgeHooks.plantGrass(par1World, j1, k1, l1); - } - } - } - } - return true; - } - } - } else if (par1World.getBlockMetadata(par2, par3, par4) == 7) { - return false; - } else { - if (!par1World.isRemote) { - ((BlockStem) Block.blocksList[l]).fertilizeStem(par1World, par2, par3, par4); - itemStack.damageItem(1, player); - } - return true; - } - } else { - if (!par1World.isRemote) { - if (par1World.rand.nextFloat() < 0.4D) { - ((BlockMushroom) Block.blocksList[l]).fertilizeMushroom(par1World, par2, par3, par4, par1World.rand); - } - itemStack.damageItem(1, player); - } - return true; - } - return true; + public static boolean applyBonemeal(ItemStack itemStack, World world, int x, int y, int z, EntityPlayer player) { + Block block = world.getBlock(x, y, z); + BonemealEvent event = new BonemealEvent(player, world, block, x, y, z); + if (MinecraftForge.EVENT_BUS.post(event)){ + return false; + } + if (event.getResult() == Event.Result.ALLOW){ + if (!world.isRemote){ + itemStack.damageItem(1, player); + } + return true; + } + if (block instanceof IGrowable){ + IGrowable igrowable = (IGrowable)block; + if (igrowable.func_149851_a(world, x, y, z, world.isRemote)){ + if (!world.isRemote){ + if (igrowable.func_149852_a(world, world.rand, x, y, z)){ + igrowable.func_149853_b(world, world.rand, x, y, z); + } + itemStack.damageItem(1, player); + } + return true; + } + } + return false; } } diff --git a/common/MysticWorld/Items/ItemOrbEnergy.java b/common/MysticWorld/Items/ItemOrbEnergy.java index 83f3b6f..bd2b05d 100644 --- a/common/MysticWorld/Items/ItemOrbEnergy.java +++ b/common/MysticWorld/Items/ItemOrbEnergy.java @@ -2,16 +2,18 @@ package mysticworld.items; import mysticworld.MysticWorld; import mysticworld.blocks.BlockHandler; +import net.minecraft.block.Block; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.world.World; public class ItemOrbEnergy extends ItemOrb { - public ItemOrbEnergy(int id) { - super(id); + public ItemOrbEnergy() { + super(); } @Override @@ -37,10 +39,10 @@ public class ItemOrbEnergy extends ItemOrb { if (!entityPlayer.canPlayerEdit(par4, par5, par6, par7, itemStack)) { return false; } else { - int i1 = world.getBlockId(par4, par5, par6); - if (i1 == 0) { + Block i1 = world.getBlock(par4, par5, par6); + if (i1 == Blocks.air) { world.playSoundEffect(par4 + 0.5D, par5 + 0.5D, par6 + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - world.setBlock(par4, par5, par6, BlockHandler.lightCube.blockID); + world.setBlock(par4, par5, par6, BlockHandler.lightCube); } itemStack.damageItem(1, entityPlayer); return true; @@ -49,15 +51,9 @@ public class ItemOrbEnergy extends ItemOrb { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2)); - MysticWorld.proxy.energyFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (entity instanceof EntityPlayer && par5) { + ((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2)); + MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } diff --git a/common/MysticWorld/Items/ItemOrbFire.java b/common/MysticWorld/Items/ItemOrbFire.java index 405f85b..cd33300 100644 --- a/common/MysticWorld/Items/ItemOrbFire.java +++ b/common/MysticWorld/Items/ItemOrbFire.java @@ -1,10 +1,10 @@ package mysticworld.items; import mysticworld.MysticWorld; -import net.minecraft.block.Block; import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; +import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; @@ -12,14 +12,15 @@ import net.minecraft.util.DamageSource; import net.minecraft.world.World; public class ItemOrbFire extends ItemOrb { - public ItemOrbFire(int id) { - super(id); + public ItemOrbFire() { + super(); } - public boolean itemInteractionForEntity(ItemStack itemStack, EntityLiving entityLiving) { - entityLiving.setFire(5); - entityLiving.attackEntityFrom(DamageSource.magic, 7); - itemStack.damageItem(1, entityLiving); + @Override + public boolean itemInteractionForEntity(ItemStack itemStack, EntityPlayer entityPlayer, EntityLivingBase entity) { + entity.setFire(5); + entity.attackEntityFrom(DamageSource.magic, 7); + itemStack.damageItem(1, entityPlayer); return true; } @@ -48,7 +49,7 @@ public class ItemOrbFire extends ItemOrb { } else { if (par3World.isAirBlock(par4, par5, par6)) { par3World.playSoundEffect(par4 + 0.5D, par5 + 0.5D, par6 + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - par3World.setBlock(par4, par5, par6, Block.fire.blockID); + par3World.setBlock(par4, par5, par6, Blocks.fire); } par1ItemStack.damageItem(1, par2EntityPlayer); return true; @@ -65,15 +66,9 @@ public class ItemOrbFire extends ItemOrb { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0)); - MysticWorld.proxy.fireFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (entity instanceof EntityPlayer && par5) { + ((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0)); + MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } diff --git a/common/MysticWorld/Items/ItemOrbWater.java b/common/MysticWorld/Items/ItemOrbWater.java index 8ea45e7..0017449 100644 --- a/common/MysticWorld/Items/ItemOrbWater.java +++ b/common/MysticWorld/Items/ItemOrbWater.java @@ -5,14 +5,14 @@ import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; public class ItemOrbWater extends ItemOrb { - public ItemOrbWater(int id) { - super(id); + public ItemOrbWater() { + super(); } @Override @@ -21,7 +21,7 @@ public class ItemOrbWater extends ItemOrb { if (movingobjectposition == null) { return itemStack; } else { - if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { + if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; @@ -31,7 +31,7 @@ public class ItemOrbWater extends ItemOrb { if (!entityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, itemStack)) { return itemStack; } - if (world.getBlockMaterial(i, j, k) == Material.water && world.getBlockMetadata(i, j, k) == 0) { + if (world.getBlock(i, j, k).getMaterial() == Material.water && world.getBlockMetadata(i, j, k) == 0) { world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); world.setBlockToAir(i, j, k); itemStack.damageItem(1, entityPlayer); @@ -58,10 +58,10 @@ public class ItemOrbWater extends ItemOrb { if (!entityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, itemStack)) { return itemStack; } else { - int i1 = world.getBlockId(i, j, k); - if (i1 == 0) { + Block i1 = world.getBlock(i, j, k); + if (i1 == Blocks.air) { world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - world.setBlock(i, j, k, Block.waterMoving.blockID); + world.setBlock(i, j, k, Blocks.flowing_water); itemStack.damageItem(1, entityPlayer); } return itemStack; @@ -74,14 +74,8 @@ public class ItemOrbWater extends ItemOrb { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (itemStack != null) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - MysticWorld.proxy.waterFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (par5) { + MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } diff --git a/common/MysticWorld/Items/ItemStaff.java b/common/MysticWorld/Items/ItemStaff.java index c2ec23d..0da190a 100644 --- a/common/MysticWorld/Items/ItemStaff.java +++ b/common/MysticWorld/Items/ItemStaff.java @@ -1,17 +1,14 @@ package mysticworld.items; -import java.util.Random; - -import mysticworld.MysticWorld; -import net.minecraft.item.Item; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; +import mysticworld.MysticWorld; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.item.Item; public class ItemStaff extends Item { - Random rand = new Random(); - - public ItemStaff(int id) { - super(id); + public ItemStaff() { + super(); this.setMaxStackSize(1); this.setMaxDamage(200); this.setCreativeTab(MysticWorld.MysticWorldTab); @@ -22,4 +19,9 @@ public class ItemStaff extends Item { public boolean isFull3D() { return true; } + + @Override + @SideOnly(Side.CLIENT) + public void registerIcons(IIconRegister par1IconRegister) { + } } diff --git a/common/MysticWorld/Items/ItemStaffAir.java b/common/MysticWorld/Items/ItemStaffAir.java index 10a856d..1d8cea6 100644 --- a/common/MysticWorld/Items/ItemStaffAir.java +++ b/common/MysticWorld/Items/ItemStaffAir.java @@ -5,76 +5,52 @@ import mysticworld.entity.EntityChargeAir; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; import net.minecraft.world.World; -import org.lwjgl.input.Mouse; - public class ItemStaffAir extends ItemStaff { - public ItemStaffAir(int id) { - super(id); + public ItemStaffAir() { + super(); } @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer player) { - if (itemStack.stackTagCompound == null) - itemStack.setTagCompound(new NBTTagCompound()); - if (itemStack.stackTagCompound.getBoolean("charging") == false) { - itemStack.stackTagCompound.setBoolean("charging", true); - } + player.setItemInUse(itemStack, this.getMaxItemUseDuration(itemStack)); return itemStack; } + @Override + public int getMaxItemUseDuration(ItemStack itemStack){ + return 5*20; + } + + @Override + public void onPlayerStoppedUsing(ItemStack itemStack, World world, EntityPlayer player, int time) { + int charge = getMaxItemUseDuration(itemStack)-time; + if (charge > 0) { + world.playAuxSFXAtEntity(player, 1009, (int) player.posX, (int) player.posY, (int) player.posZ, 0); + if (!world.isRemote) + world.spawnEntityInWorld(new EntityChargeAir(world, player, 1.0f + charge * (5.0f * (1 / (float) getMaxItemUseDuration(itemStack))), charge * (2.5D * (1.0D / getMaxItemUseDuration(itemStack))))); + itemStack.damageItem(1, player); + } + } + @Override - public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - if (itemStack.stackTagCompound == null) - itemStack.setTagCompound(new NBTTagCompound()); - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - itemStack.stackTagCompound.setInteger("maxChargeTime", 3 * 20); - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.fallDistance = 0.0F; - chargeEffect(itemStack, world, player); - if (!Mouse.isButtonDown(1)) { - if (itemStack.stackTagCompound.getInteger("chargeTime") > 0) { - if (!world.isRemote) { - world.playAuxSFXAtEntity((EntityPlayer) null, 1009, (int) player.posX, (int) player.posY, (int) player.posZ, 0); - world.spawnEntityInWorld(new EntityChargeAir(world, player, 1.0f + ((itemStack.stackTagCompound.getInteger("chargeTime")) * (5.0f * (1 / (float) itemStack.stackTagCompound - .getInteger("maxChargeTime")))), (itemStack.stackTagCompound.getInteger("chargeTime")) * (2.5D * (1.0D / itemStack.stackTagCompound.getInteger("maxChargeTime"))))); - itemStack.damageItem(1, player); - } - } - resetData(itemStack); - } else { - if (itemStack.stackTagCompound.getBoolean("charging") == true) { - incrementData(itemStack); - } - } - } - } else { - resetData(itemStack); - } - if (itemStack.stackTagCompound.getInteger("chargeTime") > itemStack.stackTagCompound.getInteger("maxChargeTime")) { - itemStack.stackTagCompound.setInteger("chargeTime", itemStack.stackTagCompound.getInteger("maxChargeTime")); + public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean current) { + if (current) { + entity.fallDistance = 0.0F; } } - private void chargeEffect(ItemStack itemStack, World world, EntityPlayer player) { - double particleX = (player.posX - 0.5D) + rand.nextDouble(); - double particleY = player.posY + (player.height / itemStack.stackTagCompound.getInteger("maxChargeTime") * itemStack.stackTagCompound.getInteger("chargeTime")); - double particleZ = (player.posZ - 0.5D) + rand.nextDouble(); - float particleScale = ((itemStack.stackTagCompound.getInteger("chargeTime")) * (5.0f * (1 / (float) itemStack.stackTagCompound.getInteger("maxChargeTime")))); - if (!world.isRemote) - MysticWorld.proxy.airFeetFX(world, particleX, particleY, particleZ, 1.0f + particleScale, 15); - } + @Override + public void onUsingTick(ItemStack stack, EntityPlayer player, int count){ + chargeEffect(stack, player.worldObj, player, getMaxItemUseDuration(stack) - count); + } - private void incrementData(ItemStack itemStack) { - itemStack.stackTagCompound.setInteger("chargeTime", itemStack.stackTagCompound.getInteger("chargeTime") + 1); - } - - private void resetData(ItemStack itemStack) { - itemStack.stackTagCompound.setInteger("chargeTime", 0); - itemStack.stackTagCompound.setBoolean("charging", false); + private void chargeEffect(ItemStack itemStack, World world, Entity player, int charge) { + double particleX = (player.posX - 0.5D) + itemRand.nextDouble(); + double particleY = player.posY + (charge * player.height / getMaxItemUseDuration(itemStack)); + double particleZ = (player.posZ - 0.5D) + itemRand.nextDouble(); + float particleScale = charge * (5.0f * (1 / (float) getMaxItemUseDuration(itemStack))); + MysticWorld.proxy.airFeetFX(world, particleX, particleY, particleZ, 1.0f + particleScale, 15); } } diff --git a/common/MysticWorld/Items/ItemStaffEarth.java b/common/MysticWorld/Items/ItemStaffEarth.java index e744c47..7de7ef7 100644 --- a/common/MysticWorld/Items/ItemStaffEarth.java +++ b/common/MysticWorld/Items/ItemStaffEarth.java @@ -2,40 +2,25 @@ package mysticworld.items; import mysticworld.MysticWorld; import mysticworld.entity.EntityChargeEarth; -import net.minecraft.block.Block; -import net.minecraft.block.BlockCocoa; -import net.minecraft.block.BlockCrops; -import net.minecraft.block.BlockDirectional; -import net.minecraft.block.BlockMushroom; -import net.minecraft.block.BlockSapling; -import net.minecraft.block.BlockStem; import net.minecraft.entity.Entity; -import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; -import net.minecraftforge.common.ForgeHooks; -import net.minecraftforge.common.MinecraftForge; -import net.minecraftforge.event.Event.Result; -import net.minecraftforge.event.entity.player.BonemealEvent; - -import org.lwjgl.input.Keyboard; public class ItemStaffEarth extends ItemStaff { - public ItemStaffEarth(int id) { - super(id); + public ItemStaffEarth() { + super(); } @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer) { - if (Keyboard.isKeyDown(Keyboard.KEY_RSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { + if (entityPlayer.isSneaking()) { MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(world, entityPlayer, true); if (movingobjectposition == null) { return itemStack; } else { - if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { + if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; @@ -55,7 +40,7 @@ public class ItemStaffEarth extends ItemStaff { } } } else { - world.playAuxSFXAtEntity((EntityPlayer) null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); + world.playAuxSFXAtEntity(null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); if (!world.isRemote) { world.spawnEntityInWorld(new EntityChargeEarth(world, entityPlayer)); itemStack.damageItem(1, entityPlayer); @@ -67,125 +52,12 @@ public class ItemStaffEarth extends ItemStaff { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - MysticWorld.proxy.earthFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (par5) { + MysticWorld.proxy.earthFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } public static boolean applyBonemeal(ItemStack itemStack, World par1World, int par2, int par3, int par4, EntityPlayer player) { - int l = par1World.getBlockId(par2, par3, par4); - BonemealEvent event = new BonemealEvent(player, par1World, l, par2, par3, par4); - if (MinecraftForge.EVENT_BUS.post(event)) { - return false; - } - if (event.getResult() == Result.ALLOW) { - itemStack.damageItem(1, player); - return true; - } - if (l == Block.sapling.blockID) { - if (!par1World.isRemote) { - if (par1World.rand.nextFloat() < 0.45D) { - ((BlockSapling) Block.sapling).markOrGrowMarked(par1World, par2, par3, par4, par1World.rand); - } - itemStack.damageItem(1, player); - } - return true; - } else if (l == Block.cobblestone.blockID) { - if (!par1World.isRemote) { - par1World.setBlock(par2, par3, par4, Block.cobblestoneMossy.blockID); - } - itemStack.damageItem(1, player); - } else if (l == Block.deadBush.blockID) { - if (!par1World.isRemote) { - par1World.setBlock(par2, par3, par4, 0); - par1World.spawnEntityInWorld(new EntityItem(par1World, par2, par3, par4, new ItemStack(Block.sapling, 1))); - } - itemStack.damageItem(1, player); - } else if (l != Block.mushroomBrown.blockID && l != Block.mushroomRed.blockID) { - if (l != Block.melonStem.blockID && l != Block.pumpkinStem.blockID) { - if (l > 0 && Block.blocksList[l] instanceof BlockCrops) { - if (par1World.getBlockMetadata(par2, par3, par4) == 7) { - return false; - } else { - if (!par1World.isRemote) { - ((BlockCrops) Block.blocksList[l]).fertilize(par1World, par2, par3, par4); - itemStack.damageItem(1, player); - } - return true; - } - } else { - int i1; - int j1; - int k1; - if (l == Block.cocoaPlant.blockID) { - i1 = par1World.getBlockMetadata(par2, par3, par4); - j1 = BlockDirectional.getDirection(i1); - k1 = BlockCocoa.func_72219_c(i1); - if (k1 >= 2) { - return false; - } else { - if (!par1World.isRemote) { - ++k1; - par1World.setBlockMetadataWithNotify(par2, par3, par4, k1 << 2 | j1, 2); - itemStack.damageItem(1, player); - } - return true; - } - } else if (l != Block.grass.blockID) { - return false; - } else { - if (!par1World.isRemote) { - itemStack.damageItem(1, player); - label102: for (i1 = 0; i1 < 128; ++i1) { - j1 = par2; - k1 = par3 + 1; - int l1 = par4; - for (int i2 = 0; i2 < i1 / 16; ++i2) { - j1 += itemRand.nextInt(3) - 1; - k1 += (itemRand.nextInt(3) - 1) * itemRand.nextInt(3) / 2; - l1 += itemRand.nextInt(3) - 1; - if (par1World.getBlockId(j1, k1 - 1, l1) != Block.grass.blockID || par1World.isBlockNormalCube(j1, k1, l1)) { - continue label102; - } - } - if (par1World.getBlockId(j1, k1, l1) == 0) { - if (itemRand.nextInt(10) != 0) { - if (Block.tallGrass.canBlockStay(par1World, j1, k1, l1)) { - par1World.setBlock(j1, k1, l1, Block.tallGrass.blockID, 1, 3); - } - } else { - ForgeHooks.plantGrass(par1World, j1, k1, l1); - } - } - } - } - return true; - } - } - } else if (par1World.getBlockMetadata(par2, par3, par4) == 7) { - return false; - } else { - if (!par1World.isRemote) { - ((BlockStem) Block.blocksList[l]).fertilizeStem(par1World, par2, par3, par4); - itemStack.damageItem(1, player); - } - return true; - } - } else { - if (!par1World.isRemote) { - if (par1World.rand.nextFloat() < 0.4D) { - ((BlockMushroom) Block.blocksList[l]).fertilizeMushroom(par1World, par2, par3, par4, par1World.rand); - } - itemStack.damageItem(1, player); - } - return true; - } - return true; + return ItemOrbEarth.applyBonemeal(itemStack, par1World, par2, par3, par4, player); } } diff --git a/common/MysticWorld/Items/ItemStaffEnegy.java b/common/MysticWorld/Items/ItemStaffEnegy.java index 47c5544..734d6e0 100644 --- a/common/MysticWorld/Items/ItemStaffEnegy.java +++ b/common/MysticWorld/Items/ItemStaffEnegy.java @@ -8,25 +8,22 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; -import org.lwjgl.input.Keyboard; - public class ItemStaffEnegy extends ItemStaff { - public ItemStaffEnegy(int id) { - super(id); + public ItemStaffEnegy() { + super(); } @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer) { - if (Keyboard.isKeyDown(Keyboard.KEY_RSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { + if (entityPlayer.isSneaking()) { MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(world, entityPlayer, true); if (movingobjectposition == null) { return itemStack; } else { - if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { + if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; @@ -59,7 +56,7 @@ public class ItemStaffEnegy extends ItemStaff { } else { if (world.isAirBlock(i, j, k)) { world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - world.setBlock(i, j, k, BlockHandler.lightCube.blockID); + world.setBlock(i, j, k, BlockHandler.lightCube); } itemStack.damageItem(1, entityPlayer); return itemStack; @@ -68,7 +65,7 @@ public class ItemStaffEnegy extends ItemStaff { } } } else { - world.playAuxSFXAtEntity((EntityPlayer) null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); + world.playAuxSFXAtEntity(null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); if (!world.isRemote) { world.spawnEntityInWorld(new EntityChargeEnergy(world, entityPlayer)); itemStack.damageItem(1, entityPlayer); @@ -80,15 +77,9 @@ public class ItemStaffEnegy extends ItemStaff { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2)); - MysticWorld.proxy.energyFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (entity instanceof EntityPlayer && par5) { + ((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2)); + MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } diff --git a/common/MysticWorld/Items/ItemStaffFire.java b/common/MysticWorld/Items/ItemStaffFire.java index adf3916..4054ba0 100644 --- a/common/MysticWorld/Items/ItemStaffFire.java +++ b/common/MysticWorld/Items/ItemStaffFire.java @@ -3,27 +3,26 @@ package mysticworld.items; import mysticworld.MysticWorld; import mysticworld.entity.EntityChargeFire; import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLiving; +import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.util.DamageSource; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; -import org.lwjgl.input.Keyboard; - public class ItemStaffFire extends ItemStaff { - public ItemStaffFire(int id) { - super(id); + public ItemStaffFire() { + super(); } - public boolean itemInteractionForEntity(ItemStack itemStack, EntityLiving entityLiving) { - if (Keyboard.isKeyDown(Keyboard.KEY_RSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { + @Override + public boolean itemInteractionForEntity(ItemStack itemStack, EntityPlayer entityPlayer, EntityLivingBase entityLiving) { + if (entityPlayer.isSneaking()) { entityLiving.setFire(5); entityLiving.attackEntityFrom(DamageSource.magic, 7); itemStack.damageItem(1, entityLiving); @@ -34,12 +33,12 @@ public class ItemStaffFire extends ItemStaff { @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer) { - if (Keyboard.isKeyDown(Keyboard.KEY_RSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { + if (entityPlayer.isSneaking()) { MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(world, entityPlayer, true); if (movingobjectposition == null) { return itemStack; } else { - if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { + if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; @@ -49,12 +48,12 @@ public class ItemStaffFire extends ItemStaff { if (!entityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, itemStack)) { return itemStack; } else { - ItemStack result = FurnaceRecipes.smelting().getSmeltingResult(new ItemStack(world.getBlockId(i, j, k), 1, world.getBlockMetadata(i, j, k))); - if (!world.isRemote && !(result == null)) { - int id = result.itemID; + ItemStack result = FurnaceRecipes.smelting().getSmeltingResult(new ItemStack(world.getBlock(i, j, k), 1, world.getBlockMetadata(i, j, k))); + if (!world.isRemote && result != null) { + Item id = result.getItem(); int meta = result.getItemDamage(); world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - world.setBlock(i, j, k, 0); + world.setBlockToAir(i, j, k); world.spawnEntityInWorld(new EntityItem(world, i, j, k, new ItemStack(id, 1, meta))); itemStack.damageItem(1, entityPlayer); } @@ -62,7 +61,7 @@ public class ItemStaffFire extends ItemStaff { } } } else { - world.playAuxSFXAtEntity((EntityPlayer) null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); + world.playAuxSFXAtEntity(null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); if (!world.isRemote) { world.spawnEntityInWorld(new EntityChargeFire(world, entityPlayer)); itemStack.damageItem(1, entityPlayer); @@ -82,15 +81,9 @@ public class ItemStaffFire extends ItemStaff { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - player.addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0)); - MysticWorld.proxy.fireFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (entity instanceof EntityPlayer && par5) { + ((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0)); + MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } diff --git a/common/MysticWorld/Items/ItemStaffParts.java b/common/MysticWorld/Items/ItemStaffParts.java index 0ce6633..67006a7 100644 --- a/common/MysticWorld/Items/ItemStaffParts.java +++ b/common/MysticWorld/Items/ItemStaffParts.java @@ -1,37 +1,37 @@ package mysticworld.items; -import java.util.List; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; +import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; public class ItemStaffParts extends Item { - private Icon[] icons; + private IIcon[] icons; private static final String[] STAFF_PARTS = new String[] { "Staff", "Hilt", "Handle", "Head" }; - public ItemStaffParts(int id) { - super(id); + public ItemStaffParts() { + super(); this.setHasSubtypes(true); this.setCreativeTab(MysticWorld.MysticWorldTab); } @Override @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int meta) { + public IIcon getIconFromDamage(int meta) { int j = MathHelper.clamp_int(meta, 0, STAFF_PARTS.length); return icons[j]; } @Override @SideOnly(Side.CLIENT) - public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List) { + public void getSubItems(Item par1, CreativeTabs par2CreativeTabs, List par3List) { for (int var4 = 0; var4 < STAFF_PARTS.length; var4++) { par3List.add(new ItemStack(par1, 1, var4)); } @@ -51,10 +51,10 @@ public class ItemStaffParts extends Item { @Override @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - icons = new Icon[STAFF_PARTS.length]; + public void registerIcons(IIconRegister iconRegister) { + icons = new IIcon[STAFF_PARTS.length]; for (int i = 0; i < STAFF_PARTS.length; ++i) { - icons[i] = iconRegister.registerIcon("MysticMods:StaffPart_" + STAFF_PARTS[i]); + icons[i] = iconRegister.registerIcon("mysticworld:StaffPart_" + STAFF_PARTS[i]); } } } diff --git a/common/MysticWorld/Items/ItemStaffPower.java b/common/MysticWorld/Items/ItemStaffPower.java deleted file mode 100644 index 86736ca..0000000 --- a/common/MysticWorld/Items/ItemStaffPower.java +++ /dev/null @@ -1,43 +0,0 @@ -package mysticworld.items; - -import net.minecraft.client.renderer.texture.IconRegister; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; -import net.minecraft.util.MathHelper; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class ItemStaffPower extends Item { - private Icon[] icons; - private static final String[] CHARGE_NAMES = new String[] { "Fire", "Water", "Earth", "Air", "Energy" }; - - public ItemStaffPower(int id) { - super(id); - this.setHasSubtypes(true); - this.setCreativeTab(null); - maxStackSize = 64; - } - - @Override - @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int meta) { - int j = MathHelper.clamp_int(meta, 0, 5); - return icons[j]; - } - - @Override - public String getUnlocalizedName(ItemStack itemStack) { - int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, 5); - return super.getUnlocalizedName() + CHARGE_NAMES[meta]; - } - - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - icons = new Icon[CHARGE_NAMES.length]; - for (int i = 0; i < CHARGE_NAMES.length; ++i) { - icons[i] = iconRegister.registerIcon("MysticMods:Charge" + CHARGE_NAMES[i]); - } - } -} diff --git a/common/MysticWorld/Items/ItemStaffWater.java b/common/MysticWorld/Items/ItemStaffWater.java index 1f2264f..b70a8f3 100644 --- a/common/MysticWorld/Items/ItemStaffWater.java +++ b/common/MysticWorld/Items/ItemStaffWater.java @@ -6,16 +6,14 @@ import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.entity.Entity; import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; -import net.minecraft.util.EnumMovingObjectType; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; -import org.lwjgl.input.Keyboard; - public class ItemStaffWater extends ItemStaff { - public ItemStaffWater(int id) { - super(id); + public ItemStaffWater() { + super(); this.setMaxStackSize(1); this.setMaxDamage(200); this.setCreativeTab(MysticWorld.MysticWorldTab); @@ -23,12 +21,12 @@ public class ItemStaffWater extends ItemStaff { @Override public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer) { - if (Keyboard.isKeyDown(Keyboard.KEY_RSHIFT) || Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { + if (entityPlayer.isSneaking()) { MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(world, entityPlayer, true); if (movingobjectposition == null) { return itemStack; } else { - if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE) { + if (movingobjectposition.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) { int i = movingobjectposition.blockX; int j = movingobjectposition.blockY; int k = movingobjectposition.blockZ; @@ -38,7 +36,7 @@ public class ItemStaffWater extends ItemStaff { if (!entityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, itemStack)) { return itemStack; } - if (world.getBlockMaterial(i, j, k) == Material.water && world.getBlockMetadata(i, j, k) == 0) { + if (world.getBlock(i, j, k).getMaterial() == Material.water && world.getBlockMetadata(i, j, k) == 0) { world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); world.setBlockToAir(i, j, k); itemStack.damageItem(1, entityPlayer); @@ -65,10 +63,10 @@ public class ItemStaffWater extends ItemStaff { if (!entityPlayer.canPlayerEdit(i, j, k, movingobjectposition.sideHit, itemStack)) { return itemStack; } else { - int i1 = world.getBlockId(i, j, k); - if (i1 == 0) { + Block i1 = world.getBlock(i, j, k); + if (i1 == Blocks.air) { world.playSoundEffect(i + 0.5D, j + 0.5D, k + 0.5D, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F); - world.setBlock(i, j, k, Block.waterMoving.blockID); + world.setBlock(i, j, k, Blocks.flowing_water); itemStack.damageItem(1, entityPlayer); } return itemStack; @@ -78,7 +76,7 @@ public class ItemStaffWater extends ItemStaff { return itemStack; } } else { - world.playAuxSFXAtEntity((EntityPlayer) null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); + world.playAuxSFXAtEntity(null, 1009, (int) entityPlayer.posX, (int) entityPlayer.posY, (int) entityPlayer.posZ, 0); if (!world.isRemote) { world.spawnEntityInWorld(new EntityChargeWater(world, entityPlayer)); itemStack.damageItem(1, entityPlayer); @@ -89,14 +87,8 @@ public class ItemStaffWater extends ItemStaff { @Override public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) { - EntityPlayer player = (EntityPlayer) entity; - ItemStack currentItem = player.inventory.getCurrentItem(); - if (!world.isRemote) { - if (currentItem != null) { - if (currentItem.itemID == itemStack.itemID) { - MysticWorld.proxy.waterFX(world, (player.posX - 0.5D) + rand.nextDouble(), player.posY, (player.posZ - 0.5D) + rand.nextDouble(), 1.0F); - } - } + if (par5) { + MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F); } } } \ No newline at end of file diff --git a/common/MysticWorld/Items/ItemVoidShard.java b/common/MysticWorld/Items/ItemVoidShard.java index efeae6f..0dc1a5a 100644 --- a/common/MysticWorld/Items/ItemVoidShard.java +++ b/common/MysticWorld/Items/ItemVoidShard.java @@ -1,20 +1,19 @@ package mysticworld.items; -import java.util.List; - +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; import mysticworld.MysticWorld; -import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.world.World; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; + +import java.util.List; public class ItemVoidShard extends Item { - public ItemVoidShard(int id) { - super(id); + public ItemVoidShard() { + super(); this.setMaxStackSize(1); this.setCreativeTab(MysticWorld.MysticWorldTab); this.setMaxDamage(1); @@ -29,7 +28,7 @@ public class ItemVoidShard extends Item { } @Override - public boolean hasEffect(ItemStack itemStack) { + public boolean hasEffect(ItemStack itemStack, int i) { if (itemStack.stackTagCompound == null) itemStack.setTagCompound(new NBTTagCompound()); if (itemStack.stackTagCompound.hasKey("filled")) { @@ -45,7 +44,7 @@ public class ItemVoidShard extends Item { itemStack.setTagCompound(new NBTTagCompound()); int experience = entityPlayer.experienceLevel; int experienceSubtract = entityPlayer.experienceLevel - 30; - if (itemStack.stackTagCompound.getBoolean("filled") == false) { + if (!itemStack.stackTagCompound.getBoolean("filled")) { if (experience > 0 && experience <= 30) { entityPlayer.experienceLevel = 0; itemStack.stackTagCompound.setInteger("xpStored", experience); @@ -63,10 +62,4 @@ public class ItemVoidShard extends Item { } return itemStack; } - - @Override - @SideOnly(Side.CLIENT) - public void registerIcons(IconRegister iconRegister) { - itemIcon = iconRegister.registerIcon("MysticMods:ShardVoid"); - } } diff --git a/common/MysticWorld/Lib/BlockIds.java b/common/MysticWorld/Lib/BlockIds.java deleted file mode 100644 index e2b223f..0000000 --- a/common/MysticWorld/Lib/BlockIds.java +++ /dev/null @@ -1,49 +0,0 @@ -package mysticworld.lib; - -public class BlockIds { - - //Default Block IDs - public static int ORE_STONE_1_DEFAULT = 600; - - public static int BUSH_DEFAULT = 601; - public static int POISON_BUSH_DEFAULT = 602; - public static int WEAKNESS_BUSH_DEFAULT = 603; - public static int SLOWNESS_BUSH_DEFAULT = 604; - public static int HARMING_BUSH_DEFAULT = 605; - public static int WITHER_BUSH_DEFAULT = 606; - public static int HEALTH_BUSH_DEFAULT = 607; - public static int SPEED_BUSH_DEFAULT = 608; - public static int FIRE_RESISTANCE_BUSH_DEFAULT = 609; - public static int REGEN_BUSH_DEFAULT = 610; - public static int NIGHT_VISION_BUSH_DEFAULT = 611; - public static int INVISIBILITY_BUSH_DEFAULT = 612; - - public static int LIGHT_CUBE_DEFAULT = 613; - - public static int PLATFORM_DEFAULT = 614; - public static int PILLAR_DEFAULT = 615; - public static int PILLAR_INSERT_DEFAULT = 616; - - //Current Block IDs - public static int ORE_STONE_1; - - public static int BUSH; - public static int POISON_BUSH; - public static int WEAKNESS_BUSH; - public static int SLOWNESS_BUSH; - public static int HARMING_BUSH; - public static int WITHER_BUSH; - public static int HEALTH_BUSH; - public static int SPEED_BUSH; - public static int FIRE_RESISTANCE_BUSH; - public static int REGEN_BUSH; - public static int NIGHT_VISION_BUSH; - public static int INVISIBILITY_BUSH; - - public static int LIGHT_CUBE; - - public static int PLATFORM; - public static int PILLAR; - public static int PILLAR_INSERT; - -} diff --git a/common/MysticWorld/Lib/Booleans.java b/common/MysticWorld/Lib/Booleans.java index 8284535..3822330 100644 --- a/common/MysticWorld/Lib/Booleans.java +++ b/common/MysticWorld/Lib/Booleans.java @@ -2,6 +2,7 @@ package mysticworld.lib; public class Booleans { + public static boolean ENABLE_IMBUED_STONE_GEN; public static boolean ENABLE_BUSH_GEN; public static boolean ENABLE_GLACIER_GEN; public static boolean ENABLE_JUNGLE_REWRITE; diff --git a/common/MysticWorld/Lib/EntityIds.java b/common/MysticWorld/Lib/EntityIds.java deleted file mode 100644 index dac5313..0000000 --- a/common/MysticWorld/Lib/EntityIds.java +++ /dev/null @@ -1,14 +0,0 @@ -package mysticworld.lib; - -public class EntityIds { - - //Entity IDs - public static int ENTITY_AIR_CHARGE = 1; - public static int ENTITY_FIREBALL = 2; - public static int ENTITY_EARTH_CHARGE = 3; - public static int ENTITY_ENERGY_CHARGE = 4; - public static int ENTITY_WATER_CHARGE = 5; - - public static int ENTITY_PIGMAN = 6; - -} diff --git a/common/MysticWorld/Lib/ItemIds.java b/common/MysticWorld/Lib/ItemIds.java deleted file mode 100644 index 467b451..0000000 --- a/common/MysticWorld/Lib/ItemIds.java +++ /dev/null @@ -1,90 +0,0 @@ -package mysticworld.lib; - -public class ItemIds { - - //Default Item IDs - public static int STAFF_PARTS_DEFAULT = 5503; - - public static int IMBUED_SHARD_DEFAULT = 5504; - - public static int FIRE_STAFF_DEFAULT = 5505; - public static int WATER_STAFF_DEFAULT = 5506; - public static int EARTH_STAFF_DEFAULT = 5507; - public static int AIR_STAFF_DEFAULT = 5508; - public static int ENERGY_STAFF_DEFAULT = 5509; - - public static int STAFF_POWER_DEFAULT = 5510; - - public static int BUSH_FRUIT_DEFAULT = 5511; - - public static int VERDITE_HELMET_DEFAULT = 5512; - public static int VERDITE_CHESTPLATE_DEFAULT = 5513; - public static int VERDITE_LEGGINGS_DEFAULT = 5514; - public static int VERDITE_BOOTS_DEFAULT = 5515; - - public static int MITHRIL_HELMET_DEFAULT = 5516; - public static int MITHRIL_CHESTPLATE_DEFAULT = 5517; - public static int MITHRIL_LEGGINGS_DEFAULT = 5518; - public static int MITHRIL_BOOTS_DEFAULT = 5519; - - public static int ADAMANTINE_HELMET_DEFAULT = 5520; - public static int ADAMANTINE_CHESTPLATE_DEFAULT = 5521; - public static int ADAMANTINE_LEGGINGS_DEFAULT = 5522; - public static int ADAMANTINE_BOOTS_DEFAULT = 5523; - - public static int IRIDIUM_HELMET_DEFAULT = 5524; - public static int IRIDIUM_CHESTPLATE_DEFAULT = 5525; - public static int IRIDIUM_LEGGINGS_DEFAULT = 5526; - public static int IRIDIUM_BOOTS_DEFAULT = 5527; - - public static int FIRE_ORB_DEFAULT = 5528; - public static int WATER_ORB_DEFAULT = 5529; - public static int EARTH_ORB_DEFAULT = 5530; - public static int AIR_ORB_DEFAULT = 5531; - public static int ENERGY_ORB_DEFAULT = 5532; - - public static int VOID_SHARD_DEFAULT = 5533; - - //Current Item IDs - public static int STAFF_PARTS; - - public static int IMBUED_SHARD; - - public static int FIRE_STAFF; - public static int WATER_STAFF; - public static int EARTH_STAFF; - public static int AIR_STAFF; - public static int ENERGY_STAFF; - - public static int STAFF_POWER; - - public static int BUSH_FRUIT; - - public static int VERDITE_HELMET; - public static int VERDITE_CHESTPLATE; - public static int VERDITE_LEGGINGS; - public static int VERDITE_BOOTS; - - public static int MITHRIL_HELMET; - public static int MITHRIL_CHESTPLATE; - public static int MITHRIL_LEGGINGS; - public static int MITHRIL_BOOTS; - - public static int ADAMANTINE_HELMET; - public static int ADAMANTINE_CHESTPLATE; - public static int ADAMANTINE_LEGGINGS; - public static int ADAMANTINE_BOOTS; - - public static int IRIDIUM_HELMET; - public static int IRIDIUM_CHESTPLATE; - public static int IRIDIUM_LEGGINGS; - public static int IRIDIUM_BOOTS; - - public static int FIRE_ORB; - public static int WATER_ORB; - public static int EARTH_ORB; - public static int AIR_ORB; - public static int ENERGY_ORB; - - public static int VOID_SHARD; -} diff --git a/common/MysticWorld/Lib/Strings.java b/common/MysticWorld/Lib/Strings.java index e5b811a..398794f 100644 --- a/common/MysticWorld/Lib/Strings.java +++ b/common/MysticWorld/Lib/Strings.java @@ -25,10 +25,6 @@ public class Strings { public static final String PILLAR_INSERT_NAME = "pillarInsert"; //Item Names - public static final String STAFF_HILT_NAME = "staffHilt"; - public static final String STAFF_HANDLE_NAME = "staffHandle"; - public static final String STAFF_HEAD_NAME = "staffHead"; - public static final String STAFF_NAME = "staff"; public static final String IMBUED_SHARD_NAME = "imbuedShard"; @@ -38,7 +34,7 @@ public class Strings { public static final String AIR_STAFF_NAME = "airStaff"; public static final String ENERGY_STAFF_NAME = "energyStaff"; - public static final String POWER_STAFF_NAME = "staffPoweredItem"; + public static final String STAFF_PART_NAME = "staffparts"; public static final String FIRE_ORB_NAME = "fireOrb"; public static final String WATER_ORB_NAME = "waterOrb"; @@ -80,7 +76,4 @@ public class Strings { //Tile Entity Names public static final String PILLAR_INSERT_TE_NAME = "pillarInsert"; - //Config Category Names - public static final String ENTITY_CATEGORY = "entity"; - } diff --git a/common/MysticWorld/Model/ModelOrb.java b/common/MysticWorld/Model/ModelOrb.java index 9d007eb..cc4b2aa 100644 --- a/common/MysticWorld/Model/ModelOrb.java +++ b/common/MysticWorld/Model/ModelOrb.java @@ -1,14 +1,16 @@ package mysticworld.model; import net.minecraft.client.model.ModelBase; +import net.minecraft.util.ResourceLocation; import net.minecraftforge.client.model.AdvancedModelLoader; import net.minecraftforge.client.model.IModelCustom; public class ModelOrb extends ModelBase { + private static final ResourceLocation orb = new ResourceLocation("mysticworld", "models/orb.obj"); private IModelCustom modelOrb; public ModelOrb() { - modelOrb = AdvancedModelLoader.loadModel("/assets/mysticmods/models/orb.obj"); + modelOrb = AdvancedModelLoader.loadModel(orb); } public void render() { diff --git a/common/MysticWorld/Model/ModelPillarInsert.java b/common/MysticWorld/Model/ModelPillarInsert.java index 7a785d0..83d8634 100644 --- a/common/MysticWorld/Model/ModelPillarInsert.java +++ b/common/MysticWorld/Model/ModelPillarInsert.java @@ -70,10 +70,5 @@ public class ModelPillarInsert extends ModelBase model.rotateAngleY = y; model.rotateAngleZ = z; } - - public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5, Entity entity) - { - super.setRotationAngles(f, f1, f2, f3, f4, f5, entity); - } } diff --git a/common/MysticWorld/Model/ModelStaff.java b/common/MysticWorld/Model/ModelStaff.java index 15bcb18..40d253a 100644 --- a/common/MysticWorld/Model/ModelStaff.java +++ b/common/MysticWorld/Model/ModelStaff.java @@ -142,9 +142,4 @@ public class ModelStaff extends ModelBase model.rotateAngleY = y; model.rotateAngleZ = z; } - - public void setRotationAngles(float f, float f1, float f2, float f3, float f4, float f5, Entity entity) - { - super.setRotationAngles(f, f1, f2, f3, f4, f5, entity); - } } diff --git a/common/MysticWorld/MysticWorld.java b/common/MysticWorld/MysticWorld.java index aebc0cf..e3d5371 100644 --- a/common/MysticWorld/MysticWorld.java +++ b/common/MysticWorld/MysticWorld.java @@ -1,59 +1,73 @@ package mysticworld; +import cpw.mods.fml.common.FMLCommonHandler; +import cpw.mods.fml.common.Mod; +import cpw.mods.fml.common.Mod.EventHandler; +import cpw.mods.fml.common.Mod.Instance; +import cpw.mods.fml.common.SidedProxy; +import cpw.mods.fml.common.event.FMLInitializationEvent; +import cpw.mods.fml.common.event.FMLMissingMappingsEvent; +import cpw.mods.fml.common.event.FMLPreInitializationEvent; +import cpw.mods.fml.common.registry.GameData; +import cpw.mods.fml.common.registry.GameRegistry; import mysticworld.biome.BiomeHandler; import mysticworld.blocks.BlockHandler; import mysticworld.entity.EntityHandler; import mysticworld.items.ItemHandler; import mysticworld.lib.Booleans; import mysticworld.tiles.TileEntityHandler; -import mysticworld.util.CommonProxy; import mysticworld.util.Config; -import mysticworld.util.Localizations; import mysticworld.util.RecipeHandler; import mysticworld.util.Reference; -import mysticworld.util.TabMysticWorld; import mysticworld.util.TickHandler; -import mysticworld.worldgen.WorldGenBushes; -import mysticworld.worldgen.WorldGenStones; +import mysticworld.worldgen.WorldGenerators; import net.minecraft.creativetab.CreativeTabs; -import cpw.mods.fml.common.Mod; -import cpw.mods.fml.common.Mod.EventHandler; -import cpw.mods.fml.common.Mod.Instance; -import cpw.mods.fml.common.SidedProxy; -import cpw.mods.fml.common.event.FMLInitializationEvent; -import cpw.mods.fml.common.event.FMLPreInitializationEvent; -import cpw.mods.fml.common.network.NetworkMod; -import cpw.mods.fml.common.registry.GameRegistry; -import cpw.mods.fml.common.registry.TickRegistry; -import cpw.mods.fml.relauncher.Side; +import net.minecraft.item.Item; @Mod(modid = Reference.MOD_ID, name = Reference.MOD_NAME, version = Reference.VERSION_NUMBER) -@NetworkMod(clientSideRequired = true, serverSideRequired = false) -public class MysticWorld { +public final class MysticWorld { @Instance(Reference.MOD_ID) public static MysticWorld instance; @SidedProxy(clientSide = Reference.CLIENT_PROXY_CLASS, serverSide = Reference.SERVER_PROXY_CLASS) public static CommonProxy proxy; - public static final CreativeTabs MysticWorldTab = new TabMysticWorld("MysticWorldTab"); + public static CreativeTabs MysticWorldTab; + public boolean ENABLE = true; @EventHandler public void load(FMLInitializationEvent event) { - TickRegistry.registerTickHandler(new TickHandler(), Side.SERVER); - BlockHandler.init(); - ItemHandler.init(); - TileEntityHandler.init(); - if (Booleans.ENABLE_BUSH_GEN) - GameRegistry.registerWorldGenerator(new WorldGenBushes()); - GameRegistry.registerWorldGenerator(new WorldGenStones()); - EntityHandler.init(); - RecipeHandler.init(); - Localizations.Initialize(); - proxy.registerRenders(); + if(ENABLE){ + FMLCommonHandler.instance().bus().register(new TickHandler()); + if(Booleans.ENABLE_IMBUED_STONE_GEN||Booleans.ENABLE_BUSH_GEN) + GameRegistry.registerWorldGenerator(new WorldGenerators(), 100); + EntityHandler.init(); + proxy.registerRenders(); + } } @EventHandler public void preInit(FMLPreInitializationEvent event) { Config.initialize(event.getSuggestedConfigurationFile()); - BiomeHandler.init(); + if(ENABLE){ + MysticWorldTab = new CreativeTabs("MysticWorldTab") { + @Override + public Item getTabIconItem() { + return ItemHandler.earthStaff; + } + }; + BiomeHandler.init(); + BlockHandler.init(); + ItemHandler.init(); + TileEntityHandler.init(); + RecipeHandler.init(); + } } + + @EventHandler + public void onRemap(FMLMissingMappingsEvent event){ + for(FMLMissingMappingsEvent.MissingMapping missingMapping : event.get()){ + if(missingMapping.type.name().equals("ITEM") && missingMapping.name.contains("item.")){ + missingMapping.remap(GameData.getItemRegistry().getObject(missingMapping.name.replace("item.mysticworld:", "").replace("item.", ""))); + } + } + } } diff --git a/common/MysticWorld/Renderer/BlockPillarInsertRenderer.java b/common/MysticWorld/Renderer/BlockPillarInsertRenderer.java index 4f9354c..5cd11b5 100644 --- a/common/MysticWorld/Renderer/BlockPillarInsertRenderer.java +++ b/common/MysticWorld/Renderer/BlockPillarInsertRenderer.java @@ -1,16 +1,14 @@ package mysticworld.renderer; +import cpw.mods.fml.client.FMLClientHandler; import mysticworld.model.ModelPillarInsert; import net.minecraft.item.ItemStack; import net.minecraft.util.ResourceLocation; import net.minecraftforge.client.IItemRenderer; - import org.lwjgl.opengl.GL11; -import cpw.mods.fml.client.FMLClientHandler; - public class BlockPillarInsertRenderer implements IItemRenderer { - private static final ResourceLocation texture = new ResourceLocation("mysticmods:textures" + "/models/PillarInsert.png"); + private static final ResourceLocation texture = new ResourceLocation("mysticworld", "textures/models/PillarInsert.png"); private final ModelPillarInsert model; public BlockPillarInsertRenderer() { diff --git a/common/MysticWorld/Renderer/ItemOrbEarthRenderer.java b/common/MysticWorld/Renderer/ItemOrbEarthRenderer.java deleted file mode 100644 index 2a6c826..0000000 --- a/common/MysticWorld/Renderer/ItemOrbEarthRenderer.java +++ /dev/null @@ -1,82 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelOrb; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemOrbEarthRenderer implements IItemRenderer { - private ModelOrb modelOrb; - - public ItemOrbEarthRenderer() { - modelOrb = new ModelOrb(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderOrb(0.0f, 0.5f, 0.0f, 0.4f); - break; - case EQUIPPED: - renderOrb(0.5f, 1.0f, 0.5f, 0.5f); - break; - case INVENTORY: - renderOrb(0.0f, 0.0f, 0.0f, 0.5f); - break; - case EQUIPPED_FIRST_PERSON: - renderOrb(0.0f, 1.0f, 1.0f, 0.5f); - break; - default: - break; - } - } - - public void renderOrb(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glTranslatef(x, y, z); - GL11.glScalef(scale, scale, scale); - GL11.glRotatef(180f, 0f, 1f, 0f); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/OrbEarth.png")); - modelOrb.render(); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - default: - return false; - } - } -} diff --git a/common/MysticWorld/Renderer/ItemOrbEnergyRenderer.java b/common/MysticWorld/Renderer/ItemOrbEnergyRenderer.java deleted file mode 100644 index 0022f0c..0000000 --- a/common/MysticWorld/Renderer/ItemOrbEnergyRenderer.java +++ /dev/null @@ -1,82 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelOrb; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemOrbEnergyRenderer implements IItemRenderer { - private ModelOrb modelOrb; - - public ItemOrbEnergyRenderer() { - modelOrb = new ModelOrb(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderOrb(0.0f, 0.5f, 0.0f, 0.4f); - break; - case EQUIPPED: - renderOrb(0.5f, 1.0f, 0.5f, 0.5f); - break; - case INVENTORY: - renderOrb(0.0f, 0.0f, 0.0f, 0.5f); - break; - case EQUIPPED_FIRST_PERSON: - renderOrb(0.0f, 1.0f, 1.0f, 0.5f); - break; - default: - break; - } - } - - public void renderOrb(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glTranslatef(x, y, z); - GL11.glScalef(scale, scale, scale); - GL11.glRotatef(180f, 0f, 1f, 0f); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/OrbEnergy.png")); - modelOrb.render(); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - default: - return false; - } - } -} diff --git a/common/MysticWorld/Renderer/ItemOrbFireRenderer.java b/common/MysticWorld/Renderer/ItemOrbFireRenderer.java deleted file mode 100644 index 48c3adc..0000000 --- a/common/MysticWorld/Renderer/ItemOrbFireRenderer.java +++ /dev/null @@ -1,82 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelOrb; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemOrbFireRenderer implements IItemRenderer { - private ModelOrb modelOrb; - - public ItemOrbFireRenderer() { - modelOrb = new ModelOrb(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderOrb(0.0f, 0.5f, 0.0f, 0.4f); - break; - case EQUIPPED: - renderOrb(0.5f, 1.0f, 0.5f, 0.5f); - break; - case INVENTORY: - renderOrb(0.0f, 0.0f, 0.0f, 0.5f); - break; - case EQUIPPED_FIRST_PERSON: - renderOrb(0.0f, 1.0f, 1.0f, 0.5f); - break; - default: - break; - } - } - - public void renderOrb(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glTranslatef(x, y, z); - GL11.glScalef(scale, scale, scale); - GL11.glRotatef(180f, 0f, 1f, 0f); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/OrbFire.png")); - modelOrb.render(); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - default: - return false; - } - } -} diff --git a/common/MysticWorld/Renderer/ItemOrbWaterRenderer.java b/common/MysticWorld/Renderer/ItemOrbWaterRenderer.java deleted file mode 100644 index d756667..0000000 --- a/common/MysticWorld/Renderer/ItemOrbWaterRenderer.java +++ /dev/null @@ -1,82 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelOrb; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemOrbWaterRenderer implements IItemRenderer { - private ModelOrb modelOrb; - - public ItemOrbWaterRenderer() { - modelOrb = new ModelOrb(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderOrb(0.0f, 0.5f, 0.0f, 0.4f); - break; - case EQUIPPED: - renderOrb(0.5f, 1.0f, 0.5f, 0.5f); - break; - case INVENTORY: - renderOrb(0.0f, 0.0f, 0.0f, 0.5f); - break; - case EQUIPPED_FIRST_PERSON: - renderOrb(0.0f, 1.0f, 1.0f, 0.5f); - break; - default: - break; - } - } - - public void renderOrb(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glTranslatef(x, y, z); - GL11.glScalef(scale, scale, scale); - GL11.glRotatef(180f, 0f, 1f, 0f); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/OrbWater.png")); - modelOrb.render(); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - default: - return false; - } - } -} diff --git a/common/MysticWorld/Renderer/ItemStaffEarthRenderer.java b/common/MysticWorld/Renderer/ItemStaffEarthRenderer.java deleted file mode 100644 index 46f9853..0000000 --- a/common/MysticWorld/Renderer/ItemStaffEarthRenderer.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelStaff; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemStaffEarthRenderer implements IItemRenderer { - private final ModelStaff model; - - public ItemStaffEarthRenderer() { - this.model = new ModelStaff(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderModel(0.0F, 1.2F, 0.0F, 1.0F); - break; - case INVENTORY: - renderModel(0.5F, 0.95F, 0.5F, 1.0F); - break; - case EQUIPPED_FIRST_PERSON: - renderModel(1.0F, 1.2f, 0.0f, 1.0f); - break; - case EQUIPPED: - renderModelEquipped(0.0F, 0.9f, 0.0f, 1.0f); - break; - default: - break; - } - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return false; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return false; - default: - return false; - } - } - - private void renderModel(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 0.0F, 0.0F, 0.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffEarth.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - private void renderModelEquipped(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F); - GL11.glRotatef(-45.0F, 0.0F, 0.0F, 1.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffEarth.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } -} diff --git a/common/MysticWorld/Renderer/ItemStaffEnergyRenderer.java b/common/MysticWorld/Renderer/ItemStaffEnergyRenderer.java deleted file mode 100644 index c34cace..0000000 --- a/common/MysticWorld/Renderer/ItemStaffEnergyRenderer.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelStaff; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemStaffEnergyRenderer implements IItemRenderer { - private final ModelStaff model; - - public ItemStaffEnergyRenderer() { - this.model = new ModelStaff(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderModel(0.0F, 1.2F, 0.0F, 1.0F); - break; - case INVENTORY: - renderModel(0.5F, 0.95F, 0.5F, 1.0F); - break; - case EQUIPPED_FIRST_PERSON: - renderModel(1.0F, 1.2f, 0.0f, 1.0f); - break; - case EQUIPPED: - renderModelEquipped(0.0F, 0.9f, 0.0f, 1.0f); - break; - default: - break; - } - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return false; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return false; - default: - return false; - } - } - - private void renderModel(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 0.0F, 0.0F, 0.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffEnergy.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - private void renderModelEquipped(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F); - GL11.glRotatef(-45.0F, 0.0F, 0.0F, 1.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffEnergy.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } -} diff --git a/common/MysticWorld/Renderer/ItemStaffFireRenderer.java b/common/MysticWorld/Renderer/ItemStaffFireRenderer.java deleted file mode 100644 index 92a6508..0000000 --- a/common/MysticWorld/Renderer/ItemStaffFireRenderer.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelStaff; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemStaffFireRenderer implements IItemRenderer { - private final ModelStaff model; - - public ItemStaffFireRenderer() { - this.model = new ModelStaff(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderModel(0.0F, 1.2F, 0.0F, 1.0F); - break; - case INVENTORY: - renderModel(0.5F, 0.95F, 0.5F, 1.0F); - break; - case EQUIPPED_FIRST_PERSON: - renderModel(1.0F, 1.2f, 0.0f, 1.0f); - break; - case EQUIPPED: - renderModelEquipped(0.0F, 0.9f, 0.0f, 1.0f); - break; - default: - break; - } - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return false; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return false; - default: - return false; - } - } - - private void renderModel(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 0.0F, 0.0F, 0.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffFire.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - private void renderModelEquipped(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F); - GL11.glRotatef(-45.0F, 0.0F, 0.0F, 1.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffFire.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } -} diff --git a/common/MysticWorld/Renderer/ItemStaffWaterRenderer.java b/common/MysticWorld/Renderer/ItemStaffWaterRenderer.java deleted file mode 100644 index 5f14fe0..0000000 --- a/common/MysticWorld/Renderer/ItemStaffWaterRenderer.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticworld.renderer; - -import mysticworld.model.ModelStaff; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - -import org.lwjgl.opengl.GL11; - -import cpw.mods.fml.client.FMLClientHandler; - -public class ItemStaffWaterRenderer implements IItemRenderer { - private final ModelStaff model; - - public ItemStaffWaterRenderer() { - this.model = new ModelStaff(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } - } - - @Override - public void renderItem(ItemRenderType type, ItemStack item, Object... data) { - switch (type) { - case ENTITY: - renderModel(0.0F, 1.2F, 0.0F, 1.0F); - break; - case INVENTORY: - renderModel(0.5F, 0.95F, 0.5F, 1.0F); - break; - case EQUIPPED_FIRST_PERSON: - renderModel(1.0F, 1.2f, 0.0f, 1.0f); - break; - case EQUIPPED: - renderModelEquipped(0.0F, 0.9f, 0.0f, 1.0f); - break; - default: - break; - } - } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return false; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return false; - default: - return false; - } - } - - private void renderModel(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 0.0F, 0.0F, 0.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffWater.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } - - private void renderModelEquipped(float x, float y, float z, float scale) { - GL11.glPushMatrix(); - GL11.glDisable(GL11.GL_LIGHTING); - GL11.glScalef(scale, scale, scale); - GL11.glTranslatef(x, y, z); - GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F); - GL11.glRotatef(-45.0F, 0.0F, 0.0F, 1.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffWater.png")); - model.renderModel(0.0625f); - GL11.glEnable(GL11.GL_LIGHTING); - GL11.glPopMatrix(); - } -} diff --git a/common/MysticWorld/Renderer/RenderStaffPower.java b/common/MysticWorld/Renderer/RenderStaffPower.java index 9411e6c..6ea399d 100644 --- a/common/MysticWorld/Renderer/RenderStaffPower.java +++ b/common/MysticWorld/Renderer/RenderStaffPower.java @@ -1,23 +1,16 @@ package mysticworld.renderer; -import mysticworld.items.ItemHandler; import net.minecraft.client.renderer.Tessellator; import net.minecraft.client.renderer.entity.Render; -import net.minecraft.client.renderer.texture.TextureMap; import net.minecraft.entity.Entity; -import net.minecraft.item.Item; -import net.minecraft.util.Icon; import net.minecraft.util.ResourceLocation; - import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL12; public class RenderStaffPower extends Render { - private Item item; - private int meta = 0; - - public RenderStaffPower(int par1) { - this.meta = par1; + private final ResourceLocation location; + public RenderStaffPower(String type) { + location = new ResourceLocation("mysticworld","textures/items/Charge"+type+".png"); } @Override @@ -28,14 +21,9 @@ public class RenderStaffPower extends Render { public void doRenderEntity(Entity entity, double par2, double par4, double par6, float par8, float par9) { GL11.glPushMatrix(); this.bindEntityTexture(entity); - GL11.glTranslatef((float) par2, (float) par4, (float) par6); + GL11.glTranslatef((float) par2, (float) par4, (float) par6); GL11.glEnable(GL12.GL_RESCALE_NORMAL); - Icon icon = ItemHandler.staffPower.getIconFromDamage(this.meta); Tessellator tessellator = Tessellator.instance; - float f3 = icon.getMinU(); - float f4 = icon.getMaxU(); - float f5 = icon.getMinV(); - float f6 = icon.getMaxV(); float f7 = 1.0F; float f8 = 0.5F; float f9 = 0.25F; @@ -43,10 +31,10 @@ public class RenderStaffPower extends Render { GL11.glRotatef(-this.renderManager.playerViewX, 1.0F, 0.0F, 0.0F); tessellator.startDrawingQuads(); tessellator.setNormal(0.0F, 1.0F, 0.0F); - tessellator.addVertexWithUV(0.0F - f8, 0.0F - f9, 0.0D, f3, f6); - tessellator.addVertexWithUV(f7 - f8, 0.0F - f9, 0.0D, f4, f6); - tessellator.addVertexWithUV(f7 - f8, 1.0F - f9, 0.0D, f4, f5); - tessellator.addVertexWithUV(0.0F - f8, 1.0F - f9, 0.0D, f3, f5); + tessellator.addVertexWithUV(0.0F - f8, 0.0F - f9, 0.0D, 0, 1); + tessellator.addVertexWithUV(f7 - f8, 0.0F - f9, 0.0D, 1, 1); + tessellator.addVertexWithUV(f7 - f8, 1.0F - f9, 0.0D, 1, 0); + tessellator.addVertexWithUV(0.0F - f8, 1.0F - f9, 0.0D, 0, 0); tessellator.draw(); GL11.glDisable(GL12.GL_RESCALE_NORMAL); GL11.glPopMatrix(); @@ -54,6 +42,6 @@ public class RenderStaffPower extends Render { @Override protected ResourceLocation getEntityTexture(Entity par1Entity) { - return TextureMap.locationItemsTexture; + return location; } } diff --git a/common/MysticWorld/Renderer/TileEntityPillarInsertRenderer.java b/common/MysticWorld/Renderer/TileEntityPillarInsertRenderer.java index b6046b6..622c203 100644 --- a/common/MysticWorld/Renderer/TileEntityPillarInsertRenderer.java +++ b/common/MysticWorld/Renderer/TileEntityPillarInsertRenderer.java @@ -1,17 +1,15 @@ package mysticworld.renderer; +import cpw.mods.fml.client.FMLClientHandler; import mysticworld.model.ModelPillarInsert; import mysticworld.tiles.TileEntityPillarInsert; import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer; import net.minecraft.tileentity.TileEntity; import net.minecraft.util.ResourceLocation; - import org.lwjgl.opengl.GL11; -import cpw.mods.fml.client.FMLClientHandler; - public class TileEntityPillarInsertRenderer extends TileEntitySpecialRenderer { - private static final ResourceLocation texture = new ResourceLocation("mysticmods:textures" + "/models/PillarInsert.png"); + private static final ResourceLocation texture = new ResourceLocation("mysticworld", "textures/models/PillarInsert.png"); private ModelPillarInsert model; public TileEntityPillarInsertRenderer() { diff --git a/common/MysticWorld/Util/Config.java b/common/MysticWorld/Util/Config.java index be78ca3..bce6fcd 100644 --- a/common/MysticWorld/Util/Config.java +++ b/common/MysticWorld/Util/Config.java @@ -1,64 +1,23 @@ package mysticworld.util; +import mysticworld.MysticWorld; +import mysticworld.lib.Booleans; +import net.minecraftforge.common.config.Configuration; + import java.io.File; -import mysticworld.lib.BlockIds; -import mysticworld.lib.Booleans; -import mysticworld.lib.ItemIds; -import mysticworld.lib.Strings; -import net.minecraftforge.common.Configuration; - public class Config { - public static Configuration config; - public static void initialize(File file) { - config = new Configuration(file); + Configuration config = new Configuration(file); + MysticWorld.instance.ENABLE = config.get("General", "Enable", true).getBoolean(); //Boolean Configurations - Booleans.ENABLE_BUSH_GEN = config.get("World Generation", "Enable Bush Generation", true).getBoolean(Booleans.ENABLE_BUSH_GEN); - Booleans.ENABLE_GLACIER_GEN = config.get("World Generation", "Enable Glacier Biome", true).getBoolean(Booleans.ENABLE_GLACIER_GEN); - Booleans.ENABLE_JUNGLE_REWRITE = config.get("World Generation", "Enable Vanilla Jungle Biome Modification", true).getBoolean(Booleans.ENABLE_JUNGLE_REWRITE); - Booleans.ENABLE_MOUNTAIN_GEN = config.get("World Generation", "Enable Mountain Biome", true).getBoolean(Booleans.ENABLE_MOUNTAIN_GEN); - Booleans.ENABLE_STEPPE_GEN = config.get("World Generation", "Enable Steppe Biome", true).getBoolean(Booleans.ENABLE_STEPPE_GEN); - Booleans.ENABLE_TUNDRA_GEN = config.get("World Generation", "Enable Tundra Biome", true).getBoolean(Booleans.ENABLE_TUNDRA_GEN); - //Block Configuration - BlockIds.ORE_STONE_1 = config.getBlock(Strings.IMBUED_STONE_NAME, BlockIds.ORE_STONE_1_DEFAULT).getInt(BlockIds.ORE_STONE_1); - BlockIds.BUSH = config.getBlock(Strings.BUSH_NAME, BlockIds.BUSH_DEFAULT).getInt(BlockIds.BUSH_DEFAULT); - BlockIds.LIGHT_CUBE = config.getBlock(Strings.LIGHT_CUBE_NAME, BlockIds.LIGHT_CUBE_DEFAULT).getInt(BlockIds.LIGHT_CUBE_DEFAULT); - BlockIds.PLATFORM = config.getBlock(Strings.PLATFORM_NAME, BlockIds.PLATFORM_DEFAULT).getInt(BlockIds.PLATFORM_DEFAULT); - BlockIds.PILLAR = config.getBlock(Strings.PILLAR_NAME, BlockIds.PILLAR_DEFAULT).getInt(BlockIds.PILLAR_DEFAULT); - BlockIds.PILLAR_INSERT = config.getBlock(Strings.PILLAR_INSERT_NAME, BlockIds.PILLAR_INSERT_DEFAULT).getInt(BlockIds.PILLAR_INSERT_DEFAULT); - //Item Configuration - ItemIds.IMBUED_SHARD = config.getItem(Strings.IMBUED_SHARD_NAME, ItemIds.IMBUED_SHARD_DEFAULT).getInt(ItemIds.IMBUED_SHARD_DEFAULT); - ItemIds.STAFF_PARTS = config.getItem(Strings.STAFF_NAME, ItemIds.STAFF_PARTS_DEFAULT).getInt(ItemIds.STAFF_PARTS_DEFAULT); - ItemIds.FIRE_STAFF = config.getItem(Strings.FIRE_STAFF_NAME, ItemIds.FIRE_STAFF_DEFAULT).getInt(ItemIds.FIRE_STAFF_DEFAULT); - ItemIds.WATER_STAFF = config.getItem(Strings.WATER_STAFF_NAME, ItemIds.WATER_STAFF_DEFAULT).getInt(ItemIds.WATER_STAFF_DEFAULT); - ItemIds.EARTH_STAFF = config.getItem(Strings.EARTH_STAFF_NAME, ItemIds.EARTH_STAFF_DEFAULT).getInt(ItemIds.EARTH_STAFF_DEFAULT); - ItemIds.AIR_STAFF = config.getItem(Strings.AIR_STAFF_NAME, ItemIds.AIR_STAFF_DEFAULT).getInt(ItemIds.AIR_STAFF_DEFAULT); - ItemIds.ENERGY_STAFF = config.getItem(Strings.ENERGY_STAFF_NAME, ItemIds.ENERGY_STAFF_DEFAULT).getInt(ItemIds.ENERGY_STAFF_DEFAULT); - ItemIds.STAFF_POWER = config.getItem(Strings.POWER_STAFF_NAME, ItemIds.STAFF_POWER_DEFAULT).getInt(ItemIds.STAFF_POWER_DEFAULT); - ItemIds.BUSH_FRUIT = config.getItem(Strings.BUSH_FRUIT_NAME, ItemIds.BUSH_FRUIT_DEFAULT).getInt(ItemIds.BUSH_FRUIT_DEFAULT); - ItemIds.VERDITE_HELMET = config.getItem(Strings.VERDITE_HELMET_NAME, ItemIds.VERDITE_HELMET_DEFAULT).getInt(ItemIds.VERDITE_HELMET_DEFAULT); - ItemIds.VERDITE_CHESTPLATE = config.getItem(Strings.VERDITE_CHESTPLATE_NAME, ItemIds.VERDITE_CHESTPLATE_DEFAULT).getInt(ItemIds.VERDITE_CHESTPLATE_DEFAULT); - ItemIds.VERDITE_LEGGINGS = config.getItem(Strings.VERDITE_LEGGINGS_NAME, ItemIds.VERDITE_LEGGINGS_DEFAULT).getInt(ItemIds.VERDITE_LEGGINGS_DEFAULT); - ItemIds.VERDITE_BOOTS = config.getItem(Strings.VERDITE_BOOTS_NAME, ItemIds.VERDITE_BOOTS_DEFAULT).getInt(ItemIds.VERDITE_BOOTS_DEFAULT); - ItemIds.MITHRIL_HELMET = config.getItem(Strings.MITHRIL_HELMET_NAME, ItemIds.MITHRIL_HELMET_DEFAULT).getInt(ItemIds.MITHRIL_HELMET_DEFAULT); - ItemIds.MITHRIL_CHESTPLATE = config.getItem(Strings.MITHRIL_CHESTPLATE_NAME, ItemIds.MITHRIL_CHESTPLATE_DEFAULT).getInt(ItemIds.MITHRIL_CHESTPLATE_DEFAULT); - ItemIds.MITHRIL_LEGGINGS = config.getItem(Strings.MITHRIL_LEGGINGS_NAME, ItemIds.MITHRIL_LEGGINGS_DEFAULT).getInt(ItemIds.MITHRIL_LEGGINGS_DEFAULT); - ItemIds.MITHRIL_BOOTS = config.getItem(Strings.MITHRIL_BOOTS_NAME, ItemIds.MITHRIL_BOOTS_DEFAULT).getInt(ItemIds.MITHRIL_BOOTS_DEFAULT); - ItemIds.ADAMANTINE_HELMET = config.getItem(Strings.ADAMANTINE_HELMET_NAME, ItemIds.ADAMANTINE_HELMET_DEFAULT).getInt(ItemIds.ADAMANTINE_HELMET_DEFAULT); - ItemIds.ADAMANTINE_CHESTPLATE = config.getItem(Strings.ADAMANTINE_CHESTPLATE_NAME, ItemIds.ADAMANTINE_CHESTPLATE_DEFAULT).getInt(ItemIds.ADAMANTINE_CHESTPLATE_DEFAULT); - ItemIds.ADAMANTINE_LEGGINGS = config.getItem(Strings.ADAMANTINE_LEGGINGS_NAME, ItemIds.ADAMANTINE_LEGGINGS_DEFAULT).getInt(ItemIds.ADAMANTINE_LEGGINGS_DEFAULT); - ItemIds.ADAMANTINE_BOOTS = config.getItem(Strings.ADAMANTINE_BOOTS_NAME, ItemIds.ADAMANTINE_BOOTS_DEFAULT).getInt(ItemIds.ADAMANTINE_BOOTS_DEFAULT); - ItemIds.IRIDIUM_HELMET = config.getItem(Strings.IRIDIUM_HELMET_NAME, ItemIds.IRIDIUM_HELMET_DEFAULT).getInt(ItemIds.IRIDIUM_HELMET_DEFAULT); - ItemIds.IRIDIUM_CHESTPLATE = config.getItem(Strings.IRIDIUM_CHESTPLATE_NAME, ItemIds.IRIDIUM_CHESTPLATE_DEFAULT).getInt(ItemIds.IRIDIUM_CHESTPLATE_DEFAULT); - ItemIds.IRIDIUM_LEGGINGS = config.getItem(Strings.IRIDIUM_LEGGINGS_NAME, ItemIds.IRIDIUM_LEGGINGS_DEFAULT).getInt(ItemIds.IRIDIUM_LEGGINGS_DEFAULT); - ItemIds.IRIDIUM_BOOTS = config.getItem(Strings.IRIDIUM_BOOTS_NAME, ItemIds.IRIDIUM_BOOTS_DEFAULT).getInt(ItemIds.IRIDIUM_BOOTS_DEFAULT); - ItemIds.FIRE_ORB = config.getItem(Strings.FIRE_ORB_NAME, ItemIds.FIRE_ORB_DEFAULT).getInt(ItemIds.FIRE_ORB_DEFAULT); - ItemIds.WATER_ORB = config.getItem(Strings.WATER_ORB_NAME, ItemIds.WATER_ORB_DEFAULT).getInt(ItemIds.WATER_ORB_DEFAULT); - ItemIds.EARTH_ORB = config.getItem(Strings.EARTH_ORB_NAME, ItemIds.EARTH_ORB_DEFAULT).getInt(ItemIds.EARTH_ORB_DEFAULT); - ItemIds.AIR_ORB = config.getItem(Strings.AIR_ORB_NAME, ItemIds.AIR_ORB_DEFAULT).getInt(ItemIds.AIR_ORB_DEFAULT); - ItemIds.ENERGY_ORB = config.getItem(Strings.ENERGY_ORB_NAME, ItemIds.ENERGY_ORB_DEFAULT).getInt(ItemIds.ENERGY_ORB_DEFAULT); - ItemIds.VOID_SHARD = config.getItem(Strings.VOID_SHARD_NAME, ItemIds.VOID_SHARD_DEFAULT).getInt(ItemIds.VOID_SHARD_DEFAULT); + Booleans.ENABLE_IMBUED_STONE_GEN = config.get("World Generation", "Enable Imbued Stones Generation", true).getBoolean(); + Booleans.ENABLE_BUSH_GEN = config.get("World Generation", "Enable Bush Generation", true).getBoolean(); + Booleans.ENABLE_GLACIER_GEN = config.get("World Generation", "Enable Glacier Biome", true).getBoolean(); + Booleans.ENABLE_JUNGLE_REWRITE = config.get("World Generation", "Enable Vanilla Jungle Biome Modification", true).getBoolean(); + Booleans.ENABLE_MOUNTAIN_GEN = config.get("World Generation", "Enable Mountain Biome", true).getBoolean(); + Booleans.ENABLE_STEPPE_GEN = config.get("World Generation", "Enable Steppe Biome", true).getBoolean(); + Booleans.ENABLE_TUNDRA_GEN = config.get("World Generation", "Enable Tundra Biome", true).getBoolean(); config.save(); } } \ No newline at end of file diff --git a/common/MysticWorld/Util/Localizations.java b/common/MysticWorld/Util/Localizations.java deleted file mode 100644 index dc22b20..0000000 --- a/common/MysticWorld/Util/Localizations.java +++ /dev/null @@ -1,95 +0,0 @@ -package mysticworld.util; - -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Enumeration; -import java.util.regex.Matcher; -import java.util.regex.Pattern; -import java.util.zip.ZipEntry; -import java.util.zip.ZipException; -import java.util.zip.ZipFile; - -import mysticworld.MysticWorld; -import cpw.mods.fml.common.Loader; -import cpw.mods.fml.common.registry.LanguageRegistry; - -/* - * - * All credits go to copygirl (or copy....boy) for this one - * Couldn't have done any of this without your - * repository, many thanks friend c: - * - */ -public class Localizations { - private Localizations() { - } - - public static void Initialize() { - File source = Loader.instance().getReversedModObjectList().get(MysticWorld.instance).getSource(); - Pattern pattern = Pattern.compile(".*(assets/" + "mysticmods/lang/(.+)\\.(.+))"); - for (String file : getResources(source, pattern)) { - Matcher matcher = pattern.matcher(file); - matcher.find(); - String resource = "/" + matcher.group(1); - String lang = matcher.group(2); - boolean isXML = matcher.group(3).equalsIgnoreCase("XML"); - LanguageRegistry.instance().loadLocalization(resource, lang, isXML); - } - } - - private static Collection getResources(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - if (file.isDirectory()) - retval.addAll(getResourcesFromDirectory(file, pattern)); - else - retval.addAll(getResourcesFromJarFile(file, pattern)); - return retval; - } - - private static Collection getResourcesFromDirectory(File directory, Pattern pattern) { - ArrayList retval = new ArrayList(); - File[] FileList = directory.listFiles(); - for (File file : FileList) { - if (file.isDirectory()) { - retval.addAll(getResourcesFromDirectory(file, pattern)); - } else - try { - String fileName = file.getCanonicalPath().replace('\\', '/'); - boolean accept = pattern.matcher(fileName).matches(); - if (accept) - retval.add(fileName); - } catch (final IOException e) { - throw new Error(e); - } - } - return retval; - } - - private static Collection getResourcesFromJarFile(File file, Pattern pattern) { - ArrayList retval = new ArrayList(); - ZipFile Zip; - try { - Zip = new ZipFile(file); - } catch (ZipException Ex) { - throw new Error(Ex); - } catch (IOException Ex) { - throw new Error(Ex); - } - Enumeration entries = Zip.entries(); - while (entries.hasMoreElements()) { - ZipEntry ZipE = entries.nextElement(); - String FileName = ZipE.getName(); - boolean accept = pattern.matcher(FileName).matches(); - if (accept) - retval.add(FileName); - } - try { - Zip.close(); - } catch (IOException Ex) { - throw new Error(Ex); - } - return retval; - } -} diff --git a/common/MysticWorld/Util/RecipeHandler.java b/common/MysticWorld/Util/RecipeHandler.java index c1d64ba..0ff0a05 100644 --- a/common/MysticWorld/Util/RecipeHandler.java +++ b/common/MysticWorld/Util/RecipeHandler.java @@ -1,10 +1,10 @@ package mysticworld.util; +import cpw.mods.fml.common.registry.GameRegistry; import mysticores.items.Items; import mysticworld.items.ItemHandler; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import cpw.mods.fml.common.registry.GameRegistry; public class RecipeHandler { public static void init() { @@ -13,27 +13,27 @@ public class RecipeHandler { } private static void bootsRecipe(Item output, ItemStack input) { - GameRegistry.addRecipe(new ItemStack(output), new Object[] { "# #", "# #", '#', input }); + GameRegistry.addRecipe(new ItemStack(output), "# #", "# #", '#', input); } private static void chestplateRecipe(Item output, ItemStack input) { - GameRegistry.addRecipe(new ItemStack(output), new Object[] { "# #", "###", "###", '#', input }); + GameRegistry.addRecipe(new ItemStack(output), "# #", "###", "###", '#', input); } private static void helmetRecipe(Item output, ItemStack input) { - GameRegistry.addRecipe(new ItemStack(output), new Object[] { "###", "# #", '#', input }); + GameRegistry.addRecipe(new ItemStack(output), "###", "# #", '#', input); } private static void itemRecipes() { //Staff Hilt Recipe - GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 1), new Object[] { " # ", "#$#", " # ", '#', Item.ingotGold, '$', Item.diamond }); + GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 1), " # ", "#$#", " # ", '#', net.minecraft.init.Items.gold_ingot, '$', net.minecraft.init.Items.diamond); //Staff Handle Recipe - GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 2), new Object[] { "#", "$", "S", '#', Item.goldNugget, '$', Item.stick, 'S', Item.dyePowder }); + GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 2), "#", "$", "S", '#', net.minecraft.init.Items.gold_nugget, '$', net.minecraft.init.Items.stick, 'S', net.minecraft.init.Items.dye); //Staff Topper Recipe - GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 3), new Object[] { " # ", "#$#", " # ", '#', Item.ingotGold, '$', Item.netherStar }); + GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 3), " # ", "#$#", " # ", '#', net.minecraft.init.Items.gold_ingot, '$', net.minecraft.init.Items.nether_star); //Staff Recipe - GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 0), new Object[] { " #", " X ", "Y ", '#', new ItemStack(ItemHandler.staffParts, 1, 3), 'X', - new ItemStack(ItemHandler.staffParts, 1, 2), 'Y', new ItemStack(ItemHandler.staffParts, 1, 1) }); + GameRegistry.addRecipe(new ItemStack(ItemHandler.staffParts, 1, 0), " #", " X ", "Y ", '#', new ItemStack(ItemHandler.staffParts, 1, 3), 'X', + new ItemStack(ItemHandler.staffParts, 1, 2), 'Y', new ItemStack(ItemHandler.staffParts, 1, 1)); //Orb Recipes orbRecipe(ItemHandler.fireOrb, new ItemStack(ItemHandler.imbuedShard, 1, 0)); orbRecipe(ItemHandler.waterOrb, new ItemStack(ItemHandler.imbuedShard, 1, 1)); @@ -69,15 +69,15 @@ public class RecipeHandler { } private static void itemSmelting() { - GameRegistry.addSmelting(ItemHandler.imbuedShard.itemID, new ItemStack(ItemHandler.voidShard), 0.5f); + GameRegistry.addSmelting(ItemHandler.imbuedShard, new ItemStack(ItemHandler.voidShard), 0.5f); } private static void leggingsRecipe(Item output, ItemStack input) { - GameRegistry.addRecipe(new ItemStack(output), new Object[] { "###", "# #", "# #", '#', input }); + GameRegistry.addRecipe(new ItemStack(output), "###", "# #", "# #", '#', input); } private static void orbRecipe(Item output, ItemStack input) { - GameRegistry.addRecipe(new ItemStack(output), new Object[] { "##", "##", '#', input }); + GameRegistry.addRecipe(new ItemStack(output), "##", "##", '#', input); } private static void staffRecipe(Item output, ItemStack input) { diff --git a/common/MysticWorld/Util/Reference.java b/common/MysticWorld/Util/Reference.java index 152a097..429f264 100644 --- a/common/MysticWorld/Util/Reference.java +++ b/common/MysticWorld/Util/Reference.java @@ -1,7 +1,7 @@ package mysticworld.util; public class Reference { - public static final String MOD_ID = "MysticWorld"; + public static final String MOD_ID = "mysticworld"; public static final String MOD_NAME = "Mystic World"; public static final String VERSION_NUMBER = "0.1a"; public static final String SERVER_PROXY_CLASS = "mysticworld.CommonProxy"; diff --git a/common/MysticWorld/Util/TabMysticWorld.java b/common/MysticWorld/Util/TabMysticWorld.java deleted file mode 100644 index c9c0e71..0000000 --- a/common/MysticWorld/Util/TabMysticWorld.java +++ /dev/null @@ -1,16 +0,0 @@ -package mysticworld.util; - -import mysticworld.items.ItemHandler; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.ItemStack; - -public class TabMysticWorld extends CreativeTabs { - public TabMysticWorld(String par2Str) { - super(par2Str); - } - - @Override - public ItemStack getIconItemStack() { - return new ItemStack(ItemHandler.earthStaff, 1); - } -} \ No newline at end of file diff --git a/common/MysticWorld/Util/TickHandler.java b/common/MysticWorld/Util/TickHandler.java index a0810b3..17413b6 100644 --- a/common/MysticWorld/Util/TickHandler.java +++ b/common/MysticWorld/Util/TickHandler.java @@ -1,68 +1,36 @@ package mysticworld.util; -import java.util.EnumSet; -import java.util.Random; - +import cpw.mods.fml.common.eventhandler.SubscribeEvent; +import cpw.mods.fml.common.gameevent.TickEvent; import mysticworld.blocks.BlockHandler; +import net.minecraft.block.Block; import net.minecraft.enchantment.Enchantment; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.item.Item; +import net.minecraft.init.Items; import net.minecraft.item.ItemStack; import net.minecraft.potion.Potion; import net.minecraft.potion.PotionEffect; import net.minecraft.world.World; -import cpw.mods.fml.common.IScheduledTickHandler; -import cpw.mods.fml.common.TickType; -public class TickHandler implements IScheduledTickHandler { - private EnumSet ticks; +import java.util.Random; + +public class TickHandler { public static final Enchantment[] enchantmentsPick = { Enchantment.efficiency, Enchantment.fortune, Enchantment.silkTouch, Enchantment.unbreaking }; - public TickHandler() { - this.ticks = EnumSet.of(TickType.PLAYER); + @SubscribeEvent + public void tickStart(TickEvent.PlayerTickEvent event) { + if(event.phase == TickEvent.Phase.START && event.side.isServer() && event.player.worldObj.getWorldTime()%20==0) + pillarTick(event.player, event.player.worldObj, event.player.getRNG()); } - @Override - public String getLabel() { - return "mystic world tick"; - } - - @Override - public int nextTickSpacing() { - return 20; - } - - @Override - public void tickEnd(EnumSet type, Object... tickData) { - EntityPlayer player = (EntityPlayer) tickData[0]; - World world = player.worldObj; - InventoryPlayer inventory = player.inventory; - } - - @Override - public EnumSet ticks() { - return this.ticks; - } - - @Override - public void tickStart(EnumSet type, Object... tickData) { - Random rand = new Random(); - EntityPlayer player = (EntityPlayer) tickData[0]; - World world = player.worldObj; - InventoryPlayer inventory = player.inventory; - ItemStack itemstack = inventory.getCurrentItem(); - pillarTick(player, world, inventory, rand); - } - - private static void pillarTick(EntityPlayer player, World world, InventoryPlayer inventory, Random rand) { - ItemStack itemStack = inventory.getCurrentItem(); + private static void pillarTick(EntityPlayer player, World world, Random rand) { + ItemStack itemStack = player.inventory.getCurrentItem(); int blockX = (int) player.posX - 1; int blockY = (int) (player.posY - 0.15D); int blockZ = (int) player.posZ - 1; - int blockId = world.getBlockId(blockX, blockY, blockZ); + Block blockId = world.getBlock(blockX, blockY, blockZ); int blockMeta = world.getBlockMetadata(blockX, blockY, blockZ); - if (blockId == BlockHandler.pillarPlatform.blockID) { + if (blockId == BlockHandler.pillarPlatform) { switch (blockMeta) { //food case 0: @@ -97,9 +65,9 @@ public class TickHandler implements IScheduledTickHandler { //enchanter case 7: if (itemStack != null - && (itemStack.itemID == Item.pickaxeWood.itemID || itemStack.itemID == Item.pickaxeStone.itemID || itemStack.itemID == Item.pickaxeIron.itemID - || itemStack.itemID == Item.pickaxeGold.itemID || itemStack.itemID == Item.pickaxeDiamond.itemID)) { - if (itemStack.isItemEnchanted() != true && player.experienceLevel >= 10) { + && (itemStack.getItem() == Items.wooden_pickaxe || itemStack.getItem() == Items.stone_pickaxe || itemStack.getItem() == Items.iron_pickaxe + || itemStack.getItem() == Items.golden_pickaxe || itemStack.getItem() == Items.diamond_pickaxe)) { + if (!itemStack.isItemEnchanted() && player.experienceLevel >= 10) { player.experienceLevel -= 10; itemStack.addEnchantment(enchantmentsPick[rand.nextInt(3)], rand.nextInt(4) + 1); } diff --git a/common/MysticWorld/WorldGen/BushesGen.java b/common/MysticWorld/WorldGen/BushesGen.java index baecf4a..79ad6f1 100644 --- a/common/MysticWorld/WorldGen/BushesGen.java +++ b/common/MysticWorld/WorldGen/BushesGen.java @@ -1,12 +1,12 @@ package mysticworld.worldgen; -import java.util.Random; - import mysticworld.blocks.BlockHandler; -import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.world.World; import net.minecraft.world.gen.feature.WorldGenerator; +import java.util.Random; + public class BushesGen extends WorldGenerator { @Override public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) { @@ -15,8 +15,8 @@ public class BushesGen extends WorldGenerator { int i1 = par3 + par2Random.nextInt(8) - par2Random.nextInt(8); int j1 = par4 + par2Random.nextInt(4) - par2Random.nextInt(4); int k1 = par5 + par2Random.nextInt(8) - par2Random.nextInt(8); - if (par1World.isAirBlock(i1, j1, k1) && par1World.getBlockId(i1, j1 - 1, k1) == Block.grass.blockID && BlockHandler.bush.canPlaceBlockAt(par1World, i1, j1, k1)) { - par1World.setBlock(i1, j1, k1, BlockHandler.bush.blockID, bushType, 2); + if (par1World.isAirBlock(i1, j1, k1) && par1World.getBlock(i1, j1 - 1, k1) == Blocks.grass && BlockHandler.bush.canPlaceBlockAt(par1World, i1, j1, k1)) { + par1World.setBlock(i1, j1, k1, BlockHandler.bush, bushType, 2); } } return true; diff --git a/common/MysticWorld/WorldGen/StonesGen.java b/common/MysticWorld/WorldGen/StonesGen.java index 5a31bff..528b78a 100644 --- a/common/MysticWorld/WorldGen/StonesGen.java +++ b/common/MysticWorld/WorldGen/StonesGen.java @@ -1,23 +1,18 @@ package mysticworld.worldgen; -import java.util.Random; - import mysticworld.blocks.BlockHandler; -import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.world.World; import net.minecraft.world.gen.feature.WorldGenerator; +import java.util.Random; + public class StonesGen extends WorldGenerator { @Override - public boolean generate(World par1World, Random par2Random, int par3, int par4, int par5) { - for (int l = 0; l < 1; ++l) { - int i1 = par3 + par2Random.nextInt(8) - par2Random.nextInt(8); - int j1 = par4 + par2Random.nextInt(4) - par2Random.nextInt(4); - int k1 = par5 + par2Random.nextInt(8) - par2Random.nextInt(8); - if (par1World.isAirBlock(i1, j1, k1) && par1World.getBlockId(i1, j1 - 1, k1) == Block.grass.blockID && BlockHandler.oreImbuedStone.canPlaceBlockAt(par1World, i1, j1, k1)) { - par1World.setBlock(i1, j1, k1, BlockHandler.oreImbuedStone.blockID, par2Random.nextInt(5), 2); - } - } + public boolean generate(World par1World, Random par2Random, int i1, int j1, int k1) { + if (par1World.isAirBlock(i1, j1, k1) && par1World.getBlock(i1, j1 - 1, k1) == Blocks.grass && BlockHandler.oreImbuedStone.canPlaceBlockAt(par1World, i1, j1, k1)) { + par1World.setBlock(i1, j1, k1, BlockHandler.oreImbuedStone, par2Random.nextInt(5), 2); + } return true; } } diff --git a/common/MysticWorld/WorldGen/WorldGenBushes.java b/common/MysticWorld/WorldGen/WorldGenBushes.java deleted file mode 100644 index ef9d6a6..0000000 --- a/common/MysticWorld/WorldGen/WorldGenBushes.java +++ /dev/null @@ -1,30 +0,0 @@ -package mysticworld.worldgen; - -import java.util.Random; - -import net.minecraft.world.World; -import net.minecraft.world.chunk.IChunkProvider; -import net.minecraft.world.gen.feature.WorldGenerator; - -import cpw.mods.fml.common.IWorldGenerator; - -public class WorldGenBushes implements IWorldGenerator { - public static final WorldGenerator bushes = new BushesGen(); - - @Override - public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { - switch (world.provider.dimensionId) { - case 0: - generateSurface(world, random, chunkX * 16, chunkZ * 16); - } - } - - private void generateSurface(World world, Random random, int blockX, int blockZ) { - for (int i = 0; i < 1; i++) { - int Xcoord1 = blockX + random.nextInt(16) + 8; - int Ycoord1 = random.nextInt(11) + 60; - int Zcoord1 = blockZ + random.nextInt(16) + 8; - bushes.generate(world, random, Xcoord1, Ycoord1, Zcoord1); - } - } -} \ No newline at end of file diff --git a/common/MysticWorld/WorldGen/WorldGenStones.java b/common/MysticWorld/WorldGen/WorldGenStones.java deleted file mode 100644 index 6bc68cc..0000000 --- a/common/MysticWorld/WorldGen/WorldGenStones.java +++ /dev/null @@ -1,30 +0,0 @@ -package mysticworld.worldgen; - -import java.util.Random; - -import net.minecraft.world.World; -import net.minecraft.world.chunk.IChunkProvider; -import net.minecraft.world.gen.feature.WorldGenerator; - -import cpw.mods.fml.common.IWorldGenerator; - -public class WorldGenStones implements IWorldGenerator { - public static final WorldGenerator stones = new StonesGen(); - - @Override - public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { - switch (world.provider.dimensionId) { - case 0: - generateSurface(world, random, chunkX * 16, chunkZ * 16); - } - } - - private void generateSurface(World world, Random random, int blockX, int blockZ) { - for (int i = 0; i < 1; i++) { - int Xcoord1 = blockX + random.nextInt(16) + 8; - int Ycoord1 = random.nextInt(11) + 60; - int Zcoord1 = blockZ + random.nextInt(16) + 8; - stones.generate(world, random, Xcoord1, Ycoord1, Zcoord1); - } - } -} \ No newline at end of file diff --git a/common/assets/mysticmods/lang/de_DE.xml b/common/assets/mysticmods/lang/de_DE.xml deleted file mode 100644 index 197d699..0000000 --- a/common/assets/mysticmods/lang/de_DE.xml +++ /dev/null @@ -1,190 +0,0 @@ - - - - German (de_DE) Localization File - - Verditschwert - Verditspitzhacke - Verditschaufel - Verditaxt - Verdithacke - - Mithrilschwert - Mithrilspitzhacke - Mithrilschaufel - Mithrilaxt - Mithrilhacke - - Adamantines Schwert - Adamantine Spitzhacke - Adamantine Schaufel - Adamantine Axt - Adamantine Hacke - - Iridiumschwert - Iridiumspitzhacke - Iridiumschaufel - Iridiumaxt - Iridiumhacke - - Obsidianschwert - Obsidianspitzhacke - Obsidianschaufel - Obsidianaxt - Obsidianhacke - - Blutsteinschwert - Blutsteinspitzhacke - Blutsteinschaufel - Blutsteinaxt - Blutsteinhacke - - Verditbarren - Mithrilbarren - Adamantiner Barren - Iridiumbarren - Iridiumnugget - Turmalin - Achat - Topas - Amethyst - Mystisches Pulver - Blutsteinscherbe - Glasscherbe - Obsidianscherbe - Obsidianstab - Magischer Beutel - - Adamantines Erz - Amethysterz - Iridiumerz - Mithrilerz - Turmalinerz - Topaserz - Verditerz - Blutstein - Schwarzer Seelenstein - Blauer Seelenstein - Roter Seelenstein - Achaterz - Gehärtetes Glas - - Mystic Ores - - Violette Planken - Grüne Planken - Schwarze Planken - Orange Planken - Rote Planken - Blaue Planken - Gelbe Planken - - Glattes Anorthosit - Glatter Kalkstein - Glatter Schiefer - Glattes Migmatit - Glattes Orthogneis - Glatter Marmor - Glattes Travertin - - Anorthosit - Kalkstein - Schiefer - Migmatit - Orthogneis - Marmor - Travertin - - Anorthositziegel - Kalksteinziegel - Schieferziegel - Migmatitziegel - Orthogneisziegel - Marmorziegel - Travertinziegel - - Verdit-verstärkte Ziegel - Mithril-verstärkte Ziegel - Adamantine Verstärkte Ziegel - Iridium-verstärkte Ziegel - Topas-verstärkte Ziegel - Turmalin-verstärkte Ziegel - Amethyst-verstärkte Ziegel - Achat-verstärkte Ziegel - - Mystic Stones - - Magmatischer Felsbrocken - Aquatischer Felsbrocken - Fruchtbarer Felsbrocken - Durchlüfteter Felsbrocken - Kinetischer Felsbrocken - - Gewöhnlicher Busch - Giftiger Busch - Schwächender Busch - Langsamkeitsbusch - Schadender Busch - Verzehrender Busch - Heilender Busch - Geschwindigkeitsbusch - Löschender Busch - Regenerationsbusch - Nachtsichtbusch - Unsichtbarkeitsbusch - - Säulenplattform - Säulenturm - Säuleneinlage - - Stab - Stabheft - Stabgriff - Stabspitze - - Magmatische Scherbe - Aquatische Scherbe - Fruchtbare Scherbe - Durchlüftete Scherbe - Kinetische Scherbe - - Magmastab - Aquastab - Fruchtbarer Stab - Durchlüftungsstab - Kinesisstab - - Mysteriöse Frucht - - Verdithelm - Verditbrustplatte - Verditehose - Verditestiefel - - Mithrilhelm - Mithrilbrustplatte - Mithrilhose - Mithrilstiefel - - Adamantiner Helmet - Adamantine Brustplatte - Adamantine Hose - Adamantine Stiefel - - Iridiumhelm - Iridiumbrustplatte - Iridiumhose - Iridiumstiefel - - Magmatischer Orb - Aquatischer Orb - Orb der Fruchtbarkeit - Durchlüftender Orb - Kinesis-Orb - - Scherbe der Leere - - Mystc World - - - diff --git a/common/assets/mysticmods/lang/en_US.xml b/common/assets/mysticmods/lang/en_US.xml deleted file mode 100644 index 4195022..0000000 --- a/common/assets/mysticmods/lang/en_US.xml +++ /dev/null @@ -1,190 +0,0 @@ - - - - English (en_US) Localization File - - Verdite Sword - Verdite Pickaxe - Verdite Shovel - Verdite Axe - Verdite Hoe - - Mithril Sword - Mithril Pickaxe - Mithril Shovel - Mithril Axe - Mithril Hoe - - Adamantine Sword - Adamantine Pickaxe - Adamantine Shovel - Adamantine Axe - Adamantine Hoe - - Iridium Sword - Iridium Pickaxe - Iridium Shovel - Iridium Axe - Iridium Hoe - - Obsidian Sword - Obsidian Pickaxe - Obsidian Shovel - Obsidian Axe - Obsidian Hoe - - Bloodstone Sword - Bloodstone Pickaxe - Bloodstone Shovel - Bloodstone Axe - Bloodstone Hoe - - Verdite Ingot - Mithril Ingot - Adamantine Ingot - Iridium Ingot - Iridium Nugget - Tourmaline Gemstone - Agate Gemstone - Topaz Gemstone - Amethyst Gemstone - Mystic Powder - Bloodstone Shard - Glass Shard - Obsidian Shard - Obsidian Rod - Magical Bag - - Adamantine Ore - Amethyst Ore - Iridium Ore - Mithril Ore - Tourmaline Ore - Topaz Ore - Verdite Ore - Bloodstone - Black Soulstone - Blue Soulstone - Red Soulstone - Agate Ore - Tempered Glass - - Mystic Ores - - Purple Planks - Green Planks - Black Planks - Orange Planks - Red Planks - Blue Planks - Yellow Planks - - Smooth Anorthosite - Smooth Limestone - Smooth Slate - Smooth Migmatite - Smooth Orthogneiss - Smooth Marble - Smooth Travertine - - Anorthosite - Limestone - Slate - Migmatite - Orthogneiss - Marble - Travertine - - Anorthosite Bricks - Limestone Bricks - Slate Bricks - Migmatite Bricks - Orthogneiss Bricks - Marble Bricks - Travertine Bricks - - Verdite Reinforced Bricks - Mithril Reinforced Bricks - Adamantine Reinforced Bricks - Iridium Reinfroced Bricks - Topaz Reinforced Bricks - Tourmaline Reinforced Bricks - Amethyst Reinforced Bricks - Agate Reinforced Bricks - - Mystic Stones - - Magmatic Stone Chunk - Aquatic Stone Chunk - Fertile Stone Chunk - Aerated Stone Chunk - Kinetic Stone Chunk - - Mundane Bush - Poisonous Bush - Weakening Bush - Slowness Bush - Harming Bush - Withering Bush - Healing Bush - Speed Bush - Extinguishing Bush - Regeneration Bush - Night Vision Bush - Invisibility Bush - - Pillar Platform - Pillar Tower - Pillar Insert - - Staff - Staff Hilt - Staff Handle - Staff Topper - - Magmatic Shard - Aquatic Shard - Fertile Shard - Aerated Shard - Kinetic Shard - - Magma Staff - Aqua Staff - Fertile Staff - Aeration Staff - Kinesis Staff - - Mysterious Fruit - - Verdite Helmet - Verdite Chestplate - Verdite Leggings - Verdite Boots - - Mithril Helmet - Mithril Chestplate - Mithril Leggings - Mithril Boots - - Adamantine Helmet - Adamantine Chestplate - Adamantine Leggings - Adamantine Boots - - Iridium Helmet - Iridium Chestplate - Iridium Leggings - Iridium Boots - - Magmatic Orb - Aquatic Orb - Orb of Fertility - Aerating Orb - Kinesis Orb - - Void Shard - - Mystic World - - - diff --git a/common/assets/mysticores/lang/de_DE.lang b/common/assets/mysticores/lang/de_DE.lang new file mode 100644 index 0000000..2a57cc7 --- /dev/null +++ b/common/assets/mysticores/lang/de_DE.lang @@ -0,0 +1,68 @@ + +item.VerditeSword.name=Verditschwert +item.VerditePickaxe.name=Verditspitzhacke +item.VerditeShovel.name=Verditschaufel +item.VerditeAxe.name=Verditaxt +item.VerditeHoe.name=Verdithacke + +item.MithrilSword.name=Mithrilschwert +item.MithrilPickaxe.name=Mithrilspitzhacke +item.MithrilShovel.name=Mithrilschaufel +item.MithrilAxe.name=Mithrilaxt +item.MithrilHoe.name=Mithrilhacke + +item.AdamantineSword.name=Adamantines Schwert +item.AdamantinePickaxe.name=Adamantine Spitzhacke +item.AdamantineShovel.name=Adamantine Schaufel +item.AdamantineAxe.name=Adamantine Axt +item.AdamantineHoe.name=Adamantine Hacke + +item.IridiumSword.name=Iridiumschwert +item.IridiumPickaxe.name=Iridiumspitzhacke +item.IridiumShovel.name=Iridiumschaufel +item.IridiumAxe.name=Iridiumaxt +item.IridiumHoe.name=Iridiumhacke + +item.ObsidianSword.name=Obsidianschwert +item.ObsidianPickaxe.name=Obsidianspitzhacke +item.ObsidianShovel.name=Obsidianschaufel +item.ObsidianAxe.name=Obsidianaxt +item.ObsidianHoe.name=Obsidianhacke + +item.BloodstoneSword.name=Blutsteinschwert +item.BloodstonePickaxe.name=Blutsteinspitzhacke +item.BloodstoneShovel.name=Blutsteinschaufel +item.BloodstoneAxe.name=Blutsteinaxt +item.BloodstoneHoe.name=Blutsteinhacke + +Verdite Ingot.name=Verditbarren +Mithril Ingot.name=Mithrilbarren +Adamantine Ingot.name=Adamantiner Barren +Iridium Ingot.name=Iridiumbarren +Iridium Nugget.name=Iridiumnugget +Tourmaline Gem.name=Turmalin +Agate Gem.name=Achat +Topaz Gem.name=Topas +Amethyst Gem.name=Amethyst +Mystic Powder.name=Mystisches Pulver +Bloodstone Shard.name=Blutsteinscherbe +Glass Shard.name=Glasscherbe +Obsidian Shard.name=Obsidianscherbe +Obsidian Rod.name=Obsidianstab +item.Satchel.name=Magischer Beutel + +Adamantine Ore.name=Adamantines Erz +Amethyst Ore.name=Amethysterz +Iridium Ore.name=Iridiumerz +Mithril Ore.name=Mithrilerz +Tourmaline Ore.name=Turmalinerz +Topaz Ore.name=Topaserz +Verdite Ore.name=Verditerz +Bloodstone.name=Blutstein +Black Soulstone.name=Schwarzer Seelenstein +Blue Soulstone.name=Blauer Seelenstein +Red Soulstone.name=Roter Seelenstein +Agate Ore.name=Achaterz +Tempered Glass.name=Gehärtetes Glas + +itemGroup.MysticOresTab=Mystic Ores \ No newline at end of file diff --git a/common/assets/mysticores/lang/en_US.lang b/common/assets/mysticores/lang/en_US.lang new file mode 100644 index 0000000..87f376a --- /dev/null +++ b/common/assets/mysticores/lang/en_US.lang @@ -0,0 +1,68 @@ + +item.VerditeSword.name=Verdite Sword +item.VerditePickaxe.name=Verdite Pickaxe +item.VerditeShovel.name=Verdite Shovel +item.VerditeAxe.name=Verdite Axe +item.VerditeHoe.name=Verdite Hoe + +item.MithrilSword.name=Mithril Sword +item.MithrilPickaxe.name=Mithril Pickaxe +item.MithrilShovel.name=Mithril Shovel +item.MithrilAxe.name=Mithril Axe +item.MithrilHoe.name=Mithril Hoe + +item.AdamantineSword.name=Adamantine Sword +item.AdamantinePickaxe.name=Adamantine Pickaxe +item.AdamantineShovel.name=Adamantine Shovel +item.AdamantineAxe.name=Adamantine Axe +item.AdamantineHoe.name=Adamantine Hoe + +item.IridiumSword.name=Iridium Sword +item.IridiumPickaxe.name=Iridium Pickaxe +item.IridiumShovel.name=Iridium Shovel +item.IridiumAxe.name=Iridium Axe +item.IridiumHoe.name=Iridium Hoe + +item.ObsidianSword.name=Obsidian Sword +item.ObsidianPickaxe.name=Obsidian Pickaxe +item.ObsidianShovel.name=Obsidian Shovel +item.ObsidianAxe.name=Obsidian Axe +item.ObsidianHoe.name=Obsidian Hoe + +item.BloodstoneSword.name=Bloodstone Sword +item.BloodstonePickaxe.name=Bloodstone Pickaxe +item.BloodstoneShovel.name=Bloodstone Shovel +item.BloodstoneAxe.name=Bloodstone Axe +item.BloodstoneHoe.name=Bloodstone Hoe + +Verdite Ingot.name=Verdite Ingot +Mithril Ingot.name=Mithril Ingot +Adamantine Ingot.name=Adamantine Ingot +Iridium Ingot.name=Iridium Ingot +Iridium Nugget.name=Iridium Nugget +Tourmaline Gem.name=Tourmaline Gemstone +Agate Gem.name=Agate Gemstone +Topaz Gem.name=Topaz Gemstone +Amethyst Gem.name=Amethyst Gemstone +Mystic Powder.name=Mystic Powder +Bloodstone Shard.name=Bloodstone Shard +Glass Shard.name=Glass Shard +Obsidian Shard.name=Obsidian Shard +Obsidian Rod.name=Obsidian Rod +item.Satchel.name=Magical Bag + +Adamantine Ore.name=Adamantine Ore +Amethyst Ore.name=Amethyst Ore +Iridium Ore.name=Iridium Ore +Mithril Ore.name=Mithril Ore +Tourmaline Ore.name=Tourmaline Ore +Topaz Ore.name=Topaz Ore +Verdite Ore.name=Verdite Ore +Bloodstone.name=Bloodstone +Black Soulstone.name=Black Soulstone +Blue Soulstone.name=Blue Soulstone +Red Soulstone.name=Red Soulstone +Agate Ore.name=Agate Ore +Tempered Glass.name=Tempered Glass + +itemGroup.MysticOresTab=Mystic Ores \ No newline at end of file diff --git a/common/assets/mysticores/lang/ru_RU.lang b/common/assets/mysticores/lang/ru_RU.lang new file mode 100644 index 0000000..c8f51ab --- /dev/null +++ b/common/assets/mysticores/lang/ru_RU.lang @@ -0,0 +1,68 @@ + +item.VerditeSword.name=Вердитовый меч +item.VerditePickaxe.name=Вердитовая кирка +item.VerditeShovel.name=Вердитовая лопата +item.VerditeAxe.name=Вердитовый топор +item.VerditeHoe.name=Вердитовая мотыга + +item.MithrilSword.name=Мифриловый меч +item.MithrilPickaxe.name=Мифриловая кирка +item.MithrilShovel.name=Мифриловая лопата +item.MithrilAxe.name=Мифриловый топор +item.MithrilHoe.name=Мифриловая мотыга + +item.AdamantineSword.name=Адамантиновый меч +item.AdamantinePickaxe.name=Адамантиновая кирка +item.AdamantineShovel.name=Адамантиновая лопата +item.AdamantineAxe.name=Адамантиновый топор +item.AdamantineHoe.name=Адамантиновая мотыга + +item.IridiumSword.name=Иридиевый меч +item.IridiumPickaxe.name=Иридиевая кирка +item.IridiumShovel.name=Иридиевая лопата +item.IridiumAxe.name=Иридиевый топор +item.IridiumHoe.name=Иридиевая мотыга + +item.ObsidianSword.name=Обсидиановый меч +item.ObsidianPickaxe.name=Обсидиановая кирка +item.ObsidianShovel.name=Обсидиановая лопата +item.ObsidianAxe.name=Обсидиановый топор +item.ObsidianHoe.name=Обсидиановая мотыга + +item.BloodstoneSword.name=Меч из кровавого камня +item.BloodstonePickaxe.name=Кирка из кровавого камня +item.BloodstoneShovel.name=Лопата из кровавого камня +item.BloodstoneAxe.name=Топор из кровавого камня +item.BloodstoneHoe.name=Мотыга из кровавого камня + +Verdite Ingot.name=Вердитовый слиток +Mithril Ingot.name=Мифриловый слиток +Adamantine Ingot.name=Адамантиновый слиток +Iridium Ingot.name=Иридиевый слиток +Iridium Nugget.name=Иридиевый самородок +Tourmaline Gem.name=Турмалин +Agate Gem.name=Агат +Topaz Gem.name=Топаз +Amethyst Gem.name=Аметист +Mystic Powder.name=Мистическая пыль +Bloodstone Shard.name=Осколок кровавого камня +Glass Shard.name=Осколок стекла +Obsidian Shard.name=Осколок обсидиана +Obsidian Rod.name=Обсидиановый стержень +item.Satchel.name=Магический рюкзак + +Adamantine Ore.name=Адамантиновая руда +Amethyst Ore.name=Аметистовая руда +Iridium Ore.name=Иридиевая руда +Mithril Ore.name=Мифриловая руда +Tourmaline Ore.name=Турмалиновая руда +Topaz Ore.name=Топазовая руда +Verdite Ore.name=Вердитовая руда +Bloodstone.name=Кровавый камень +Black Soulstone.name=Чёрный Камень Душ +Blue Soulstone.name=Синий Камень Душ +Red Soulstone.name=Красный Камень Душ +Agate Ore.name=Агатовая руда +Tempered Glass.name=Закалённое стекло + +itemGroup.MysticOresTab=MysticMods (Руды и инструменты) \ No newline at end of file diff --git a/common/assets/mysticmods/textures/blocks/Adamantine Ore.png b/common/assets/mysticores/textures/blocks/Adamantine Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Adamantine Ore.png rename to common/assets/mysticores/textures/blocks/Adamantine Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Agate Ore.png b/common/assets/mysticores/textures/blocks/Agate Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Agate Ore.png rename to common/assets/mysticores/textures/blocks/Agate Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Amethyst Ore.png b/common/assets/mysticores/textures/blocks/Amethyst Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Amethyst Ore.png rename to common/assets/mysticores/textures/blocks/Amethyst Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Black Soulstone.png b/common/assets/mysticores/textures/blocks/Black Soulstone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Black Soulstone.png rename to common/assets/mysticores/textures/blocks/Black Soulstone.png diff --git a/common/assets/mysticmods/textures/blocks/Bloodstone.png b/common/assets/mysticores/textures/blocks/Bloodstone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Bloodstone.png rename to common/assets/mysticores/textures/blocks/Bloodstone.png diff --git a/common/assets/mysticmods/textures/blocks/Blue Soulstone.png b/common/assets/mysticores/textures/blocks/Blue Soulstone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Blue Soulstone.png rename to common/assets/mysticores/textures/blocks/Blue Soulstone.png diff --git a/common/assets/mysticmods/textures/blocks/Iridium Ore.png b/common/assets/mysticores/textures/blocks/Iridium Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Iridium Ore.png rename to common/assets/mysticores/textures/blocks/Iridium Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Mithril Ore.png b/common/assets/mysticores/textures/blocks/Mithril Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Mithril Ore.png rename to common/assets/mysticores/textures/blocks/Mithril Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Red Soulstone.png b/common/assets/mysticores/textures/blocks/Red Soulstone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Red Soulstone.png rename to common/assets/mysticores/textures/blocks/Red Soulstone.png diff --git a/common/assets/mysticmods/textures/blocks/Tempered Glass.png b/common/assets/mysticores/textures/blocks/Tempered Glass.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Tempered Glass.png rename to common/assets/mysticores/textures/blocks/Tempered Glass.png diff --git a/common/assets/mysticmods/textures/blocks/Topaz Ore.png b/common/assets/mysticores/textures/blocks/Topaz Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Topaz Ore.png rename to common/assets/mysticores/textures/blocks/Topaz Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Tourmaline Ore.png b/common/assets/mysticores/textures/blocks/Tourmaline Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Tourmaline Ore.png rename to common/assets/mysticores/textures/blocks/Tourmaline Ore.png diff --git a/common/assets/mysticmods/textures/blocks/Verdite Ore.png b/common/assets/mysticores/textures/blocks/Verdite Ore.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Verdite Ore.png rename to common/assets/mysticores/textures/blocks/Verdite Ore.png diff --git a/common/assets/mysticmods/textures/items/Adamantine Ingot.png b/common/assets/mysticores/textures/items/Adamantine Ingot.png similarity index 100% rename from common/assets/mysticmods/textures/items/Adamantine Ingot.png rename to common/assets/mysticores/textures/items/Adamantine Ingot.png diff --git a/common/assets/mysticmods/textures/items/AdamantineAxe.png b/common/assets/mysticores/textures/items/AdamantineAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineAxe.png rename to common/assets/mysticores/textures/items/AdamantineAxe.png diff --git a/common/assets/mysticmods/textures/items/AdamantineHoe.png b/common/assets/mysticores/textures/items/AdamantineHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineHoe.png rename to common/assets/mysticores/textures/items/AdamantineHoe.png diff --git a/common/assets/mysticmods/textures/items/AdamantinePickaxe.png b/common/assets/mysticores/textures/items/AdamantinePickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantinePickaxe.png rename to common/assets/mysticores/textures/items/AdamantinePickaxe.png diff --git a/common/assets/mysticmods/textures/items/AdamantineShovel.png b/common/assets/mysticores/textures/items/AdamantineShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineShovel.png rename to common/assets/mysticores/textures/items/AdamantineShovel.png diff --git a/common/assets/mysticmods/textures/items/AdamantineSword.png b/common/assets/mysticores/textures/items/AdamantineSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineSword.png rename to common/assets/mysticores/textures/items/AdamantineSword.png diff --git a/common/assets/mysticmods/textures/items/Agate Gem.png b/common/assets/mysticores/textures/items/Agate Gem.png similarity index 100% rename from common/assets/mysticmods/textures/items/Agate Gem.png rename to common/assets/mysticores/textures/items/Agate Gem.png diff --git a/common/assets/mysticmods/textures/items/Amethyst Gem.png b/common/assets/mysticores/textures/items/Amethyst Gem.png similarity index 100% rename from common/assets/mysticmods/textures/items/Amethyst Gem.png rename to common/assets/mysticores/textures/items/Amethyst Gem.png diff --git a/common/assets/mysticmods/textures/items/Bloodstone Shard.png b/common/assets/mysticores/textures/items/Bloodstone Shard.png similarity index 100% rename from common/assets/mysticmods/textures/items/Bloodstone Shard.png rename to common/assets/mysticores/textures/items/Bloodstone Shard.png diff --git a/common/assets/mysticmods/textures/items/BloodstoneAxe.png b/common/assets/mysticores/textures/items/BloodstoneAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/BloodstoneAxe.png rename to common/assets/mysticores/textures/items/BloodstoneAxe.png diff --git a/common/assets/mysticmods/textures/items/BloodstoneHoe.png b/common/assets/mysticores/textures/items/BloodstoneHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/BloodstoneHoe.png rename to common/assets/mysticores/textures/items/BloodstoneHoe.png diff --git a/common/assets/mysticmods/textures/items/BloodstonePickaxe.png b/common/assets/mysticores/textures/items/BloodstonePickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/BloodstonePickaxe.png rename to common/assets/mysticores/textures/items/BloodstonePickaxe.png diff --git a/common/assets/mysticmods/textures/items/BloodstoneShovel.png b/common/assets/mysticores/textures/items/BloodstoneShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/BloodstoneShovel.png rename to common/assets/mysticores/textures/items/BloodstoneShovel.png diff --git a/common/assets/mysticmods/textures/items/BloodstoneSword.png b/common/assets/mysticores/textures/items/BloodstoneSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/BloodstoneSword.png rename to common/assets/mysticores/textures/items/BloodstoneSword.png diff --git a/common/assets/mysticmods/textures/items/Glass Shard.png b/common/assets/mysticores/textures/items/Glass Shard.png similarity index 100% rename from common/assets/mysticmods/textures/items/Glass Shard.png rename to common/assets/mysticores/textures/items/Glass Shard.png diff --git a/common/assets/mysticmods/textures/items/Iridium Ingot.png b/common/assets/mysticores/textures/items/Iridium Ingot.png similarity index 100% rename from common/assets/mysticmods/textures/items/Iridium Ingot.png rename to common/assets/mysticores/textures/items/Iridium Ingot.png diff --git a/common/assets/mysticmods/textures/items/Iridium Nugget.png b/common/assets/mysticores/textures/items/Iridium Nugget.png similarity index 100% rename from common/assets/mysticmods/textures/items/Iridium Nugget.png rename to common/assets/mysticores/textures/items/Iridium Nugget.png diff --git a/common/assets/mysticmods/textures/items/IridiumAxe.png b/common/assets/mysticores/textures/items/IridiumAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumAxe.png rename to common/assets/mysticores/textures/items/IridiumAxe.png diff --git a/common/assets/mysticmods/textures/items/IridiumHoe.png b/common/assets/mysticores/textures/items/IridiumHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumHoe.png rename to common/assets/mysticores/textures/items/IridiumHoe.png diff --git a/common/assets/mysticmods/textures/items/IridiumPickaxe.png b/common/assets/mysticores/textures/items/IridiumPickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumPickaxe.png rename to common/assets/mysticores/textures/items/IridiumPickaxe.png diff --git a/common/assets/mysticmods/textures/items/IridiumShovel.png b/common/assets/mysticores/textures/items/IridiumShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumShovel.png rename to common/assets/mysticores/textures/items/IridiumShovel.png diff --git a/common/assets/mysticmods/textures/items/IridiumSword.png b/common/assets/mysticores/textures/items/IridiumSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumSword.png rename to common/assets/mysticores/textures/items/IridiumSword.png diff --git a/common/assets/mysticmods/textures/items/Mithril Ingot.png b/common/assets/mysticores/textures/items/Mithril Ingot.png similarity index 100% rename from common/assets/mysticmods/textures/items/Mithril Ingot.png rename to common/assets/mysticores/textures/items/Mithril Ingot.png diff --git a/common/assets/mysticmods/textures/items/MithrilAxe.png b/common/assets/mysticores/textures/items/MithrilAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilAxe.png rename to common/assets/mysticores/textures/items/MithrilAxe.png diff --git a/common/assets/mysticmods/textures/items/MithrilHoe.png b/common/assets/mysticores/textures/items/MithrilHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilHoe.png rename to common/assets/mysticores/textures/items/MithrilHoe.png diff --git a/common/assets/mysticmods/textures/items/MithrilPickaxe.png b/common/assets/mysticores/textures/items/MithrilPickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilPickaxe.png rename to common/assets/mysticores/textures/items/MithrilPickaxe.png diff --git a/common/assets/mysticmods/textures/items/MithrilShovel.png b/common/assets/mysticores/textures/items/MithrilShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilShovel.png rename to common/assets/mysticores/textures/items/MithrilShovel.png diff --git a/common/assets/mysticmods/textures/items/MithrilSword.png b/common/assets/mysticores/textures/items/MithrilSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilSword.png rename to common/assets/mysticores/textures/items/MithrilSword.png diff --git a/common/assets/mysticmods/textures/items/Mystic Powder.png b/common/assets/mysticores/textures/items/Mystic Powder.png similarity index 100% rename from common/assets/mysticmods/textures/items/Mystic Powder.png rename to common/assets/mysticores/textures/items/Mystic Powder.png diff --git a/common/assets/mysticmods/textures/items/Obsidian Rod.png b/common/assets/mysticores/textures/items/Obsidian Rod.png similarity index 100% rename from common/assets/mysticmods/textures/items/Obsidian Rod.png rename to common/assets/mysticores/textures/items/Obsidian Rod.png diff --git a/common/assets/mysticmods/textures/items/Obsidian Shard.png b/common/assets/mysticores/textures/items/Obsidian Shard.png similarity index 100% rename from common/assets/mysticmods/textures/items/Obsidian Shard.png rename to common/assets/mysticores/textures/items/Obsidian Shard.png diff --git a/common/assets/mysticmods/textures/items/ObsidianAxe.png b/common/assets/mysticores/textures/items/ObsidianAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/ObsidianAxe.png rename to common/assets/mysticores/textures/items/ObsidianAxe.png diff --git a/common/assets/mysticmods/textures/items/ObsidianHoe.png b/common/assets/mysticores/textures/items/ObsidianHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/ObsidianHoe.png rename to common/assets/mysticores/textures/items/ObsidianHoe.png diff --git a/common/assets/mysticmods/textures/items/ObsidianPickaxe.png b/common/assets/mysticores/textures/items/ObsidianPickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/ObsidianPickaxe.png rename to common/assets/mysticores/textures/items/ObsidianPickaxe.png diff --git a/common/assets/mysticmods/textures/items/ObsidianShovel.png b/common/assets/mysticores/textures/items/ObsidianShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/ObsidianShovel.png rename to common/assets/mysticores/textures/items/ObsidianShovel.png diff --git a/common/assets/mysticmods/textures/items/ObsidianSword.png b/common/assets/mysticores/textures/items/ObsidianSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/ObsidianSword.png rename to common/assets/mysticores/textures/items/ObsidianSword.png diff --git a/common/assets/mysticmods/textures/items/Satchel.png b/common/assets/mysticores/textures/items/Satchel.png similarity index 100% rename from common/assets/mysticmods/textures/items/Satchel.png rename to common/assets/mysticores/textures/items/Satchel.png diff --git a/common/assets/mysticmods/textures/items/Topaz Gem.png b/common/assets/mysticores/textures/items/Topaz Gem.png similarity index 100% rename from common/assets/mysticmods/textures/items/Topaz Gem.png rename to common/assets/mysticores/textures/items/Topaz Gem.png diff --git a/common/assets/mysticmods/textures/items/Tourmaline Gem.png b/common/assets/mysticores/textures/items/Tourmaline Gem.png similarity index 100% rename from common/assets/mysticmods/textures/items/Tourmaline Gem.png rename to common/assets/mysticores/textures/items/Tourmaline Gem.png diff --git a/common/assets/mysticmods/textures/items/Verdite Ingot.png b/common/assets/mysticores/textures/items/Verdite Ingot.png similarity index 100% rename from common/assets/mysticmods/textures/items/Verdite Ingot.png rename to common/assets/mysticores/textures/items/Verdite Ingot.png diff --git a/common/assets/mysticmods/textures/items/VerditeAxe.png b/common/assets/mysticores/textures/items/VerditeAxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeAxe.png rename to common/assets/mysticores/textures/items/VerditeAxe.png diff --git a/common/assets/mysticmods/textures/items/VerditeHoe.png b/common/assets/mysticores/textures/items/VerditeHoe.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeHoe.png rename to common/assets/mysticores/textures/items/VerditeHoe.png diff --git a/common/assets/mysticmods/textures/items/VerditePickaxe.png b/common/assets/mysticores/textures/items/VerditePickaxe.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditePickaxe.png rename to common/assets/mysticores/textures/items/VerditePickaxe.png diff --git a/common/assets/mysticmods/textures/items/VerditeShovel.png b/common/assets/mysticores/textures/items/VerditeShovel.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeShovel.png rename to common/assets/mysticores/textures/items/VerditeShovel.png diff --git a/common/assets/mysticmods/textures/items/VerditeSword.png b/common/assets/mysticores/textures/items/VerditeSword.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeSword.png rename to common/assets/mysticores/textures/items/VerditeSword.png diff --git a/common/assets/mysticstones/lang/de_DE.lang b/common/assets/mysticstones/lang/de_DE.lang new file mode 100644 index 0000000..49103b1 --- /dev/null +++ b/common/assets/mysticstones/lang/de_DE.lang @@ -0,0 +1,43 @@ + +Purple Planks.name=Violette Planken +Green Planks.name=Grüne Planken +Black Planks.name=Schwarze Planken +Orange Planks.name=Orange Planken +Red Planks.name=Rote Planken +Blue Planks.name=Blaue Planken +Yellow Planks.name=Gelbe Planken + +Smooth Anorthosite.name=Glattes Anorthosit +Smooth Limestone.name=Glatter Kalkstein +Smooth Slate.name=Glatter Schiefer +Smooth Migmatite.name=Glattes Migmatit +Smooth Orthogneiss.name=Glattes Orthogneis +Smooth Marble.name=Glatter Marmor +Smooth Travertine.name=Glattes Travertin + +Anorthosite.name=Anorthosit +Limestone.name=Kalkstein +Slate.name=Schiefer +Migmatite.name=Migmatit +Orthogneiss.name=Orthogneis +Marble.name=Marmor +Travertine.name=Travertin + +Anorthosite Bricks.name=Anorthositziegel +Limestone Bricks.name=Kalksteinziegel +Slate Bricks.name=Schieferziegel +Migmatite Bricks.name=Migmatitziegel +Orthogneiss Bricks.name=Orthogneisziegel +Marble Bricks.name=Marmorziegel +Travertine Bricks.name=Travertinziegel + +Verdite Bricks.name=Verdit-verstärkte Ziegel +Mithril Bricks.name=Mithril-verstärkte Ziegel +Adamantine Bricks.name=Adamantine Verstärkte Ziegel +Iridium Bricks.name=Iridium-verstärkte Ziegel +Topaz Bricks.name=Topas-verstärkte Ziegel +Tourmaline Bricks.name=Turmalin-verstärkte Ziegel +Amethyst Bricks.name=Amethyst-verstärkte Ziegel +Agate Bricks.name=Achat-verstärkte Ziegel + +itemGroup.MysticStonesTab=Mystic Stones \ No newline at end of file diff --git a/common/assets/mysticstones/lang/en_US.lang b/common/assets/mysticstones/lang/en_US.lang new file mode 100644 index 0000000..9cff482 --- /dev/null +++ b/common/assets/mysticstones/lang/en_US.lang @@ -0,0 +1,43 @@ + +Purple Planks.name=Purple Planks +Green Planks.name=Green Planks +Black Planks.name=Black Planks +Orange Planks.name=Orange Planks +Red Planks.name=Red Planks +Blue Planks.name=Blue Planks +Yellow Planks.name=Yellow Planks + +Smooth Anorthosite.name=Smooth Anorthosite +Smooth Limestone.name=Smooth Limestone +Smooth Slate.name=Smooth Slate +Smooth Migmatite.name=Smooth Migmatite +Smooth Orthogneiss.name=Smooth Orthogneiss +Smooth Marble.name=Smooth Marble +Smooth Travertine.name=Smooth Travertine + +Anorthosite.name=Anorthosite +Limestone.name=Limestone +Slate.name=Slate +Migmatite.name=Migmatite +Orthogneiss.name=Orthogneiss +Marble.name=Marble +Travertine.name=Travertine + +Anorthosite Bricks.name=Anorthosite Bricks +Limestone Bricks.name=Limestone Bricks +Slate Bricks.name=Slate Bricks +Migmatite Bricks.name=Migmatite Bricks +Orthogneiss Bricks.name=Orthogneiss Bricks +Marble Bricks.name=Marble Bricks +Travertine Bricks.name=Travertine Bricks + +Verdite Bricks.name=Verdite Reinforced Bricks +Mithril Bricks.name=Mithril Reinforced Bricks +Adamantine Bricks.name=Adamantine Reinforced Bricks +Iridium Bricks.name=Iridium Reinfroced Bricks +Topaz Bricks.name=Topaz Reinforced Bricks +Tourmaline Bricks.name=Tourmaline Reinforced Bricks +Amethyst Bricks.name=Amethyst Reinforced Bricks +Agate Bricks.name=Agate Reinforced Bricks + +itemGroup.MysticStonesTab=Mystic Stones \ No newline at end of file diff --git a/common/assets/mysticstones/lang/ru_RU.lang b/common/assets/mysticstones/lang/ru_RU.lang new file mode 100644 index 0000000..2bc286b --- /dev/null +++ b/common/assets/mysticstones/lang/ru_RU.lang @@ -0,0 +1,43 @@ + +Purple Planks.name=Фиолетовые доски +Green Planks.name=Зелёные доски +Black Planks.name=Чёрные доски +Orange Planks.name=Оранжевые доски +Red Planks.name=Красные доски +Blue Planks.name=Синие доски +Yellow Planks.name=Жёлтые доски + +Smooth Anorthosite.name=Гладкий анортозит +Smooth Limestone.name=Гладкий известняк +Smooth Slate.name=Гладкий сланец +Smooth Migmatite.name=Гладкий мигматит +Smooth Orthogneiss.name=Гладкий ортогнейс +Smooth Marble.name=Гладкий мрамор +Smooth Travertine.name=Гладкий травертин + +Anorthosite.name=Анортозит +Limestone.name=Известняк +Slate.name=Сланец +Migmatite.name=Мигматит +Orthogneiss.name=Ортогнейс +Marble.name=Мрамор +Travertine.name=Травертин + +Anorthosite Bricks.name=Анортозитовый кирпич +Limestone Bricks.name=Известняковый кирпич +Slate Bricks.name=Сланцевый кирпич +Migmatite Bricks.name=Мигматитовый кирпич +Orthogneiss Bricks.name=Ортогнейсовый кирпич +Marble Bricks.name=Мраморный кирпич +Travertine Bricks.name=Травертиновый кирпич + +Verdite Bricks.name=Вердитовый армированный кирпич +Mithril Bricks.name=Мифриловый армированный кирпич +Adamantine Bricks.name=Адамантиновый армированный кирпич +Iridium Bricks.name=Иридиевый армированный кирпич +Topaz Bricks.name=Топазовый армированный кирпич +Tourmaline Bricks.name=Турмалиновый армированный кирпич +Amethyst Bricks.name=Аметистовый армированный кирпич +Agate Bricks.name=Агатовый армированный кирпич + +itemGroup.MysticStonesTab=MysticMods (Камни и доски) \ No newline at end of file diff --git a/common/assets/mysticmods/textures/blocks/Adamantine Bricks.png b/common/assets/mysticstones/textures/blocks/Adamantine Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Adamantine Bricks.png rename to common/assets/mysticstones/textures/blocks/Adamantine Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Agate Bricks.png b/common/assets/mysticstones/textures/blocks/Agate Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Agate Bricks.png rename to common/assets/mysticstones/textures/blocks/Agate Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Amethyst Bricks.png b/common/assets/mysticstones/textures/blocks/Amethyst Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Amethyst Bricks.png rename to common/assets/mysticstones/textures/blocks/Amethyst Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Anorthosite Bricks.png b/common/assets/mysticstones/textures/blocks/Anorthosite Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Anorthosite Bricks.png rename to common/assets/mysticstones/textures/blocks/Anorthosite Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Anorthosite.png b/common/assets/mysticstones/textures/blocks/Anorthosite.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Anorthosite.png rename to common/assets/mysticstones/textures/blocks/Anorthosite.png diff --git a/common/assets/mysticmods/textures/blocks/Black Planks.png b/common/assets/mysticstones/textures/blocks/Black Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Black Planks.png rename to common/assets/mysticstones/textures/blocks/Black Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Blue Planks.png b/common/assets/mysticstones/textures/blocks/Blue Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Blue Planks.png rename to common/assets/mysticstones/textures/blocks/Blue Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Green Planks.png b/common/assets/mysticstones/textures/blocks/Green Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Green Planks.png rename to common/assets/mysticstones/textures/blocks/Green Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Iridium Bricks.png b/common/assets/mysticstones/textures/blocks/Iridium Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Iridium Bricks.png rename to common/assets/mysticstones/textures/blocks/Iridium Bricks.png diff --git a/common/assets/mysticstones/textures/blocks/Iridium Ore.png b/common/assets/mysticstones/textures/blocks/Iridium Ore.png new file mode 100644 index 0000000..4406592 Binary files /dev/null and b/common/assets/mysticstones/textures/blocks/Iridium Ore.png differ diff --git a/common/assets/mysticmods/textures/blocks/Limestone Bricks.png b/common/assets/mysticstones/textures/blocks/Limestone Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Limestone Bricks.png rename to common/assets/mysticstones/textures/blocks/Limestone Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Limestone.png b/common/assets/mysticstones/textures/blocks/Limestone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Limestone.png rename to common/assets/mysticstones/textures/blocks/Limestone.png diff --git a/common/assets/mysticmods/textures/blocks/Marble Bricks.png b/common/assets/mysticstones/textures/blocks/Marble Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Marble Bricks.png rename to common/assets/mysticstones/textures/blocks/Marble Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Marble.png b/common/assets/mysticstones/textures/blocks/Marble.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Marble.png rename to common/assets/mysticstones/textures/blocks/Marble.png diff --git a/common/assets/mysticmods/textures/blocks/Migmatite Bricks.png b/common/assets/mysticstones/textures/blocks/Migmatite Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Migmatite Bricks.png rename to common/assets/mysticstones/textures/blocks/Migmatite Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Migmatite.png b/common/assets/mysticstones/textures/blocks/Migmatite.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Migmatite.png rename to common/assets/mysticstones/textures/blocks/Migmatite.png diff --git a/common/assets/mysticmods/textures/blocks/Mithril Bricks.png b/common/assets/mysticstones/textures/blocks/Mithril Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Mithril Bricks.png rename to common/assets/mysticstones/textures/blocks/Mithril Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/MysticDirt.png b/common/assets/mysticstones/textures/blocks/MysticDirt.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/MysticDirt.png rename to common/assets/mysticstones/textures/blocks/MysticDirt.png diff --git a/common/assets/mysticmods/textures/blocks/Orange Planks.png b/common/assets/mysticstones/textures/blocks/Orange Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Orange Planks.png rename to common/assets/mysticstones/textures/blocks/Orange Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Orthogneiss Bricks.png b/common/assets/mysticstones/textures/blocks/Orthogneiss Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Orthogneiss Bricks.png rename to common/assets/mysticstones/textures/blocks/Orthogneiss Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Orthogneiss.png b/common/assets/mysticstones/textures/blocks/Orthogneiss.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Orthogneiss.png rename to common/assets/mysticstones/textures/blocks/Orthogneiss.png diff --git a/common/assets/mysticmods/textures/blocks/Purple Planks.png b/common/assets/mysticstones/textures/blocks/Purple Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Purple Planks.png rename to common/assets/mysticstones/textures/blocks/Purple Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Red Planks.png b/common/assets/mysticstones/textures/blocks/Red Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Red Planks.png rename to common/assets/mysticstones/textures/blocks/Red Planks.png diff --git a/common/assets/mysticmods/textures/blocks/Slate Bricks.png b/common/assets/mysticstones/textures/blocks/Slate Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Slate Bricks.png rename to common/assets/mysticstones/textures/blocks/Slate Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Slate.png b/common/assets/mysticstones/textures/blocks/Slate.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Slate.png rename to common/assets/mysticstones/textures/blocks/Slate.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Anorthosite.png b/common/assets/mysticstones/textures/blocks/Smooth Anorthosite.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Anorthosite.png rename to common/assets/mysticstones/textures/blocks/Smooth Anorthosite.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Limestone.png b/common/assets/mysticstones/textures/blocks/Smooth Limestone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Limestone.png rename to common/assets/mysticstones/textures/blocks/Smooth Limestone.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Marble.png b/common/assets/mysticstones/textures/blocks/Smooth Marble.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Marble.png rename to common/assets/mysticstones/textures/blocks/Smooth Marble.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Migmatite.png b/common/assets/mysticstones/textures/blocks/Smooth Migmatite.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Migmatite.png rename to common/assets/mysticstones/textures/blocks/Smooth Migmatite.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Orthogneiss.png b/common/assets/mysticstones/textures/blocks/Smooth Orthogneiss.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Orthogneiss.png rename to common/assets/mysticstones/textures/blocks/Smooth Orthogneiss.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Slate.png b/common/assets/mysticstones/textures/blocks/Smooth Slate.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Slate.png rename to common/assets/mysticstones/textures/blocks/Smooth Slate.png diff --git a/common/assets/mysticmods/textures/blocks/Smooth Travertine.png b/common/assets/mysticstones/textures/blocks/Smooth Travertine.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Smooth Travertine.png rename to common/assets/mysticstones/textures/blocks/Smooth Travertine.png diff --git a/common/assets/mysticmods/textures/blocks/Topaz Bricks.png b/common/assets/mysticstones/textures/blocks/Topaz Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Topaz Bricks.png rename to common/assets/mysticstones/textures/blocks/Topaz Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Tourmaline Bricks.png b/common/assets/mysticstones/textures/blocks/Tourmaline Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Tourmaline Bricks.png rename to common/assets/mysticstones/textures/blocks/Tourmaline Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Travertine Bricks.png b/common/assets/mysticstones/textures/blocks/Travertine Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Travertine Bricks.png rename to common/assets/mysticstones/textures/blocks/Travertine Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Travertine.png b/common/assets/mysticstones/textures/blocks/Travertine.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Travertine.png rename to common/assets/mysticstones/textures/blocks/Travertine.png diff --git a/common/assets/mysticmods/textures/blocks/Verdite Bricks.png b/common/assets/mysticstones/textures/blocks/Verdite Bricks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Verdite Bricks.png rename to common/assets/mysticstones/textures/blocks/Verdite Bricks.png diff --git a/common/assets/mysticmods/textures/blocks/Yellow Planks.png b/common/assets/mysticstones/textures/blocks/Yellow Planks.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Yellow Planks.png rename to common/assets/mysticstones/textures/blocks/Yellow Planks.png diff --git a/common/assets/mysticworld/lang/de_DE.lang b/common/assets/mysticworld/lang/de_DE.lang new file mode 100644 index 0000000..8e6ce7d --- /dev/null +++ b/common/assets/mysticworld/lang/de_DE.lang @@ -0,0 +1,72 @@ + +imbuedStoneFire.name=Magmatischer Felsbrocken +imbuedStoneWater.name=Aquatischer Felsbrocken +imbuedStoneEarth.name=Fruchtbarer Felsbrocken +imbuedStoneAir.name=Durchlüfteter Felsbrocken +imbuedStoneEnergy.name=Kinetischer Felsbrocken + +Bush.name=Gewöhnlicher Busch +Poisonous Bush.name=Giftiger Busch +Weakness Bush.name=Schwächender Busch +Slowness Bush.name=Langsamkeitsbusch +Harming Bush.name=Schadender Busch +Wither Bush.name=Verzehrender Busch +Health Bush.name=Heilender Busch +Speed Bush.name=Geschwindigkeitsbusch +Fire Resistance Bush.name=Löschender Busch +Regen Bush.name=Regenerationsbusch +Night Vision Bush.name=Nachtsichtbusch +Invisibility Bush.name=Unsichtbarkeitsbusch + +tile.platform.name=Säulenplattform +tile.pillar.name=Säulenturm +tile.pillarInsert.name=Säuleneinlage + +Staff.name=Stab +Hilt.name=Stabheft +Handle.name=Stabgriff +Head.name=Stabspitze + +item.imbuedShardFire.name=Magmatische Scherbe +item.imbuedShardWater.name=Aquatische Scherbe +item.imbuedShardEarth.name=Fruchtbare Scherbe +item.imbuedShardAir.name=Durchlüftete Scherbe +item.imbuedShardEnergy.name=Kinetische Scherbe + +item.fireStaff.name=Magmastab +item.waterStaff.name=Aquastab +item.earthStaff.name=Fruchtbarer Stab +item.airStaff.name=Durchlüftungsstab +item.energyStaff.name=Kinesisstab + +item.bushFruit.name=Mysteriöse Frucht + +item.verditeHelmet.name=Verdithelm +item.verditeChestplate.name=Verditbrustplatte +item.verditeLeggings.name=Verditehose +item.verditeBoots.name=Verditestiefel + +item.mithrilHelmet.name=Mithrilhelm +item.mithrilChestplate.name=Mithrilbrustplatte +item.mithrilLeggings.name=Mithrilhose +item.mithrilBoots.name=Mithrilstiefel + +item.adamantineHelmet.name=Adamantiner Helmet +item.adamantineChestplate.name=Adamantine Brustplatte +item.adamantineLeggings.name=Adamantine Hose +item.adamantineBoots.name=Adamantine Stiefel + +item.iridiumHelmet.name=Iridiumhelm +item.iridiumChestplate.name=Iridiumbrustplatte +item.iridiumLeggings.name=Iridiumhose +item.iridiumBoots.name=Iridiumstiefel + +item.fireOrb.name=Magmatischer Orb +item.waterOrb.name=Aquatischer Orb +item.earthOrb.name=Orb der Fruchtbarkeit +item.airOrb.name=Durchlüftender Orb +item.energyOrb.name=Kinesis-Orb + +item.voidShard.name=Scherbe der Leere + +itemGroup.MysticWorldTab=Mystc World \ No newline at end of file diff --git a/common/assets/mysticworld/lang/en_US.lang b/common/assets/mysticworld/lang/en_US.lang new file mode 100644 index 0000000..c015889 --- /dev/null +++ b/common/assets/mysticworld/lang/en_US.lang @@ -0,0 +1,69 @@ + +imbuedStoneFire.name=Magmatic Stone Chunk +imbuedStoneWater.name=Aquatic Stone Chunk +imbuedStoneEarth.name=Fertile Stone Chunk +imbuedStoneAir.name=Aerated Stone Chunk +imbuedStoneEnergy.name=Kinetic Stone Chunk + +Bush.name=Mundane Bush +Poisonous Bush.name=Poisonous Bush +Weakness Bush.name=Weakening Bush +Slowness Bush.name=Slowness Bush +Harming Bush.name=Harming Bush +Wither Bush.name=Withering Bush +Health Bush.name=Healing Bush +Speed Bush.name=Speed Bush +Fire Resistance Bush.name=Extinguishing Bush +Regen Bush.name=Regeneration Bush +Night Vision Bush.name=Night Vision Bush +Invisibility Bush.name=Invisibility Bush + +tile.platform.name=Pillar Platform +tile.pillar.name=Pillar Tower +tile.pillarInsert.name=Pillarinsert + +Staff.name=Staff +Hilt.name=Staff Hilt +Handle.name=Staff Handle +Head.name=Staff Topper + +item.imbuedShardFire.name=Magmatic Shard +item.imbuedShardWater.name=Aquatic Shard +item.imbuedShardEarth.name=Fertile Shard +item.imbuedShardAir.name=Aerated Shard +item.imbuedShardEnergy.name=Kinetic Shard +item.fireStaff.name=Magma Staff +item.waterStaff.name=Aqua Staff +item.earthStaff.name=Fertile Staff +item.airStaff.name=Aeration Staff +item.energyStaff.name=Kinesis Staff +item.bushFruit.name=Mysterious Fruit + +item.verditeHelmet.name=Verdite Helmet +item.verditeChestplate.name=Verdite Chestplate +item.verditeLeggings.name=Verdite Leggings +item.verditeBoots.name=Verdite Boots + +item.mithrilHelmet.name=Mithril Helmet +item.mithrilChestplate.name=Mithril Chestplate +item.mithrilLeggings.name=Mithril Leggings +item.mithrilBoots.name=Mithril Boots + +item.adamantineHelmet.name=Adamantine Helmet +item.adamantineChestplate.name=Adamantine Chestplate +item.adamantineLeggings.name=Adamantine Leggings +item.adamantineBoots.name=Adamantine Boots + +item.iridiumHelmet.name=Iridium Helmet +item.iridiumChestplate.name=Iridium Chestplate +item.iridiumLeggings.name=Iridium Leggings +item.iridiumBoots.name=Iridium Boots + +item.fireOrb.name=Magmatic Orb +item.waterOrb.name=Aquatic Orb +item.earthOrb.name=Orb of Fertility +item.airOrb.name=Aerating Orb +item.energyOrb.name=Kinesis Orb +item.voidShard.name=Void Shard + +itemGroup.MysticWorldTab=Mystic World \ No newline at end of file diff --git a/common/assets/mysticworld/lang/ru_RU.lang b/common/assets/mysticworld/lang/ru_RU.lang new file mode 100644 index 0000000..e200c80 --- /dev/null +++ b/common/assets/mysticworld/lang/ru_RU.lang @@ -0,0 +1,69 @@ + +imbuedStoneFire.name=Часть Магмового Камня +imbuedStoneWater.name=Часть Камня Воды +imbuedStoneEarth.name=Часть Камня Изобилия +imbuedStoneAir.name=Часть Камня Воздуха +imbuedStoneEnergy.name=Часть Камня Энергии + +Bush.name=Кусты Мира +Poisonous Bush.name=Ядовитый куст +Weakness Bush.name=Куст слабости +Slowness Bush.name=Куст замедления +Harming Bush.name=Вредный куст +Wither Bush.name=Куст-иссушитель +Health Bush.name=Лечащий куст +Speed Bush.name=Куст скорости +Fire Resistance Bush.name=Куст спасения от огня +Regen Bush.name=Куст регенерации +Night Vision Bush.name=Куст ночного зрения +Invisibility Bush.name=Куст-невидимка + +tile.platform.name=Навершие колонны +tile.pillar.name=Колонна +tile.pillarInsert.name=Колонна + +Staff.name=Посох +Hilt.name=Древко посоха +Handle.name=Рукоять посоха +Head.name=Навершие посоха + +item.imbuedShardFire.name=Магмовый осколок +item.imbuedShardWater.name=Водяной осколок +item.imbuedShardEarth.name=Осколок изобилия +item.imbuedShardAir.name=Воздушный осколок +item.imbuedShardEnergy.name=Энергетический осколок +item.fireStaff.name=Магмовый посох +item.waterStaff.name=Посох Воды +item.earthStaff.name=Посох Изобилия +item.airStaff.name=Посох Воздуха +item.energyStaff.name=Посох Энергии +item.bushFruit.name=Таинственный фрукт + +item.verditeHelmet.name=Вердитовый шлем +item.verditeChestplate.name=Вердитовый нагрудник +item.verditeLeggings.name=Вердитовые поножи +item.verditeBoots.name=Вердитовые ботинки + +item.mithrilHelmet.name=Мифриловый шлем +item.mithrilChestplate.name=Мифриловый нагрудник +item.mithrilLeggings.name=Мифриловые поножи +item.mithrilBoots.name=Мифриловые ботинки + +item.adamantineHelmet.name=Адамантиновый шлем +item.adamantineChestplate.name=Адамантиновый нагрудник +item.adamantineLeggings.name=Адамантиновые поножи +item.adamantineBoots.name=Адамантиновые ботинки + +item.iridiumHelmet.name=Иридиевый шлем +item.iridiumChestplate.name=Иридиевый нагрудник +item.iridiumLeggings.name=Иридиевые поножи +item.iridiumBoots.name=Иридиевые ботинки + +item.fireOrb.name=Магмовый шар +item.waterOrb.name=Водяной шар +item.earthOrb.name=Шар изобилия +item.airOrb.name=Воздушный шар +item.energyOrb.name=Энергетический шар +item.voidShard.name=Пустой осколок + +itemGroup.MysticWorldTab=MysticMods (Мир) \ No newline at end of file diff --git a/common/assets/mysticworld/models/orb.obj b/common/assets/mysticworld/models/orb.obj new file mode 100644 index 0000000..355f618 --- /dev/null +++ b/common/assets/mysticworld/models/orb.obj @@ -0,0 +1,1962 @@ +# Blender v2.68 (sub 0) OBJ File: '' +# www.blender.org +mtllib orb.mtl +o Sphere +v -0.195090 0.980785 0.000000 +v -0.382683 0.923880 0.000000 +v -0.555570 0.831470 0.000000 +v -0.707107 0.707107 0.000000 +v -0.831470 0.555570 0.000000 +v -0.923880 0.382683 0.000000 +v -0.980785 0.195090 0.000000 +v -1.000000 0.000000 0.000000 +v -0.980785 -0.195090 0.000000 +v -0.923880 -0.382683 0.000000 +v -0.831470 -0.555570 0.000000 +v -0.707107 -0.707107 0.000000 +v -0.555570 -0.831470 0.000000 +v -0.382683 -0.923880 0.000000 +v -0.195090 -0.980785 0.000000 +v -0.191342 0.980785 -0.038060 +v -0.375330 0.923880 -0.074658 +v -0.544895 0.831470 -0.108386 +v -0.693520 0.707107 -0.137950 +v -0.815493 0.555570 -0.162212 +v -0.906127 0.382683 -0.180240 +v -0.961940 0.195090 -0.191342 +v -0.980785 0.000000 -0.195090 +v -0.961940 -0.195090 -0.191342 +v -0.906127 -0.382683 -0.180240 +v -0.815493 -0.555570 -0.162212 +v -0.693520 -0.707107 -0.137950 +v -0.544895 -0.831470 -0.108386 +v -0.375330 -0.923880 -0.074658 +v -0.191341 -0.980785 -0.038060 +v -0.180240 0.980785 -0.074658 +v -0.353553 0.923880 -0.146447 +v -0.513280 0.831470 -0.212608 +v -0.653281 0.707107 -0.270598 +v -0.768178 0.555570 -0.318190 +v -0.853553 0.382683 -0.353553 +v -0.906127 0.195090 -0.375330 +v -0.923880 0.000000 -0.382684 +v -0.906127 -0.195090 -0.375330 +v -0.853553 -0.382683 -0.353554 +v -0.768178 -0.555570 -0.318190 +v -0.653281 -0.707107 -0.270598 +v -0.513280 -0.831470 -0.212608 +v -0.353553 -0.923880 -0.146447 +v -0.180240 -0.980785 -0.074658 +v -0.162212 0.980785 -0.108387 +v -0.318190 0.923880 -0.212608 +v -0.461940 0.831470 -0.308658 +v -0.587938 0.707107 -0.392848 +v -0.691342 0.555570 -0.461940 +v -0.768178 0.382683 -0.513280 +v -0.815493 0.195090 -0.544895 +v -0.831470 0.000000 -0.555570 +v -0.815493 -0.195090 -0.544895 +v -0.768178 -0.382683 -0.513280 +v -0.691342 -0.555570 -0.461940 +v -0.587938 -0.707107 -0.392848 +v -0.461940 -0.831470 -0.308658 +v -0.318189 -0.923880 -0.212608 +v -0.162211 -0.980785 -0.108386 +v -0.137950 0.980785 -0.137950 +v -0.270598 0.923880 -0.270598 +v -0.392847 0.831470 -0.392848 +v -0.500000 0.707107 -0.500000 +v -0.587938 0.555570 -0.587938 +v -0.653281 0.382683 -0.653282 +v -0.693520 0.195090 -0.693520 +v -0.707107 0.000000 -0.707107 +v -0.693520 -0.195090 -0.693520 +v -0.653281 -0.382683 -0.653282 +v -0.587938 -0.555570 -0.587938 +v -0.500000 -0.707107 -0.500000 +v -0.392847 -0.831470 -0.392848 +v -0.270598 -0.923880 -0.270598 +v -0.137949 -0.980785 -0.137950 +v -0.108386 0.980785 -0.162212 +v -0.212607 0.923880 -0.318190 +v -0.308658 0.831470 -0.461940 +v -0.392847 0.707107 -0.587938 +v -0.461940 0.555570 -0.691342 +v -0.513280 0.382683 -0.768178 +v -0.544895 0.195090 -0.815493 +v -0.555570 0.000000 -0.831470 +v -0.544895 -0.195090 -0.815493 +v -0.513280 -0.382683 -0.768178 +v -0.461940 -0.555570 -0.691342 +v -0.392847 -0.707107 -0.587938 +v -0.308658 -0.831470 -0.461940 +v -0.212607 -0.923880 -0.318190 +v -0.108386 -0.980785 -0.162212 +v -0.074658 0.980785 -0.180240 +v -0.146446 0.923880 -0.353554 +v -0.212607 0.831470 -0.513280 +v -0.270598 0.707107 -0.653282 +v -0.318189 0.555570 -0.768178 +v -0.353553 0.382683 -0.853554 +v -0.375330 0.195090 -0.906128 +v -0.382683 0.000000 -0.923880 +v -0.375330 -0.195090 -0.906128 +v -0.353553 -0.382683 -0.853554 +v -0.318189 -0.555570 -0.768178 +v -0.270598 -0.707107 -0.653282 +v -0.212607 -0.831470 -0.513280 +v -0.146446 -0.923880 -0.353553 +v -0.074658 -0.980785 -0.180240 +v -0.038060 0.980785 -0.191342 +v -0.074658 0.923880 -0.375331 +v -0.108386 0.831470 -0.544895 +v -0.137949 0.707107 -0.693520 +v -0.162211 0.555570 -0.815493 +v -0.180240 0.382683 -0.906128 +v -0.191341 0.195090 -0.961940 +v -0.195090 0.000000 -0.980785 +v -0.191341 -0.195090 -0.961940 +v -0.180240 -0.382683 -0.906128 +v -0.162211 -0.555570 -0.815493 +v -0.137949 -0.707107 -0.693520 +v -0.108386 -0.831470 -0.544895 +v -0.074658 -0.923880 -0.375330 +v -0.038060 -0.980785 -0.191342 +v 0.000000 0.980785 -0.195091 +v 0.000000 0.923880 -0.382684 +v 0.000000 0.831470 -0.555570 +v 0.000000 0.707107 -0.707107 +v 0.000000 0.555570 -0.831470 +v 0.000000 0.382683 -0.923880 +v 0.000000 0.195090 -0.980785 +v 0.000000 0.000000 -1.000000 +v 0.000000 -0.195090 -0.980785 +v 0.000000 -0.382683 -0.923880 +v 0.000000 -0.555570 -0.831470 +v 0.000000 -0.707107 -0.707107 +v 0.000000 -0.831470 -0.555570 +v 0.000000 -0.923880 -0.382684 +v 0.000000 -0.980785 -0.195090 +v 0.038061 0.980785 -0.191342 +v 0.074658 0.923880 -0.375330 +v 0.108387 0.831470 -0.544895 +v 0.137950 0.707107 -0.693520 +v 0.162212 0.555570 -0.815493 +v 0.180240 0.382683 -0.906128 +v 0.191342 0.195090 -0.961940 +v 0.195091 0.000000 -0.980785 +v 0.191342 -0.195090 -0.961940 +v 0.180240 -0.382683 -0.906128 +v 0.162212 -0.555570 -0.815493 +v 0.137950 -0.707107 -0.693520 +v 0.108387 -0.831470 -0.544895 +v 0.074658 -0.923880 -0.375330 +v 0.038061 -0.980785 -0.191342 +v 0.074658 0.980785 -0.180240 +v 0.146447 0.923880 -0.353554 +v 0.212608 0.831470 -0.513280 +v 0.270598 0.707107 -0.653282 +v 0.318190 0.555570 -0.768178 +v 0.353554 0.382683 -0.853553 +v 0.375331 0.195090 -0.906127 +v 0.382684 0.000000 -0.923880 +v 0.375331 -0.195090 -0.906127 +v 0.353554 -0.382683 -0.853553 +v 0.318190 -0.555570 -0.768178 +v 0.270598 -0.707107 -0.653282 +v 0.212608 -0.831470 -0.513280 +v 0.146447 -0.923880 -0.353553 +v 0.074658 -0.980785 -0.180240 +v 0.108387 0.980785 -0.162212 +v 0.212608 0.923880 -0.318190 +v 0.308659 0.831470 -0.461940 +v 0.392848 0.707107 -0.587938 +v 0.461940 0.555570 -0.691342 +v 0.513280 0.382683 -0.768178 +v 0.544895 0.195090 -0.815493 +v 0.555571 0.000000 -0.831470 +v 0.544895 -0.195090 -0.815493 +v 0.513280 -0.382683 -0.768178 +v 0.461940 -0.555570 -0.691342 +v 0.392848 -0.707107 -0.587938 +v 0.308659 -0.831470 -0.461940 +v 0.212608 -0.923880 -0.318190 +v 0.108387 -0.980785 -0.162212 +v 0.137950 0.980785 -0.137950 +v 0.270599 0.923880 -0.270598 +v 0.392848 0.831470 -0.392847 +v 0.500000 0.707107 -0.500000 +v 0.587938 0.555570 -0.587938 +v 0.653282 0.382683 -0.653281 +v 0.693520 0.195090 -0.693520 +v 0.707107 0.000000 -0.707107 +v 0.693520 -0.195090 -0.693520 +v 0.653282 -0.382683 -0.653281 +v 0.587938 -0.555570 -0.587938 +v 0.500000 -0.707107 -0.500000 +v 0.392848 -0.831470 -0.392847 +v 0.270598 -0.923880 -0.270598 +v 0.137950 -0.980785 -0.137950 +v 0.162212 0.980785 -0.108387 +v 0.318190 0.923880 -0.212608 +v 0.461940 0.831470 -0.308658 +v 0.587938 0.707107 -0.392847 +v 0.691342 0.555570 -0.461940 +v 0.768178 0.382683 -0.513280 +v 0.815493 0.195090 -0.544895 +v 0.831470 0.000000 -0.555570 +v 0.815493 -0.195090 -0.544895 +v 0.768178 -0.382683 -0.513280 +v 0.691342 -0.555570 -0.461940 +v 0.587938 -0.707107 -0.392847 +v 0.461940 -0.831470 -0.308658 +v 0.318190 -0.923880 -0.212608 +v 0.162212 -0.980785 -0.108386 +v 0.180241 0.980785 -0.074658 +v 0.353554 0.923880 -0.146447 +v 0.513280 0.831470 -0.212607 +v 0.653282 0.707107 -0.270598 +v 0.768178 0.555570 -0.318190 +v 0.853554 0.382683 -0.353553 +v 0.906128 0.195090 -0.375330 +v 0.923880 0.000000 -0.382683 +v 0.906128 -0.195090 -0.375330 +v 0.853554 -0.382683 -0.353553 +v 0.768178 -0.555570 -0.318190 +v 0.653282 -0.707107 -0.270598 +v 0.513280 -0.831470 -0.212607 +v 0.353554 -0.923880 -0.146447 +v 0.180240 -0.980785 -0.074658 +v 0.191342 0.980785 -0.038060 +v 0.375331 0.923880 -0.074658 +v 0.544895 0.831470 -0.108386 +v 0.693520 0.707107 -0.137950 +v 0.815493 0.555570 -0.162212 +v 0.906128 0.382683 -0.180240 +v 0.961940 0.195090 -0.191342 +v 0.980785 0.000000 -0.195090 +v 0.961940 -0.195090 -0.191342 +v 0.906128 -0.382683 -0.180240 +v 0.815493 -0.555570 -0.162212 +v 0.693520 -0.707107 -0.137950 +v 0.544895 -0.831470 -0.108386 +v 0.375331 -0.923880 -0.074658 +v 0.191342 -0.980785 -0.038060 +v 0.195091 0.980785 0.000000 +v 0.382684 0.923880 0.000000 +v 0.555570 0.831470 0.000000 +v 0.707107 0.707107 0.000000 +v 0.831470 0.555570 0.000000 +v 0.923880 0.382683 0.000000 +v 0.980785 0.195090 0.000000 +v 1.000000 0.000000 0.000000 +v 0.980785 -0.195090 0.000000 +v 0.923880 -0.382683 0.000000 +v 0.831470 -0.555570 0.000000 +v 0.707107 -0.707107 0.000000 +v 0.555570 -0.831470 0.000000 +v 0.382684 -0.923880 0.000000 +v 0.195091 -0.980785 0.000000 +v 0.191342 0.980785 0.038060 +v 0.375331 0.923880 0.074658 +v 0.544895 0.831470 0.108386 +v 0.693520 0.707107 0.137950 +v 0.815493 0.555570 0.162212 +v 0.906128 0.382683 0.180240 +v 0.961940 0.195090 0.191342 +v 0.980785 0.000000 0.195090 +v 0.961940 -0.195090 0.191342 +v 0.906128 -0.382683 0.180240 +v 0.815493 -0.555570 0.162212 +v 0.693520 -0.707107 0.137950 +v 0.544895 -0.831470 0.108386 +v 0.375331 -0.923880 0.074658 +v 0.191342 -0.980785 0.038060 +v 0.180240 0.980785 0.074658 +v 0.353554 0.923880 0.146447 +v 0.513280 0.831470 0.212608 +v 0.653282 0.707107 0.270598 +v 0.768178 0.555570 0.318190 +v 0.853554 0.382683 0.353553 +v 0.906127 0.195090 0.375330 +v 0.923880 0.000000 0.382684 +v 0.906128 -0.195090 0.375330 +v 0.853553 -0.382683 0.353553 +v 0.768178 -0.555570 0.318190 +v 0.653282 -0.707107 0.270598 +v 0.513280 -0.831470 0.212608 +v 0.353554 -0.923880 0.146447 +v 0.180240 -0.980785 0.074658 +v 0.162212 0.980785 0.108387 +v 0.318190 0.923880 0.212608 +v 0.461940 0.831470 0.308658 +v 0.587938 0.707107 0.392847 +v 0.691342 0.555570 0.461940 +v 0.768178 0.382683 0.513280 +v 0.815493 0.195090 0.544895 +v 0.831470 0.000000 0.555570 +v 0.815493 -0.195090 0.544895 +v 0.768178 -0.382683 0.513280 +v 0.691342 -0.555570 0.461940 +v 0.587938 -0.707107 0.392847 +v 0.461940 -0.831470 0.308658 +v 0.318190 -0.923880 0.212608 +v 0.162212 -0.980785 0.108386 +v 0.137950 0.980785 0.137950 +v 0.270598 0.923880 0.270598 +v 0.392848 0.831470 0.392847 +v 0.500000 0.707107 0.500000 +v 0.587938 0.555570 0.587938 +v 0.653282 0.382683 0.653281 +v 0.693520 0.195090 0.693520 +v 0.707107 0.000000 0.707107 +v 0.693520 -0.195090 0.693520 +v 0.653282 -0.382683 0.653281 +v 0.587938 -0.555570 0.587938 +v 0.500000 -0.707107 0.500000 +v 0.392848 -0.831470 0.392847 +v 0.270598 -0.923880 0.270598 +v 0.137950 -0.980785 0.137950 +v 0.108387 0.980785 0.162212 +v 0.212608 0.923880 0.318190 +v 0.308658 0.831470 0.461940 +v 0.392848 0.707107 0.587938 +v 0.461940 0.555570 0.691342 +v 0.513280 0.382683 0.768178 +v 0.544895 0.195090 0.815493 +v 0.555570 0.000000 0.831470 +v 0.544895 -0.195090 0.815493 +v 0.513280 -0.382683 0.768178 +v 0.461940 -0.555570 0.691342 +v 0.392848 -0.707107 0.587938 +v 0.308658 -0.831470 0.461940 +v 0.212608 -0.923880 0.318190 +v 0.108387 -0.980785 0.162212 +v 0.000000 -1.000000 0.000000 +v 0.074658 0.980785 0.180240 +v 0.146447 0.923880 0.353554 +v 0.212608 0.831470 0.513280 +v 0.270598 0.707107 0.653281 +v 0.318190 0.555570 0.768178 +v 0.353553 0.382683 0.853553 +v 0.375330 0.195090 0.906127 +v 0.382683 0.000000 0.923879 +v 0.375330 -0.195090 0.906127 +v 0.353554 -0.382683 0.853553 +v 0.318190 -0.555570 0.768178 +v 0.270598 -0.707107 0.653281 +v 0.212608 -0.831470 0.513280 +v 0.146447 -0.923880 0.353553 +v 0.074658 -0.980785 0.180240 +v 0.038061 0.980785 0.191342 +v 0.074658 0.923880 0.375330 +v 0.108387 0.831470 0.544895 +v 0.137950 0.707107 0.693520 +v 0.162212 0.555570 0.815493 +v 0.180240 0.382683 0.906127 +v 0.191342 0.195090 0.961939 +v 0.195090 0.000000 0.980785 +v 0.191342 -0.195090 0.961939 +v 0.180240 -0.382683 0.906127 +v 0.162212 -0.555570 0.815493 +v 0.137950 -0.707107 0.693520 +v 0.108387 -0.831470 0.544895 +v 0.074658 -0.923880 0.375330 +v 0.038061 -0.980785 0.191342 +v 0.000000 0.980785 0.195091 +v 0.000000 0.923880 0.382683 +v 0.000000 0.831470 0.555570 +v 0.000000 0.707107 0.707107 +v 0.000000 0.555570 0.831469 +v 0.000000 0.382683 0.923879 +v 0.000000 0.195090 0.980785 +v 0.000000 0.000000 1.000000 +v 0.000000 -0.195090 0.980785 +v 0.000000 -0.382683 0.923879 +v 0.000000 -0.555570 0.831469 +v 0.000000 -0.707107 0.707107 +v 0.000000 -0.831470 0.555570 +v 0.000000 -0.923880 0.382683 +v 0.000000 -0.980785 0.195090 +v -0.038060 0.980785 0.191342 +v -0.074658 0.923880 0.375330 +v -0.108386 0.831470 0.544895 +v -0.137949 0.707107 0.693520 +v -0.162211 0.555570 0.815493 +v -0.180240 0.382683 0.906127 +v -0.191341 0.195090 0.961939 +v -0.195090 0.000000 0.980785 +v -0.191342 -0.195090 0.961939 +v -0.180240 -0.382683 0.906127 +v -0.162211 -0.555570 0.815493 +v -0.137949 -0.707107 0.693520 +v -0.108386 -0.831470 0.544895 +v -0.074658 -0.923880 0.375330 +v -0.038060 -0.980785 0.191342 +v -0.074658 0.980785 0.180240 +v -0.146446 0.923880 0.353553 +v -0.212607 0.831470 0.513280 +v -0.270598 0.707107 0.653281 +v -0.318189 0.555570 0.768177 +v -0.353553 0.382683 0.853553 +v -0.375330 0.195090 0.906127 +v -0.382683 0.000000 0.923879 +v -0.375330 -0.195090 0.906127 +v -0.353553 -0.382683 0.853553 +v -0.318189 -0.555570 0.768177 +v -0.270598 -0.707107 0.653281 +v -0.212607 -0.831470 0.513280 +v -0.146446 -0.923880 0.353553 +v -0.074658 -0.980785 0.180240 +v -0.108386 0.980785 0.162212 +v -0.212607 0.923880 0.318190 +v -0.308658 0.831470 0.461939 +v -0.392847 0.707107 0.587937 +v -0.461939 0.555570 0.691341 +v -0.513280 0.382683 0.768177 +v -0.544895 0.195090 0.815493 +v -0.555570 0.000000 0.831469 +v -0.544895 -0.195090 0.815493 +v -0.513279 -0.382683 0.768177 +v -0.461939 -0.555570 0.691341 +v -0.392847 -0.707107 0.587937 +v -0.308658 -0.831470 0.461939 +v -0.212607 -0.923880 0.318189 +v -0.108386 -0.980785 0.162212 +v -0.137950 0.980785 0.137950 +v -0.270598 0.923880 0.270598 +v -0.392847 0.831470 0.392847 +v -0.500000 0.707107 0.500000 +v -0.587937 0.555570 0.587937 +v -0.653281 0.382683 0.653281 +v -0.693519 0.195090 0.693519 +v -0.707106 0.000000 0.707106 +v -0.693520 -0.195090 0.693519 +v -0.653281 -0.382683 0.653281 +v -0.587937 -0.555570 0.587937 +v -0.500000 -0.707107 0.500000 +v -0.392847 -0.831470 0.392847 +v -0.270598 -0.923880 0.270598 +v -0.137949 -0.980785 0.137950 +v -0.162212 0.980785 0.108386 +v -0.318189 0.923880 0.212607 +v -0.461939 0.831470 0.308658 +v -0.587937 0.707107 0.392847 +v -0.691341 0.555570 0.461939 +v -0.768177 0.382683 0.513279 +v -0.815492 0.195090 0.544895 +v -0.831469 0.000000 0.555570 +v -0.815493 -0.195090 0.544895 +v -0.768177 -0.382683 0.513280 +v -0.691341 -0.555570 0.461939 +v -0.587937 -0.707107 0.392847 +v -0.461939 -0.831470 0.308658 +v -0.318189 -0.923880 0.212607 +v -0.162211 -0.980785 0.108386 +v 0.000000 1.000000 0.000000 +v -0.180240 0.980785 0.074658 +v -0.353553 0.923880 0.146446 +v -0.513279 0.831470 0.212607 +v -0.653281 0.707107 0.270598 +v -0.768177 0.555570 0.318189 +v -0.853553 0.382683 0.353553 +v -0.906127 0.195090 0.375330 +v -0.923879 0.000000 0.382683 +v -0.906127 -0.195090 0.375330 +v -0.853553 -0.382683 0.353553 +v -0.768177 -0.555570 0.318189 +v -0.653281 -0.707107 0.270598 +v -0.513279 -0.831470 0.212607 +v -0.353553 -0.923880 0.146446 +v -0.180240 -0.980785 0.074658 +v -0.191342 0.980785 0.038060 +v -0.375330 0.923880 0.074658 +v -0.544895 0.831470 0.108386 +v -0.693519 0.707107 0.137949 +v -0.815493 0.555570 0.162211 +v -0.906127 0.382683 0.180240 +v -0.961939 0.195090 0.191341 +v -0.980784 0.000000 0.195090 +v -0.961939 -0.195090 0.191341 +v -0.906127 -0.382683 0.180240 +v -0.815493 -0.555570 0.162211 +v -0.693519 -0.707107 0.137949 +v -0.544895 -0.831470 0.108386 +v -0.375330 -0.923880 0.074658 +v -0.191341 -0.980785 0.038060 +vt 0.225255 0.747791 +vt 0.200185 0.745510 +vt 0.202014 0.735870 +vt 0.083378 0.733891 +vt 0.045216 0.729934 +vt 0.089718 0.701687 +vt 0.132563 0.314124 +vt 0.159085 0.299902 +vt 0.147340 0.335836 +vt 0.116708 0.737324 +vt 0.103254 0.329885 +vt 0.146637 0.740347 +vt 0.121737 0.711556 +vt 0.069356 0.347937 +vt 0.121535 0.357021 +vt 0.206517 0.274331 +vt 0.228654 0.262287 +vt 0.231406 0.266316 +vt 0.174198 0.743051 +vt 0.150502 0.720360 +vt 0.029445 0.369408 +vt 0.091889 0.381279 +vt 0.183517 0.286764 +vt 0.212051 0.282443 +vt 0.177006 0.728389 +vt 0.000100 0.725360 +vt 0.053061 0.690360 +vt 0.191933 0.299115 +vt 0.226157 0.742999 +vt 0.205688 0.726773 +vt 0.068477 0.653078 +vt 0.170557 0.316746 +vt 0.166017 0.354256 +vt 0.102219 0.671338 +vt 0.131697 0.687265 +vt 0.120451 0.409593 +vt 0.234890 0.269729 +vt 0.158191 0.701512 +vt 0.056984 0.410042 +vt 0.202588 0.309583 +vt 0.182620 0.714557 +vt 0.009705 0.677072 +vt 0.028546 0.631587 +vt 0.185070 0.331027 +vt 0.219059 0.289318 +vt 0.215073 0.317772 +vt 0.190825 0.702086 +vt 0.055899 0.590652 +vt 0.202072 0.342206 +vt 0.227977 0.738475 +vt 0.211066 0.718568 +vt 0.090869 0.619520 +vt 0.187902 0.368689 +vt 0.120400 0.644012 +vt 0.144787 0.380062 +vt 0.172083 0.398133 +vt 0.146205 0.665384 +vt 0.238973 0.272397 +vt 0.169411 0.684525 +vt 0.091814 0.444541 +vt 0.153955 0.431817 +vt 0.202373 0.410550 +vt 0.227271 0.294693 +vt 0.236371 0.298363 +vt 0.183728 0.670054 +vt 0.132646 0.471641 +vt 0.191136 0.447112 +vt 0.228908 0.323369 +vt 0.201305 0.691455 +vt 0.119378 0.590975 +vt 0.220916 0.349860 +vt 0.230644 0.734393 +vt 0.234056 0.730909 +vt 0.143563 0.620758 +vt 0.212169 0.378591 +vt 0.164703 0.646753 +vt 0.170818 0.602470 +vt 0.234501 0.416839 +vt 0.186480 0.632090 +vt 0.230585 0.454892 +vt 0.243498 0.274217 +vt 0.248290 0.275119 +vt 0.200594 0.658655 +vt 0.177960 0.490317 +vt 0.246010 0.300188 +vt 0.217942 0.711569 +vt 0.213657 0.683073 +vt 0.090712 0.555840 +vt 0.131647 0.528489 +vt 0.240885 0.353700 +vt 0.226051 0.706046 +vt 0.238082 0.728159 +vt 0.235081 0.702211 +vt 0.152908 0.568541 +vt 0.201116 0.589850 +vt 0.237895 0.383583 +vt 0.261217 0.353579 +vt 0.267242 0.416758 +vt 0.219359 0.650764 +vt 0.253166 0.275070 +vt 0.226053 0.499845 +vt 0.275101 0.499845 +vt 0.243564 0.326164 +vt 0.255818 0.300099 +vt 0.227408 0.677262 +vt 0.190169 0.553079 +vt 0.244686 0.700212 +vt 0.177131 0.509649 +vt 0.229732 0.545184 +vt 0.258482 0.326051 +vt 0.281135 0.349501 +vt 0.242568 0.726246 +vt 0.233295 0.583384 +vt 0.264101 0.383473 +vt 0.210699 0.621956 +vt 0.299347 0.410306 +vt 0.239303 0.646686 +vt 0.270804 0.454854 +vt 0.265420 0.298100 +vt 0.323232 0.490300 +vt 0.257938 0.274070 +vt 0.262423 0.272159 +vt 0.242028 0.674245 +vt 0.259660 0.646578 +vt 0.310258 0.446989 +vt 0.368604 0.471560 +vt 0.273091 0.323033 +vt 0.286831 0.317227 +vt 0.254497 0.700125 +vt 0.225417 0.500045 +vt 0.274648 0.500045 +vt 0.299879 0.341621 +vt 0.247340 0.725246 +vt 0.266116 0.583319 +vt 0.289785 0.378264 +vt 0.236430 0.616742 +vt 0.329588 0.397724 +vt 0.262683 0.616648 +vt 0.313967 0.368151 +vt 0.356806 0.379489 +vt 0.279646 0.650442 +vt 0.347437 0.431590 +vt 0.274448 0.294268 +vt 0.266450 0.269410 +vt 0.256956 0.674139 +vt 0.409474 0.444332 +vt 0.299176 0.308854 +vt 0.264136 0.701954 +vt 0.270074 0.545159 +vt 0.309646 0.553004 +vt 0.316729 0.330240 +vt 0.252216 0.725196 +vt 0.298320 0.589659 +vt 0.346927 0.568418 +vt 0.335718 0.353520 +vt 0.331040 0.315792 +vt 0.288451 0.621678 +vt 0.328668 0.602160 +vt 0.379955 0.356294 +vt 0.312741 0.631638 +vt 0.380916 0.409238 +vt 0.282555 0.288749 +vt 0.269863 0.265928 +vt 0.271617 0.676946 +vt 0.298495 0.658132 +vt 0.444269 0.409650 +vt 0.289430 0.281755 +vt 0.273233 0.705628 +vt 0.322933 0.509649 +vt 0.257008 0.726098 +vt 0.285450 0.682561 +vt 0.281439 0.711006 +vt 0.368417 0.528488 +vt 0.380485 0.590809 +vt 0.309653 0.298235 +vt 0.342262 0.298829 +vt 0.261532 0.727917 +vt 0.355994 0.620341 +vt 0.354206 0.334928 +vt 0.398144 0.329027 +vt 0.334623 0.646146 +vt 0.409408 0.380782 +vt 0.272531 0.261848 +vt 0.315481 0.669351 +vt 0.471647 0.368836 +vt 0.294810 0.273555 +vt 0.274352 0.257325 +vt 0.297921 0.690765 +vt 0.329952 0.683669 +vt 0.431815 0.347310 +vt 0.447272 0.310101 +vt 0.317860 0.285776 +vt 0.323481 0.271955 +vt 0.288438 0.717882 +vt 0.409352 0.555839 +vt 0.444165 0.590651 +vt 0.349962 0.280001 +vt 0.265614 0.730584 +vt 0.379248 0.643503 +vt 0.368718 0.313085 +vt 0.410673 0.298729 +vt 0.353253 0.664643 +vt 0.378696 0.288828 +vt 0.417056 0.266562 +vt 0.367917 0.686420 +vt 0.298488 0.264462 +vt 0.275256 0.252534 +vt 0.308552 0.701245 +vt 0.341352 0.700534 +vt 0.490551 0.323453 +vt 0.455180 0.270580 +vt 0.300322 0.254827 +vt 0.293961 0.725991 +vt 0.409030 0.619318 +vt 0.431466 0.652847 +vt 0.353845 0.260029 +vt 0.269097 0.733996 +vt 0.397537 0.670758 +vt 0.383754 0.263085 +vt 0.410157 0.701056 +vt 0.353758 0.239681 +vt 0.417043 0.233759 +vt 0.378051 0.710639 +vt 0.275208 0.247658 +vt 0.316934 0.713598 +vt 0.349243 0.719300 +vt 0.500246 0.275239 +vt 0.455230 0.230265 +vt 0.326298 0.257302 +vt 0.300241 0.245018 +vt 0.322745 0.727349 +vt 0.471518 0.631585 +vt 0.490359 0.677070 +vt 0.271848 0.738023 +vt 0.297795 0.735022 +vt 0.299795 0.744627 +vt 0.446928 0.690109 +vt 0.454824 0.729672 +vt 0.326204 0.242379 +vt 0.349704 0.219736 +vt 0.273760 0.742508 +vt 0.416624 0.733235 +vt 0.383694 0.236844 +vt 0.378518 0.211113 +vt 0.410632 0.201581 +vt 0.383265 0.736370 +vt 0.274210 0.242885 +vt 0.353321 0.739244 +vt 0.500353 0.226044 +vt 0.447414 0.190702 +vt 0.298248 0.235412 +vt 0.325761 0.741969 +vt 0.353429 0.759600 +vt 0.490860 0.177758 +vt 0.472125 0.132236 +vt 0.323201 0.227758 +vt 0.317403 0.214003 +vt 0.325868 0.756896 +vt 0.499965 0.725357 +vt 0.454850 0.770016 +vt 0.341835 0.200963 +vt 0.274761 0.747281 +vt 0.299881 0.754438 +vt 0.416688 0.766057 +vt 0.398063 0.171264 +vt 0.383359 0.762624 +vt 0.272300 0.238399 +vt 0.378329 0.788391 +vt 0.432026 0.153414 +vt 0.379817 0.143974 +vt 0.294420 0.226379 +vt 0.288902 0.218266 +vt 0.349564 0.779587 +vt 0.444860 0.091230 +vt 0.309031 0.201641 +vt 0.323060 0.771558 +vt 0.499965 0.774590 +vt 0.490359 0.822877 +vt 0.330453 0.184082 +vt 0.274811 0.752156 +vt 0.298053 0.764077 +vt 0.410348 0.798261 +vt 0.368419 0.186882 +vt 0.353783 0.165081 +vt 0.315993 0.169744 +vt 0.397847 0.828609 +vt 0.356591 0.120763 +vt 0.368368 0.812683 +vt 0.409652 0.119834 +vt 0.269552 0.234371 +vt 0.281907 0.211384 +vt 0.341874 0.798436 +vt 0.410106 0.056322 +vt 0.317446 0.785390 +vt 0.447004 0.809588 +vt 0.471518 0.868362 +vt 0.273909 0.756948 +vt 0.294379 0.773174 +vt 0.431588 0.846870 +vt 0.444165 0.909296 +vt 0.298407 0.191149 +vt 0.285937 0.182932 +vt 0.272090 0.761472 +vt 0.289000 0.781379 +vt 0.379665 0.855935 +vt 0.335171 0.146551 +vt 0.299010 0.158502 +vt 0.329274 0.102527 +vt 0.353860 0.834563 +vt 0.381148 0.091257 +vt 0.266070 0.230957 +vt 0.261988 0.228288 +vt 0.330655 0.815422 +vt 0.369195 0.028858 +vt 0.273702 0.206000 +vt 0.309241 0.797861 +vt 0.316338 0.829893 +vt 0.347606 0.068785 +vt 0.310311 0.053289 +vt 0.264604 0.202320 +vt 0.282125 0.788378 +vt 0.409196 0.880428 +vt 0.380687 0.908971 +vt 0.280156 0.150790 +vt 0.269423 0.765554 +vt 0.356502 0.879189 +vt 0.313295 0.132007 +vt 0.288996 0.122010 +vt 0.335363 0.853194 +vt 0.298915 0.089970 +vt 0.257465 0.226466 +vt 0.313586 0.867857 +vt 0.266681 0.083580 +vt 0.252672 0.225562 +vt 0.298761 0.808492 +vt 0.299472 0.841292 +vt 0.323696 0.009902 +vt 0.270697 0.045369 +vt 0.272103 0.177305 +vt 0.254962 0.200486 +vt 0.274016 0.793901 +vt 0.409352 0.944107 +vt 0.368417 0.971457 +vt 0.260157 0.146905 +vt 0.266010 0.769038 +vt 0.329248 0.897477 +vt 0.263208 0.116948 +vt 0.239780 0.147001 +vt 0.298949 0.910096 +vt 0.236922 0.117019 +vt 0.289367 0.877990 +vt 0.230285 0.045337 +vt 0.247796 0.225611 +vt 0.286409 0.816874 +vt 0.280707 0.849182 +vt 0.275354 0.000188 +vt 0.257434 0.174487 +vt 0.245148 0.200570 +vt 0.272658 0.822685 +vt 0.347157 0.931405 +vt 0.322933 0.990296 +vt 0.261984 0.771788 +vt 0.264985 0.797736 +vt 0.309896 0.946866 +vt 0.274648 0.999900 +vt 0.242496 0.174587 +vt 0.219813 0.151075 +vt 0.257499 0.773701 +vt 0.255380 0.799735 +vt 0.266771 0.916562 +vt 0.233811 0.083608 +vt 0.211151 0.122224 +vt 0.260763 0.853260 +vt 0.190633 0.053201 +vt 0.243022 0.226611 +vt 0.226029 0.000100 +vt 0.227864 0.177601 +vt 0.258038 0.825701 +vt 0.240407 0.853369 +vt 0.177617 0.009651 +vt 0.153269 0.068666 +vt 0.235538 0.202568 +vt 0.226504 0.206403 +vt 0.243111 0.825808 +vt 0.270334 0.954761 +vt 0.225418 0.999900 +vt 0.201023 0.158972 +vt 0.252726 0.774701 +vt 0.245569 0.799822 +vt 0.233950 0.916627 +vt 0.263636 0.883204 +vt 0.201571 0.090057 +vt 0.171205 0.102684 +vt 0.237383 0.883298 +vt 0.211616 0.878268 +vt 0.119638 0.091145 +vt 0.238536 0.228522 +vt 0.234509 0.231273 +vt 0.220420 0.849504 +vt 0.131984 0.028484 +vt 0.214102 0.183416 +vt 0.201741 0.191807 +vt 0.228449 0.823000 +vt 0.229992 0.954787 +vt 0.177134 0.990295 +vt 0.184138 0.170388 +vt 0.247850 0.774751 +vt 0.235930 0.797993 +vt 0.201747 0.910287 +vt 0.186890 0.132366 +vt 0.143886 0.121008 +vt 0.171399 0.897786 +vt 0.165075 0.147055 +vt 0.146552 0.165728 +vt 0.187325 0.868308 +vt 0.091044 0.119777 +vt 0.218392 0.211929 +vt 0.231097 0.234756 +vt 0.201572 0.841815 +vt 0.090895 0.055886 +vt 0.211516 0.218931 +vt 0.214617 0.817386 +vt 0.190421 0.946942 +vt 0.131651 0.971456 +vt 0.169810 0.184885 +vt 0.243058 0.773849 +vt 0.226833 0.794319 +vt 0.191258 0.202450 +vt 0.158594 0.201902 +vt 0.238534 0.772030 +vt 0.218627 0.788941 +vt 0.153140 0.931527 +vt 0.144074 0.879606 +vt 0.120673 0.144325 +vt 0.132038 0.187664 +vt 0.165444 0.853801 +vt 0.068599 0.153461 +vt 0.228430 0.238838 +vt 0.184586 0.830596 +vt 0.055942 0.090813 +vt 0.206141 0.227140 +vt 0.090717 0.944106 +vt 0.028491 0.131928 +vt 0.053184 0.190897 +vt 0.183058 0.214934 +vt 0.177458 0.228777 +vt 0.202146 0.809182 +vt 0.191515 0.798702 +vt 0.119583 0.909137 +vt 0.055904 0.909296 +vt 0.150924 0.220780 +vt 0.234452 0.769363 +vt 0.211629 0.782065 +vt 0.120819 0.856444 +vt 0.122098 0.212014 +vt 0.102468 0.171737 +vt 0.146814 0.835304 +vt 0.226611 0.243361 +vt 0.170115 0.816278 +vt 0.132150 0.813527 +vt 0.089978 0.202184 +vt 0.045407 0.230630 +vt 0.202473 0.236239 +vt 0.225710 0.248151 +vt 0.158715 0.799413 +vt 0.009624 0.177645 +vt 0.174671 0.243442 +vt 0.183133 0.786349 +vt 0.091038 0.880630 +vt 0.028551 0.868363 +vt 0.147097 0.240787 +vt 0.230969 0.765951 +vt 0.206106 0.773956 +vt 0.102531 0.829190 +vt 0.117118 0.237835 +vt 0.089910 0.798892 +vt 0.083689 0.234486 +vt 0.117297 0.264119 +vt 0.122016 0.789308 +vt 0.045571 0.271108 +vt 0.200651 0.245876 +vt 0.225760 0.253025 +vt 0.150824 0.780648 +vt 0.000100 0.226189 +vt 0.200746 0.255680 +vt 0.202271 0.764925 +vt 0.068603 0.847101 +vt 0.009709 0.822880 +vt 0.147262 0.261143 +vt 0.228218 0.761924 +vt 0.226306 0.757439 +vt 0.174805 0.258361 +vt 0.151408 0.281052 +vt 0.200272 0.755320 +vt 0.053139 0.809840 +vt 0.083443 0.766713 +vt 0.122641 0.289821 +vt 0.083834 0.267394 +vt 0.116802 0.763577 +vt 0.053666 0.310742 +vt 0.226759 0.257795 +vt 0.177322 0.772599 +vt 0.146746 0.760704 +vt 0.000312 0.275649 +vt 0.202750 0.265274 +vt 0.000102 0.774593 +vt 0.250033 0.749973 +vt 0.250481 0.250342 +vt 0.225305 0.752666 +vt 0.010250 0.324041 +vt 0.177847 0.272958 +vt 0.174305 0.757979 +vt 0.045242 0.770277 +vt 0.090373 0.299673 +usemtl None +s off +f 15/1 14/2 29/3 +f 10/4 9/5 25/6 +f 5/7 4/8 20/9 +f 11/10 10/4 25/6 +f 6/11 5/7 20/9 +f 12/12 11/10 26/13 +f 7/14 6/11 21/15 +f 2/16 1/17 16/18 +f 13/19 12/12 27/20 +f 8/21 7/14 22/22 +f 3/23 2/16 17/24 +f 14/2 13/19 28/25 +f 9/5 8/26 24/27 +f 4/8 3/23 18/28 +f 30/29 29/3 44/30 +f 25/6 24/27 39/31 +f 20/9 19/32 35/33 +f 26/13 25/6 40/34 +f 21/15 20/9 35/33 +f 27/20 26/13 41/35 +f 22/22 21/15 37/36 +f 17/24 16/18 31/37 +f 28/25 27/20 42/38 +f 23/39 22/22 37/36 +f 18/28 17/24 33/40 +f 29/3 28/25 43/41 +f 24/27 23/42 38/43 +f 19/32 18/28 34/44 +f 33/40 32/45 48/46 +f 44/30 43/41 58/47 +f 39/31 38/43 53/48 +f 34/44 33/40 49/49 +f 45/50 44/30 59/51 +f 40/34 39/31 54/52 +f 35/33 34/44 50/53 +f 41/35 40/34 55/54 +f 36/55 35/33 51/56 +f 42/38 41/35 56/57 +f 37/36 36/55 51/56 +f 32/45 31/37 46/58 +f 43/41 42/38 57/59 +f 38/60 37/36 52/61 +f 52/61 51/56 66/62 +f 47/63 46/58 62/64 +f 58/47 57/59 72/65 +f 53/66 52/61 67/67 +f 48/46 47/63 63/68 +f 59/51 58/47 73/69 +f 54/52 53/48 69/70 +f 49/49 48/46 64/71 +f 60/72 59/51 75/73 +f 55/54 54/52 70/74 +f 50/53 49/49 65/75 +f 56/57 55/54 70/74 +f 51/56 50/53 66/62 +f 57/59 56/57 71/76 +f 71/76 70/74 85/77 +f 66/62 65/75 81/78 +f 72/65 71/76 86/79 +f 67/67 66/62 82/80 +f 62/64 61/81 76/82 +f 73/69 72/65 87/83 +f 68/84 67/67 82/80 +f 63/68 62/64 77/85 +f 74/86 73/69 88/87 +f 69/70 68/88 83/89 +f 64/71 63/68 79/90 +f 75/73 74/86 89/91 +f 70/74 69/70 85/77 +f 65/75 64/71 79/90 +f 90/92 89/91 104/93 +f 85/77 84/94 100/95 +f 80/96 79/90 94/97 +f 86/79 85/77 100/95 +f 81/78 80/96 96/98 +f 87/83 86/79 102/99 +f 82/80 81/78 96/98 +f 77/85 76/82 91/100 +f 88/87 87/83 102/99 +f 83/101 82/80 98/102 +f 78/103 77/85 92/104 +f 89/91 88/87 103/105 +f 84/94 83/89 99/106 +f 79/90 78/103 94/97 +f 104/93 103/105 119/107 +f 99/106 98/108 114/109 +f 94/97 93/110 109/111 +f 105/112 104/93 119/107 +f 100/95 99/106 115/113 +f 95/114 94/97 109/111 +f 101/115 100/95 115/113 +f 96/98 95/114 111/116 +f 102/99 101/115 117/117 +f 97/118 96/98 111/116 +f 92/104 91/100 107/119 +f 103/105 102/99 117/117 +f 98/102 97/118 113/120 +f 93/110 92/104 107/119 +f 107/119 106/121 121/122 +f 118/123 117/117 132/124 +f 113/120 112/125 128/126 +f 108/127 107/119 123/128 +f 119/107 118/123 134/129 +f 114/109 113/130 128/131 +f 109/111 108/127 124/132 +f 120/133 119/107 134/129 +f 115/113 114/109 130/134 +f 110/135 109/111 124/132 +f 116/136 115/113 130/134 +f 111/116 110/135 126/137 +f 117/117 116/136 131/138 +f 112/125 111/116 126/137 +f 126/137 125/139 141/140 +f 132/124 131/138 147/141 +f 127/142 126/137 141/140 +f 122/143 121/122 136/144 +f 133/145 132/124 147/141 +f 128/126 127/142 143/146 +f 123/128 122/143 138/147 +f 134/129 133/145 149/148 +f 129/149 128/131 144/150 +f 124/132 123/128 139/151 +f 135/152 134/129 149/148 +f 130/134 129/149 145/153 +f 125/139 124/132 139/151 +f 131/138 130/134 145/153 +f 145/153 144/150 159/154 +f 140/155 139/151 154/156 +f 146/157 145/153 160/158 +f 141/140 140/155 156/159 +f 147/141 146/157 161/160 +f 142/161 141/140 156/159 +f 137/162 136/144 151/163 +f 148/164 147/141 162/165 +f 143/146 142/161 158/166 +f 138/147 137/162 152/167 +f 149/148 148/164 164/168 +f 144/150 143/169 159/154 +f 139/151 138/147 154/156 +f 150/170 149/148 164/168 +f 164/168 163/171 179/172 +f 159/154 158/173 174/174 +f 154/156 153/175 169/176 +f 165/177 164/168 179/172 +f 160/158 159/154 175/178 +f 155/179 154/156 169/176 +f 161/160 160/158 175/178 +f 156/159 155/179 171/180 +f 162/165 161/160 176/181 +f 157/182 156/159 171/180 +f 152/167 151/163 166/183 +f 163/171 162/165 177/184 +f 158/166 157/182 173/185 +f 153/175 152/167 167/186 +f 167/186 166/183 181/187 +f 178/188 177/184 192/189 +f 173/185 172/190 187/191 +f 168/192 167/186 183/193 +f 179/172 178/188 194/194 +f 174/174 173/195 188/196 +f 169/176 168/192 184/197 +f 180/198 179/172 194/194 +f 175/178 174/174 190/199 +f 170/200 169/176 184/197 +f 176/181 175/178 190/199 +f 171/180 170/200 186/201 +f 177/184 176/181 191/202 +f 172/190 171/180 186/201 +f 186/201 185/203 201/204 +f 192/189 191/202 206/205 +f 187/191 186/201 201/204 +f 182/206 181/187 196/207 +f 193/208 192/189 207/209 +f 188/210 187/191 202/211 +f 183/193 182/206 197/212 +f 194/194 193/208 209/213 +f 189/214 188/196 204/215 +f 184/197 183/193 199/216 +f 195/217 194/194 209/213 +f 190/199 189/214 205/218 +f 185/203 184/197 200/219 +f 191/202 190/199 205/218 +f 205/218 204/215 220/220 +f 200/219 199/216 214/221 +f 206/205 205/218 220/220 +f 201/204 200/219 216/222 +f 207/209 206/205 221/223 +f 202/211 201/204 216/222 +f 197/212 196/207 211/224 +f 208/225 207/209 222/226 +f 203/227 202/211 217/228 +f 198/229 197/212 212/230 +f 209/213 208/225 223/231 +f 204/215 203/232 218/233 +f 199/216 198/229 214/221 +f 210/234 209/213 224/235 +f 224/235 223/231 239/236 +f 219/237 218/233 234/238 +f 214/221 213/239 229/240 +f 225/241 224/235 239/236 +f 220/220 219/237 235/242 +f 215/243 214/221 230/244 +f 221/223 220/220 235/242 +f 216/222 215/243 231/245 +f 222/226 221/223 236/246 +f 217/228 216/222 231/245 +f 212/230 211/224 226/247 +f 223/231 222/226 237/248 +f 218/249 217/228 232/250 +f 213/239 212/230 227/251 +f 238/252 237/248 252/253 +f 233/254 232/250 248/255 +f 228/256 227/251 243/257 +f 239/236 238/252 253/258 +f 234/238 233/259 249/260 +f 229/240 228/256 244/261 +f 240/262 239/236 254/263 +f 235/242 234/238 250/264 +f 230/244 229/240 244/261 +f 236/246 235/242 250/264 +f 231/245 230/244 246/265 +f 237/248 236/246 251/266 +f 232/250 231/245 246/265 +f 227/251 226/247 241/267 +f 252/253 251/266 266/268 +f 247/269 246/265 261/270 +f 242/271 241/267 257/272 +f 253/258 252/253 267/273 +f 248/255 247/269 263/274 +f 243/257 242/271 258/275 +f 254/263 253/258 268/276 +f 249/260 248/277 263/278 +f 244/261 243/257 259/279 +f 255/280 254/263 269/281 +f 250/264 249/260 265/282 +f 245/283 244/261 259/279 +f 251/266 250/264 265/282 +f 246/265 245/283 261/270 +f 260/284 259/279 274/285 +f 266/268 265/282 280/286 +f 261/270 260/284 276/287 +f 267/273 266/268 281/288 +f 262/289 261/270 276/287 +f 257/272 256/290 272/291 +f 268/276 267/273 282/292 +f 263/274 262/289 278/293 +f 258/275 257/272 272/291 +f 269/281 268/276 283/294 +f 264/295 263/278 278/296 +f 259/279 258/275 274/285 +f 270/297 269/281 284/298 +f 265/282 264/295 280/286 +f 279/299 278/296 293/300 +f 274/285 273/301 288/302 +f 285/303 284/298 299/304 +f 280/286 279/299 295/305 +f 275/306 274/285 289/307 +f 281/288 280/286 295/305 +f 276/287 275/306 291/308 +f 282/292 281/288 296/309 +f 277/310 276/287 291/308 +f 272/291 271/311 286/312 +f 283/294 282/292 297/313 +f 278/293 277/310 293/314 +f 273/301 272/291 287/315 +f 284/298 283/294 299/304 +f 298/316 297/313 312/317 +f 293/314 292/318 307/319 +f 288/302 287/315 302/320 +f 299/304 298/316 314/321 +f 294/322 293/300 309/323 +f 289/307 288/302 304/324 +f 300/325 299/304 314/321 +f 295/305 294/322 310/326 +f 290/327 289/307 304/324 +f 296/309 295/305 310/326 +f 291/308 290/327 305/328 +f 297/313 296/309 311/329 +f 292/318 291/308 306/330 +f 287/315 286/312 301/331 +f 312/317 311/329 326/332 +f 307/319 306/330 321/333 +f 302/320 301/331 316/334 +f 313/335 312/317 327/336 +f 308/337 307/319 322/338 +f 303/339 302/320 317/340 +f 314/321 313/335 329/341 +f 309/323 308/342 323/343 +f 304/324 303/339 319/344 +f 315/345 314/321 329/341 +f 310/326 309/323 325/346 +f 305/328 304/324 319/344 +f 311/329 310/326 325/346 +f 306/330 305/328 320/347 +f 320/347 319/344 335/348 +f 326/332 325/346 341/349 +f 321/333 320/347 336/350 +f 327/336 326/332 342/351 +f 322/338 321/333 338/352 +f 317/340 316/334 332/353 +f 328/354 327/336 343/355 +f 323/356 322/338 338/352 +f 318/357 317/340 333/358 +f 329/341 328/354 344/359 +f 324/360 323/343 339/361 +f 319/344 318/357 335/348 +f 330/362 329/341 345/363 +f 325/346 324/360 341/349 +f 340/364 339/361 354/365 +f 335/348 334/366 350/367 +f 346/368 345/363 360/369 +f 341/349 340/364 356/370 +f 336/350 335/348 350/367 +f 342/351 341/349 356/370 +f 337/371 336/350 351/372 +f 343/355 342/351 358/373 +f 338/352 337/371 353/374 +f 333/358 332/353 347/375 +f 344/359 343/355 358/373 +f 339/376 338/352 353/374 +f 334/366 333/358 349/377 +f 345/363 344/359 359/378 +f 359/378 358/373 373/379 +f 354/380 353/374 368/381 +f 349/377 348/382 363/383 +f 360/369 359/378 374/384 +f 355/385 354/365 369/386 +f 350/367 349/377 365/387 +f 361/388 360/369 375/389 +f 356/370 355/385 371/390 +f 351/372 350/367 365/387 +f 357/391 356/370 371/390 +f 352/392 351/372 367/393 +f 358/373 357/391 373/379 +f 353/374 352/392 368/381 +f 348/382 347/375 363/383 +f 373/379 372/394 387/395 +f 368/381 367/393 383/396 +f 363/383 362/397 377/398 +f 374/384 373/379 388/399 +f 369/400 368/381 383/396 +f 364/401 363/383 379/402 +f 375/389 374/384 389/403 +f 370/404 369/386 384/405 +f 365/387 364/401 380/406 +f 376/407 375/389 390/408 +f 371/390 370/404 386/409 +f 366/410 365/387 380/406 +f 372/394 371/390 386/409 +f 367/393 366/410 382/411 +f 387/395 386/409 401/412 +f 382/411 381/413 396/414 +f 388/399 387/395 402/415 +f 383/396 382/411 398/416 +f 378/417 377/398 392/418 +f 389/403 388/399 403/419 +f 384/420 383/396 398/416 +f 379/402 378/417 393/421 +f 390/408 389/403 404/422 +f 385/423 384/405 399/424 +f 380/406 379/402 395/425 +f 391/426 390/408 405/427 +f 386/409 385/423 401/412 +f 381/413 380/406 396/414 +f 395/425 394/428 410/429 +f 406/430 405/427 420/431 +f 401/412 400/432 416/433 +f 396/414 395/425 410/429 +f 402/415 401/412 416/433 +f 397/434 396/414 411/435 +f 403/419 402/415 417/436 +f 398/416 397/434 413/437 +f 393/421 392/418 407/438 +f 404/422 403/419 418/439 +f 399/440 398/416 413/437 +f 394/428 393/421 408/441 +f 405/427 404/422 420/431 +f 400/432 399/424 414/442 +f 414/443 413/437 428/444 +f 409/445 408/441 424/446 +f 420/431 419/447 434/448 +f 415/449 414/442 429/450 +f 410/429 409/445 425/451 +f 421/452 420/431 435/453 +f 416/433 415/449 431/454 +f 411/435 410/429 426/455 +f 417/436 416/433 431/454 +f 412/456 411/435 426/455 +f 418/439 417/436 432/457 +f 413/437 412/456 428/444 +f 408/441 407/438 422/458 +f 419/447 418/439 433/459 +f 433/459 432/457 447/460 +f 428/444 427/461 443/462 +f 423/463 422/458 437/464 +f 434/448 433/459 448/465 +f 429/466 428/444 443/462 +f 424/446 423/463 439/467 +f 435/453 434/448 449/468 +f 430/469 429/450 444/470 +f 425/451 424/446 440/471 +f 436/472 435/453 450/473 +f 431/454 430/469 446/474 +f 426/455 425/451 441/475 +f 432/457 431/454 446/474 +f 427/461 426/455 441/475 +f 447/460 446/474 462/476 +f 442/477 441/475 457/478 +f 448/465 447/460 463/479 +f 443/462 442/477 459/480 +f 438/481 437/464 453/482 +f 449/468 448/465 464/483 +f 444/484 443/462 459/480 +f 439/467 438/481 454/485 +f 450/473 449/468 466/486 +f 445/487 444/470 460/488 +f 440/471 439/467 456/489 +f 451/490 450/473 467/491 +f 446/474 445/487 462/476 +f 441/475 440/471 456/489 +f 456/489 455/492 471/493 +f 467/491 466/486 481/494 +f 462/476 461/495 477/496 +f 457/478 456/489 472/497 +f 463/479 462/476 477/496 +f 458/498 457/478 472/497 +f 464/483 463/479 478/499 +f 459/480 458/498 474/500 +f 454/485 453/482 468/501 +f 465/502 464/483 479/503 +f 460/504 459/480 474/500 +f 455/492 454/485 469/505 +f 466/486 465/502 481/494 +f 461/495 460/488 475/506 +f 331/507 15/1 30/29 +f 1/17 452/508 16/18 +f 331/507 30/29 45/50 +f 16/18 452/508 31/37 +f 331/507 45/50 60/72 +f 31/37 452/508 46/58 +f 331/507 60/72 75/73 +f 46/58 452/508 61/81 +f 61/81 452/508 76/82 +f 331/507 75/73 90/92 +f 331/507 90/92 105/112 +f 76/82 452/508 91/100 +f 331/507 105/112 120/133 +f 91/100 452/508 106/121 +f 331/507 120/133 135/152 +f 106/121 452/508 121/122 +f 121/122 452/508 136/144 +f 331/507 135/152 150/170 +f 331/507 150/170 165/177 +f 136/144 452/508 151/163 +f 331/507 165/177 180/198 +f 151/163 452/508 166/183 +f 331/507 180/198 195/217 +f 166/183 452/508 181/187 +f 181/187 452/508 196/207 +f 331/507 195/217 210/234 +f 331/507 210/234 225/241 +f 196/207 452/508 211/224 +f 331/507 225/241 240/262 +f 211/224 452/508 226/247 +f 331/507 240/262 255/280 +f 226/247 452/508 241/267 +f 241/267 452/508 256/290 +f 331/507 255/280 270/297 +f 331/507 270/297 285/303 +f 256/290 452/508 271/311 +f 331/507 285/303 300/325 +f 271/311 452/508 286/312 +f 331/507 300/325 315/345 +f 286/312 452/508 301/331 +f 301/331 452/508 316/334 +f 331/507 315/345 330/362 +f 331/507 330/362 346/368 +f 316/334 452/508 332/353 +f 331/507 346/368 361/388 +f 332/353 452/508 347/375 +f 331/507 361/388 376/407 +f 347/375 452/508 362/397 +f 331/507 376/407 391/426 +f 362/397 452/508 377/398 +f 331/507 391/426 406/430 +f 377/398 452/508 392/418 +f 331/507 406/430 421/452 +f 392/418 452/508 407/438 +f 331/507 421/452 436/472 +f 407/438 452/508 422/458 +f 331/507 436/472 451/490 +f 422/458 452/508 437/464 +f 331/507 451/490 467/491 +f 437/464 452/508 453/482 +f 331/507 467/491 482/509 +f 453/482 452/508 468/501 +f 475/510 474/500 7/14 +f 470/511 469/505 2/16 +f 481/494 480/512 14/2 +f 476/513 475/506 8/26 +f 471/493 470/511 3/23 +f 482/509 481/494 15/1 +f 477/496 476/513 10/4 +f 472/497 471/493 4/8 +f 331/507 482/509 15/1 +f 478/499 477/496 11/10 +f 473/514 472/497 5/7 +f 468/501 452/508 1/17 +f 479/503 478/499 12/12 +f 474/500 473/514 6/11 +f 469/505 468/501 1/17 +f 480/512 479/503 13/19 +f 30/29 15/1 29/3 +f 183/193 198/229 199/216 +f 456/489 471/493 472/497 +f 26/13 11/10 25/6 +f 21/15 6/11 20/9 +f 27/20 12/12 26/13 +f 22/22 7/14 21/15 +f 17/24 2/16 16/18 +f 28/25 13/19 27/20 +f 23/39 8/21 22/22 +f 18/28 3/23 17/24 +f 29/3 14/2 28/25 +f 321/333 337/371 338/352 +f 19/32 4/8 18/28 +f 45/50 30/29 44/30 +f 40/34 25/6 39/31 +f 380/406 395/425 396/414 +f 41/35 26/13 40/34 +f 36/55 21/15 35/33 +f 42/38 27/20 41/35 +f 54/52 69/70 70/74 +f 32/45 17/24 31/37 +f 43/41 28/25 42/38 +f 38/60 23/39 37/36 +f 242/271 257/272 258/275 +f 44/30 29/3 43/41 +f 39/31 24/27 38/43 +f 4/8 19/32 20/9 +f 342/351 357/391 358/373 +f 59/51 44/30 58/47 +f 54/52 39/31 53/48 +f 449/468 465/502 466/486 +f 60/72 45/50 59/51 +f 55/54 40/34 54/52 +f 247/269 262/289 263/274 +f 56/57 41/35 55/54 +f 214/221 229/240 230/244 +f 57/59 42/38 56/57 +f 52/61 37/36 51/56 +f 47/63 32/45 46/58 +f 58/47 43/41 57/59 +f 53/66 38/60 52/61 +f 67/67 52/61 66/62 +f 241/267 256/290 257/272 +f 73/69 58/47 72/65 +f 68/84 53/66 67/67 +f 84/94 99/106 100/95 +f 74/86 59/51 73/69 +f 83/89 98/108 99/106 +f 33/40 48/46 49/49 +f 256/290 271/311 272/291 +f 157/182 172/190 173/185 +f 465/502 480/512 481/494 +f 71/76 56/57 70/74 +f 142/161 157/182 158/166 +f 72/65 57/59 71/76 +f 86/79 71/76 85/77 +f 168/192 183/193 184/197 +f 87/83 72/65 86/79 +f 423/463 438/481 439/467 +f 77/85 62/64 76/82 +f 88/87 73/69 87/83 +f 83/101 68/84 82/80 +f 78/103 63/68 77/85 +f 89/91 74/86 88/87 +f 84/94 69/70 83/89 +f 122/143 137/162 138/147 +f 90/92 75/73 89/91 +f 333/358 348/382 349/377 +f 80/96 65/75 79/90 +f 105/112 90/92 104/93 +f 143/169 158/173 159/154 +f 95/114 80/96 94/97 +f 101/115 86/79 100/95 +f 334/366 349/377 350/367 +f 148/164 163/171 164/168 +f 97/118 82/80 96/98 +f 92/104 77/85 91/100 +f 103/105 88/87 102/99 +f 69/70 84/94 85/77 +f 93/110 78/103 92/104 +f 104/93 89/91 103/105 +f 193/208 208/225 209/213 +f 48/46 63/68 64/71 +f 49/49 64/71 65/75 +f 114/109 129/149 130/134 +f 249/260 264/295 265/282 +f 120/133 105/112 119/107 +f 101/115 116/136 117/117 +f 110/135 95/114 109/111 +f 116/136 101/115 115/113 +f 234/238 249/260 250/264 +f 9/5 24/27 25/6 +f 112/125 97/118 111/116 +f 450/473 466/486 467/491 +f 118/123 103/105 117/117 +f 112/125 127/142 128/126 +f 108/127 93/110 107/119 +f 122/143 107/119 121/122 +f 133/145 118/123 132/124 +f 35/33 50/53 51/56 +f 184/197 199/216 200/219 +f 66/62 81/78 82/80 +f 129/149 114/109 128/131 +f 108/127 123/128 124/132 +f 135/152 120/133 134/129 +f 298/316 313/335 314/321 +f 125/139 110/135 124/132 +f 131/138 116/136 130/134 +f 337/371 352/392 353/374 +f 132/124 117/117 131/138 +f 127/142 112/125 126/137 +f 243/257 258/275 259/279 +f 347/375 362/397 363/383 +f 142/161 127/142 141/140 +f 137/162 122/143 136/144 +f 148/164 133/145 147/141 +f 53/48 68/88 69/70 +f 128/131 143/169 144/150 +f 47/63 62/64 63/68 +f 163/171 178/188 179/172 +f 80/96 95/114 96/98 +f 150/170 135/152 149/148 +f 167/186 182/206 183/193 +f 140/155 125/139 139/151 +f 146/157 131/138 145/153 +f 160/158 145/153 159/154 +f 155/179 140/155 154/156 +f 161/160 146/157 160/158 +f 318/357 334/366 335/348 +f 162/165 147/141 161/160 +f 157/182 142/161 156/159 +f 152/167 137/162 151/163 +f 163/171 148/164 162/165 +f 158/173 173/195 174/174 +f 153/175 138/147 152/167 +f 19/32 34/44 35/33 +f 357/391 372/394 373/379 +f 138/147 153/175 154/156 +f 165/177 150/170 164/168 +f 18/28 33/40 34/44 +f 233/259 248/277 249/260 +f 153/175 168/192 169/176 +f 180/198 165/177 179/172 +f 228/256 243/257 244/261 +f 170/200 155/179 169/176 +f 176/181 161/160 175/178 +f 34/44 49/49 50/53 +f 177/184 162/165 176/181 +f 172/190 157/182 171/180 +f 167/186 152/167 166/183 +f 178/188 163/171 177/184 +f 223/231 238/252 239/236 +f 168/192 153/175 167/186 +f 182/206 167/186 181/187 +f 193/208 178/188 192/189 +f 188/210 173/185 187/191 +f 313/335 328/354 329/341 +f 363/383 378/417 379/402 +f 189/214 174/174 188/196 +f 382/411 397/434 398/416 +f 195/217 180/198 194/194 +f 425/451 440/471 441/475 +f 185/203 170/200 184/197 +f 191/202 176/181 190/199 +f 170/200 185/203 186/201 +f 192/189 177/184 191/202 +f 187/191 172/190 186/201 +f 185/203 200/219 201/204 +f 207/209 192/189 206/205 +f 202/211 187/191 201/204 +f 197/212 182/206 196/207 +f 208/225 193/208 207/209 +f 203/227 188/210 202/211 +f 198/229 183/193 197/212 +f 219/237 234/238 235/242 +f 127/142 142/161 143/146 +f 404/422 419/447 420/431 +f 210/234 195/217 209/213 +f 140/155 155/179 156/159 +f 218/233 233/259 234/238 +f 206/205 191/202 205/218 +f 213/239 228/256 229/240 +f 215/243 200/219 214/221 +f 221/223 206/205 220/220 +f 200/219 215/243 216/222 +f 222/226 207/209 221/223 +f 217/228 202/211 216/222 +f 212/230 197/212 211/224 +f 223/231 208/225 222/226 +f 218/249 203/227 217/228 +f 213/239 198/229 212/230 +f 224/235 209/213 223/231 +f 219/237 204/215 218/233 +f 198/229 213/239 214/221 +f 225/241 210/234 224/235 +f 99/106 114/109 115/113 +f 78/103 93/110 94/97 +f 260/284 275/306 276/287 +f 240/262 225/241 239/236 +f 204/215 219/237 220/220 +f 21/15 36/55 37/36 +f 236/246 221/223 235/242 +f 215/243 230/244 231/245 +f 237/248 222/226 236/246 +f 232/250 217/228 231/245 +f 227/251 212/230 226/247 +f 238/252 223/231 237/248 +f 233/254 218/249 232/250 +f 228/256 213/239 227/251 +f 253/258 238/252 252/253 +f 107/119 122/143 123/128 +f 232/250 247/269 248/255 +f 254/263 239/236 253/258 +f 97/118 112/125 113/120 +f 227/251 242/271 243/257 +f 255/280 240/262 254/263 +f 188/196 203/232 204/215 +f 245/283 230/244 244/261 +f 251/266 236/246 250/264 +f 230/244 245/283 246/265 +f 252/253 237/248 251/266 +f 247/269 232/250 246/265 +f 242/271 227/251 241/267 +f 267/273 252/253 266/268 +f 262/289 247/269 261/270 +f 91/100 106/121 107/119 +f 268/276 253/258 267/273 +f 50/53 65/75 66/62 +f 159/154 174/174 175/178 +f 269/281 254/263 268/276 +f 264/295 249/260 263/278 +f 262/289 277/310 278/293 +f 270/297 255/280 269/281 +f 125/139 140/155 141/140 +f 260/284 245/283 259/279 +f 266/268 251/266 265/282 +f 245/283 260/284 261/270 +f 275/306 260/284 274/285 +f 281/288 266/268 280/286 +f 93/110 108/127 109/111 +f 282/292 267/273 281/288 +f 277/310 262/289 276/287 +f 46/58 61/81 62/64 +f 283/294 268/276 282/292 +f 110/135 125/139 126/137 +f 273/301 258/275 272/291 +f 284/298 269/281 283/294 +f 279/299 264/295 278/296 +f 258/275 273/301 274/285 +f 285/303 270/297 284/298 +f 189/214 204/215 205/218 +f 294/322 279/299 293/300 +f 289/307 274/285 288/302 +f 300/325 285/303 299/304 +f 264/295 279/299 280/286 +f 290/327 275/306 289/307 +f 296/309 281/288 295/305 +f 133/145 148/164 149/148 +f 297/313 282/292 296/309 +f 292/318 277/310 291/308 +f 287/315 272/291 286/312 +f 298/316 283/294 297/313 +f 178/188 193/208 194/194 +f 288/302 273/301 287/315 +f 277/310 292/318 293/314 +f 313/335 298/316 312/317 +f 308/337 293/314 307/319 +f 303/339 288/302 302/320 +f 131/138 146/157 147/141 +f 283/294 298/316 299/304 +f 95/114 110/135 111/116 +f 315/345 300/325 314/321 +f 123/128 138/147 139/151 +f 305/328 290/327 304/324 +f 311/329 296/309 310/326 +f 306/330 291/308 305/328 +f 312/317 297/313 311/329 +f 307/319 292/318 306/330 +f 302/320 287/315 301/331 +f 327/336 312/317 326/332 +f 322/338 307/319 321/333 +f 317/340 302/320 316/334 +f 328/354 313/335 327/336 +f 323/356 308/337 322/338 +f 318/357 303/339 317/340 +f 293/300 308/342 309/323 +f 324/360 309/323 323/343 +f 8/26 23/42 24/27 +f 330/362 315/345 329/341 +f 309/323 324/360 325/346 +f 320/347 305/328 319/344 +f 326/332 311/329 325/346 +f 321/333 306/330 320/347 +f 336/350 320/347 335/348 +f 342/351 326/332 341/349 +f 337/371 321/333 336/350 +f 343/355 327/336 342/351 +f 349/377 364/401 365/387 +f 333/358 317/340 332/353 +f 344/359 328/354 343/355 +f 339/376 323/356 338/352 +f 334/366 318/357 333/358 +f 345/363 329/341 344/359 +f 340/364 324/360 339/361 +f 288/302 303/339 304/324 +f 346/368 330/362 345/363 +f 324/360 340/364 341/349 +f 355/385 340/364 354/365 +f 303/339 318/357 319/344 +f 361/388 346/368 360/369 +f 340/364 355/385 356/370 +f 351/372 336/350 350/367 +f 357/391 342/351 356/370 +f 352/392 337/371 351/372 +f 129/149 144/150 145/153 +f 294/322 309/323 310/326 +f 348/382 333/358 347/375 +f 359/378 344/359 358/373 +f 354/380 339/376 353/374 +f 118/123 133/145 134/129 +f 360/369 345/363 359/378 +f 374/384 359/378 373/379 +f 369/400 354/380 368/381 +f 364/401 349/377 363/383 +f 375/389 360/369 374/384 +f 370/404 355/385 369/386 +f 352/392 367/393 368/381 +f 376/407 361/388 375/389 +f 355/385 370/404 371/390 +f 366/410 351/372 365/387 +f 372/394 357/391 371/390 +f 439/467 455/492 456/489 +f 32/45 47/63 48/46 +f 351/372 366/410 367/393 +f 59/51 74/86 75/73 +f 388/399 373/379 387/395 +f 279/299 294/322 295/305 +f 378/417 363/383 377/398 +f 389/403 374/384 388/399 +f 384/420 369/400 383/396 +f 17/24 32/45 33/40 +f 390/408 375/389 389/403 +f 385/423 370/404 384/405 +f 65/75 80/96 81/78 +f 391/426 376/407 390/408 +f 370/404 385/423 386/409 +f 381/413 366/410 380/406 +f 387/395 372/394 386/409 +f 397/434 412/456 413/437 +f 402/415 387/395 401/412 +f 397/434 382/411 396/414 +f 403/419 388/399 402/415 +f 366/410 381/413 382/411 +f 393/421 378/417 392/418 +f 404/422 389/403 403/419 +f 399/440 384/420 398/416 +f 394/428 379/402 393/421 +f 405/427 390/408 404/422 +f 400/432 385/423 399/424 +f 379/402 394/428 395/425 +f 406/430 391/426 405/427 +f 385/423 400/432 401/412 +f 82/80 97/118 98/102 +f 364/401 379/402 380/406 +f 421/452 406/430 420/431 +f 400/432 415/449 416/433 +f 411/435 396/414 410/429 +f 417/436 402/415 416/433 +f 412/456 397/434 411/435 +f 418/439 403/419 417/436 +f 155/179 170/200 171/180 +f 408/441 393/421 407/438 +f 419/447 404/422 418/439 +f 414/443 399/440 413/437 +f 409/445 394/428 408/441 +f 103/105 118/123 119/107 +f 415/449 400/432 414/442 +f 429/466 414/443 428/444 +f 275/306 290/327 291/308 +f 435/453 420/431 434/448 +f 430/469 415/449 429/450 +f 409/445 424/446 425/451 +f 436/472 421/452 435/453 +f 415/449 430/469 431/454 +f 408/441 423/463 424/446 +f 432/457 417/436 431/454 +f 427/461 412/456 426/455 +f 433/459 418/439 432/457 +f 412/456 427/461 428/444 +f 423/463 408/441 422/458 +f 434/448 419/447 433/459 +f 448/465 433/459 447/460 +f 427/461 442/477 443/462 +f 438/481 423/463 437/464 +f 449/468 434/448 448/465 +f 444/484 429/466 443/462 +f 98/108 113/130 114/109 +f 450/473 435/453 449/468 +f 445/487 430/469 444/470 +f 424/446 439/467 440/471 +f 451/490 436/472 450/473 +f 430/469 445/487 446/474 +f 410/429 425/451 426/455 +f 447/460 432/457 446/474 +f 442/477 427/461 441/475 +f 463/479 447/460 462/476 +f 458/498 442/477 457/478 +f 464/483 448/465 463/479 +f 442/477 458/498 459/480 +f 454/485 438/481 453/482 +f 465/502 449/468 464/483 +f 460/504 444/484 459/480 +f 455/492 439/467 454/485 +f 63/68 78/103 79/90 +f 461/495 445/487 460/488 +f 394/428 409/445 410/429 +f 445/487 461/495 462/476 +f 457/478 441/475 456/489 +f 455/492 470/511 471/493 +f 482/509 467/491 481/494 +f 461/495 476/513 477/496 +f 86/79 101/115 102/99 +f 478/499 463/479 477/496 +f 473/514 458/498 472/497 +f 479/503 464/483 478/499 +f 458/498 473/514 474/500 +f 469/505 454/485 468/501 +f 480/512 465/502 479/503 +f 475/510 460/504 474/500 +f 470/511 455/492 469/505 +f 174/174 189/214 190/199 +f 476/513 461/495 475/506 +f 8/21 475/510 7/14 +f 3/23 470/511 2/16 +f 480/512 13/19 14/2 +f 9/5 476/513 8/26 +f 4/8 471/493 3/23 +f 481/494 14/2 15/1 +f 476/513 9/5 10/4 +f 5/7 472/497 4/8 +f 477/496 10/4 11/10 +f 6/11 473/514 5/7 +f 478/499 11/10 12/12 +f 7/14 474/500 6/11 +f 2/16 469/505 1/17 +f 479/503 12/12 13/19 +f 367/393 382/411 383/396 diff --git a/common/assets/mysticmods/textures/blocks/Air Imbued Stone.png b/common/assets/mysticworld/textures/blocks/Air Imbued Stone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Air Imbued Stone.png rename to common/assets/mysticworld/textures/blocks/Air Imbued Stone.png diff --git a/common/assets/mysticmods/textures/blocks/Air Imbued Stone.png.mcmeta b/common/assets/mysticworld/textures/blocks/Air Imbued Stone.png.mcmeta similarity index 100% rename from common/assets/mysticmods/textures/blocks/Air Imbued Stone.png.mcmeta rename to common/assets/mysticworld/textures/blocks/Air Imbued Stone.png.mcmeta diff --git a/common/assets/mysticmods/textures/blocks/Bush.png b/common/assets/mysticworld/textures/blocks/Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Bush.png rename to common/assets/mysticworld/textures/blocks/Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Earth Imbued Stone.png b/common/assets/mysticworld/textures/blocks/Earth Imbued Stone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Earth Imbued Stone.png rename to common/assets/mysticworld/textures/blocks/Earth Imbued Stone.png diff --git a/common/assets/mysticmods/textures/blocks/Earth Imbued Stone.png.mcmeta b/common/assets/mysticworld/textures/blocks/Earth Imbued Stone.png.mcmeta similarity index 100% rename from common/assets/mysticmods/textures/blocks/Earth Imbued Stone.png.mcmeta rename to common/assets/mysticworld/textures/blocks/Earth Imbued Stone.png.mcmeta diff --git a/common/assets/mysticmods/textures/blocks/Energy Imbued Stone.png b/common/assets/mysticworld/textures/blocks/Energy Imbued Stone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Energy Imbued Stone.png rename to common/assets/mysticworld/textures/blocks/Energy Imbued Stone.png diff --git a/common/assets/mysticmods/textures/blocks/Energy Imbued Stone.png.mcmeta b/common/assets/mysticworld/textures/blocks/Energy Imbued Stone.png.mcmeta similarity index 100% rename from common/assets/mysticmods/textures/blocks/Energy Imbued Stone.png.mcmeta rename to common/assets/mysticworld/textures/blocks/Energy Imbued Stone.png.mcmeta diff --git a/common/assets/mysticmods/textures/blocks/Fire Imbued Stone.png b/common/assets/mysticworld/textures/blocks/Fire Imbued Stone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Fire Imbued Stone.png rename to common/assets/mysticworld/textures/blocks/Fire Imbued Stone.png diff --git a/common/assets/mysticmods/textures/blocks/Fire Imbued Stone.png.mcmeta b/common/assets/mysticworld/textures/blocks/Fire Imbued Stone.png.mcmeta similarity index 100% rename from common/assets/mysticmods/textures/blocks/Fire Imbued Stone.png.mcmeta rename to common/assets/mysticworld/textures/blocks/Fire Imbued Stone.png.mcmeta diff --git a/common/assets/mysticmods/textures/blocks/Fire Resistance Bush.png b/common/assets/mysticworld/textures/blocks/Fire Resistance Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Fire Resistance Bush.png rename to common/assets/mysticworld/textures/blocks/Fire Resistance Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Harming Bush.png b/common/assets/mysticworld/textures/blocks/Harming Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Harming Bush.png rename to common/assets/mysticworld/textures/blocks/Harming Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Health Bush.png b/common/assets/mysticworld/textures/blocks/Health Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Health Bush.png rename to common/assets/mysticworld/textures/blocks/Health Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Invisibility Bush.png b/common/assets/mysticworld/textures/blocks/Invisibility Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Invisibility Bush.png rename to common/assets/mysticworld/textures/blocks/Invisibility Bush.png diff --git a/common/assets/mysticworld/textures/blocks/MysticDirt.png b/common/assets/mysticworld/textures/blocks/MysticDirt.png new file mode 100644 index 0000000..e3bf989 Binary files /dev/null and b/common/assets/mysticworld/textures/blocks/MysticDirt.png differ diff --git a/common/assets/mysticmods/textures/blocks/MysticGrass__side_snowed.png b/common/assets/mysticworld/textures/blocks/MysticGrass__side_snowed.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/MysticGrass__side_snowed.png rename to common/assets/mysticworld/textures/blocks/MysticGrass__side_snowed.png diff --git a/common/assets/mysticmods/textures/blocks/MysticGrass__top.png b/common/assets/mysticworld/textures/blocks/MysticGrass__top.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/MysticGrass__top.png rename to common/assets/mysticworld/textures/blocks/MysticGrass__top.png diff --git a/common/assets/mysticmods/textures/blocks/MysticGrass_side.png b/common/assets/mysticworld/textures/blocks/MysticGrass_side.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/MysticGrass_side.png rename to common/assets/mysticworld/textures/blocks/MysticGrass_side.png diff --git a/common/assets/mysticmods/textures/blocks/MysticGrass_side_overlay.png b/common/assets/mysticworld/textures/blocks/MysticGrass_side_overlay.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/MysticGrass_side_overlay.png rename to common/assets/mysticworld/textures/blocks/MysticGrass_side_overlay.png diff --git a/common/assets/mysticmods/textures/blocks/Night Vision Bush.png b/common/assets/mysticworld/textures/blocks/Night Vision Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Night Vision Bush.png rename to common/assets/mysticworld/textures/blocks/Night Vision Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Pillar.png b/common/assets/mysticworld/textures/blocks/Pillar.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Pillar.png rename to common/assets/mysticworld/textures/blocks/Pillar.png diff --git a/common/assets/mysticmods/textures/blocks/Platform.png b/common/assets/mysticworld/textures/blocks/Platform.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Platform.png rename to common/assets/mysticworld/textures/blocks/Platform.png diff --git a/common/assets/mysticmods/textures/blocks/Poisonous Bush.png b/common/assets/mysticworld/textures/blocks/Poisonous Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Poisonous Bush.png rename to common/assets/mysticworld/textures/blocks/Poisonous Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Regen Bush.png b/common/assets/mysticworld/textures/blocks/Regen Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Regen Bush.png rename to common/assets/mysticworld/textures/blocks/Regen Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Slowness Bush.png b/common/assets/mysticworld/textures/blocks/Slowness Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Slowness Bush.png rename to common/assets/mysticworld/textures/blocks/Slowness Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Speed Bush.png b/common/assets/mysticworld/textures/blocks/Speed Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Speed Bush.png rename to common/assets/mysticworld/textures/blocks/Speed Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Water Imbued Stone.png b/common/assets/mysticworld/textures/blocks/Water Imbued Stone.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Water Imbued Stone.png rename to common/assets/mysticworld/textures/blocks/Water Imbued Stone.png diff --git a/common/assets/mysticmods/textures/blocks/Water Imbued Stone.png.mcmeta b/common/assets/mysticworld/textures/blocks/Water Imbued Stone.png.mcmeta similarity index 100% rename from common/assets/mysticmods/textures/blocks/Water Imbued Stone.png.mcmeta rename to common/assets/mysticworld/textures/blocks/Water Imbued Stone.png.mcmeta diff --git a/common/assets/mysticmods/textures/blocks/Weakness Bush.png b/common/assets/mysticworld/textures/blocks/Weakness Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Weakness Bush.png rename to common/assets/mysticworld/textures/blocks/Weakness Bush.png diff --git a/common/assets/mysticmods/textures/blocks/Wither Bush.png b/common/assets/mysticworld/textures/blocks/Wither Bush.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/Wither Bush.png rename to common/assets/mysticworld/textures/blocks/Wither Bush.png diff --git a/common/assets/mysticmods/textures/blocks/lightCube.png b/common/assets/mysticworld/textures/blocks/lightCube.png similarity index 100% rename from common/assets/mysticmods/textures/blocks/lightCube.png rename to common/assets/mysticworld/textures/blocks/lightCube.png diff --git a/common/assets/mysticmods/textures/items/AdamantineArmor_0.png b/common/assets/mysticworld/textures/items/AdamantineArmor_0.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineArmor_0.png rename to common/assets/mysticworld/textures/items/AdamantineArmor_0.png diff --git a/common/assets/mysticmods/textures/items/AdamantineArmor_1.png b/common/assets/mysticworld/textures/items/AdamantineArmor_1.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineArmor_1.png rename to common/assets/mysticworld/textures/items/AdamantineArmor_1.png diff --git a/common/assets/mysticmods/textures/items/AdamantineArmor_2.png b/common/assets/mysticworld/textures/items/AdamantineArmor_2.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineArmor_2.png rename to common/assets/mysticworld/textures/items/AdamantineArmor_2.png diff --git a/common/assets/mysticmods/textures/items/AdamantineArmor_3.png b/common/assets/mysticworld/textures/items/AdamantineArmor_3.png similarity index 100% rename from common/assets/mysticmods/textures/items/AdamantineArmor_3.png rename to common/assets/mysticworld/textures/items/AdamantineArmor_3.png diff --git a/common/assets/mysticmods/textures/items/ChargeAir.png b/common/assets/mysticworld/textures/items/ChargeAir.png similarity index 100% rename from common/assets/mysticmods/textures/items/ChargeAir.png rename to common/assets/mysticworld/textures/items/ChargeAir.png diff --git a/common/assets/mysticmods/textures/items/ChargeEarth.png b/common/assets/mysticworld/textures/items/ChargeEarth.png similarity index 100% rename from common/assets/mysticmods/textures/items/ChargeEarth.png rename to common/assets/mysticworld/textures/items/ChargeEarth.png diff --git a/common/assets/mysticmods/textures/items/ChargeEnergy.png b/common/assets/mysticworld/textures/items/ChargeEnergy.png similarity index 100% rename from common/assets/mysticmods/textures/items/ChargeEnergy.png rename to common/assets/mysticworld/textures/items/ChargeEnergy.png diff --git a/common/assets/mysticmods/textures/items/ChargeFire.png b/common/assets/mysticworld/textures/items/ChargeFire.png similarity index 100% rename from common/assets/mysticmods/textures/items/ChargeFire.png rename to common/assets/mysticworld/textures/items/ChargeFire.png diff --git a/common/assets/mysticmods/textures/items/ChargeWater.png b/common/assets/mysticworld/textures/items/ChargeWater.png similarity index 100% rename from common/assets/mysticmods/textures/items/ChargeWater.png rename to common/assets/mysticworld/textures/items/ChargeWater.png diff --git a/common/assets/mysticmods/textures/items/FruitFireResistance.png b/common/assets/mysticworld/textures/items/FruitFireResistance.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitFireResistance.png rename to common/assets/mysticworld/textures/items/FruitFireResistance.png diff --git a/common/assets/mysticmods/textures/items/FruitHarming.png b/common/assets/mysticworld/textures/items/FruitHarming.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitHarming.png rename to common/assets/mysticworld/textures/items/FruitHarming.png diff --git a/common/assets/mysticmods/textures/items/FruitHealth.png b/common/assets/mysticworld/textures/items/FruitHealth.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitHealth.png rename to common/assets/mysticworld/textures/items/FruitHealth.png diff --git a/common/assets/mysticmods/textures/items/FruitInvisibility.png b/common/assets/mysticworld/textures/items/FruitInvisibility.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitInvisibility.png rename to common/assets/mysticworld/textures/items/FruitInvisibility.png diff --git a/common/assets/mysticmods/textures/items/FruitMundane.png b/common/assets/mysticworld/textures/items/FruitMundane.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitMundane.png rename to common/assets/mysticworld/textures/items/FruitMundane.png diff --git a/common/assets/mysticmods/textures/items/FruitNightVision.png b/common/assets/mysticworld/textures/items/FruitNightVision.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitNightVision.png rename to common/assets/mysticworld/textures/items/FruitNightVision.png diff --git a/common/assets/mysticmods/textures/items/FruitPoison.png b/common/assets/mysticworld/textures/items/FruitPoison.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitPoison.png rename to common/assets/mysticworld/textures/items/FruitPoison.png diff --git a/common/assets/mysticmods/textures/items/FruitRegen.png b/common/assets/mysticworld/textures/items/FruitRegen.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitRegen.png rename to common/assets/mysticworld/textures/items/FruitRegen.png diff --git a/common/assets/mysticmods/textures/items/FruitSlowness.png b/common/assets/mysticworld/textures/items/FruitSlowness.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitSlowness.png rename to common/assets/mysticworld/textures/items/FruitSlowness.png diff --git a/common/assets/mysticmods/textures/items/FruitSpeed.png b/common/assets/mysticworld/textures/items/FruitSpeed.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitSpeed.png rename to common/assets/mysticworld/textures/items/FruitSpeed.png diff --git a/common/assets/mysticmods/textures/items/FruitWeakness.png b/common/assets/mysticworld/textures/items/FruitWeakness.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitWeakness.png rename to common/assets/mysticworld/textures/items/FruitWeakness.png diff --git a/common/assets/mysticmods/textures/items/FruitWither.png b/common/assets/mysticworld/textures/items/FruitWither.png similarity index 100% rename from common/assets/mysticmods/textures/items/FruitWither.png rename to common/assets/mysticworld/textures/items/FruitWither.png diff --git a/common/assets/mysticmods/textures/items/IridiumArmor_0.png b/common/assets/mysticworld/textures/items/IridiumArmor_0.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumArmor_0.png rename to common/assets/mysticworld/textures/items/IridiumArmor_0.png diff --git a/common/assets/mysticmods/textures/items/IridiumArmor_1.png b/common/assets/mysticworld/textures/items/IridiumArmor_1.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumArmor_1.png rename to common/assets/mysticworld/textures/items/IridiumArmor_1.png diff --git a/common/assets/mysticmods/textures/items/IridiumArmor_2.png b/common/assets/mysticworld/textures/items/IridiumArmor_2.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumArmor_2.png rename to common/assets/mysticworld/textures/items/IridiumArmor_2.png diff --git a/common/assets/mysticmods/textures/items/IridiumArmor_3.png b/common/assets/mysticworld/textures/items/IridiumArmor_3.png similarity index 100% rename from common/assets/mysticmods/textures/items/IridiumArmor_3.png rename to common/assets/mysticworld/textures/items/IridiumArmor_3.png diff --git a/common/assets/mysticmods/textures/items/MithrilArmor_0.png b/common/assets/mysticworld/textures/items/MithrilArmor_0.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilArmor_0.png rename to common/assets/mysticworld/textures/items/MithrilArmor_0.png diff --git a/common/assets/mysticmods/textures/items/MithrilArmor_1.png b/common/assets/mysticworld/textures/items/MithrilArmor_1.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilArmor_1.png rename to common/assets/mysticworld/textures/items/MithrilArmor_1.png diff --git a/common/assets/mysticmods/textures/items/MithrilArmor_2.png b/common/assets/mysticworld/textures/items/MithrilArmor_2.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilArmor_2.png rename to common/assets/mysticworld/textures/items/MithrilArmor_2.png diff --git a/common/assets/mysticmods/textures/items/MithrilArmor_3.png b/common/assets/mysticworld/textures/items/MithrilArmor_3.png similarity index 100% rename from common/assets/mysticmods/textures/items/MithrilArmor_3.png rename to common/assets/mysticworld/textures/items/MithrilArmor_3.png diff --git a/common/assets/mysticmods/textures/items/ShardAir.png b/common/assets/mysticworld/textures/items/ShardAir.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardAir.png rename to common/assets/mysticworld/textures/items/ShardAir.png diff --git a/common/assets/mysticmods/textures/items/ShardEarth.png b/common/assets/mysticworld/textures/items/ShardEarth.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardEarth.png rename to common/assets/mysticworld/textures/items/ShardEarth.png diff --git a/common/assets/mysticmods/textures/items/ShardEnergy.png b/common/assets/mysticworld/textures/items/ShardEnergy.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardEnergy.png rename to common/assets/mysticworld/textures/items/ShardEnergy.png diff --git a/common/assets/mysticmods/textures/items/ShardFire.png b/common/assets/mysticworld/textures/items/ShardFire.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardFire.png rename to common/assets/mysticworld/textures/items/ShardFire.png diff --git a/common/assets/mysticmods/textures/items/ShardVoid.png b/common/assets/mysticworld/textures/items/ShardVoid.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardVoid.png rename to common/assets/mysticworld/textures/items/ShardVoid.png diff --git a/common/assets/mysticmods/textures/items/ShardWater.png b/common/assets/mysticworld/textures/items/ShardWater.png similarity index 100% rename from common/assets/mysticmods/textures/items/ShardWater.png rename to common/assets/mysticworld/textures/items/ShardWater.png diff --git a/common/assets/mysticmods/textures/items/StaffPart_Handle.png b/common/assets/mysticworld/textures/items/StaffPart_Handle.png similarity index 100% rename from common/assets/mysticmods/textures/items/StaffPart_Handle.png rename to common/assets/mysticworld/textures/items/StaffPart_Handle.png diff --git a/common/assets/mysticmods/textures/items/StaffPart_Head.png b/common/assets/mysticworld/textures/items/StaffPart_Head.png similarity index 100% rename from common/assets/mysticmods/textures/items/StaffPart_Head.png rename to common/assets/mysticworld/textures/items/StaffPart_Head.png diff --git a/common/assets/mysticmods/textures/items/StaffPart_Hilt.png b/common/assets/mysticworld/textures/items/StaffPart_Hilt.png similarity index 100% rename from common/assets/mysticmods/textures/items/StaffPart_Hilt.png rename to common/assets/mysticworld/textures/items/StaffPart_Hilt.png diff --git a/common/assets/mysticmods/textures/items/StaffPart_Staff.png b/common/assets/mysticworld/textures/items/StaffPart_Staff.png similarity index 100% rename from common/assets/mysticmods/textures/items/StaffPart_Staff.png rename to common/assets/mysticworld/textures/items/StaffPart_Staff.png diff --git a/common/assets/mysticmods/textures/items/VerditeArmor_0.png b/common/assets/mysticworld/textures/items/VerditeArmor_0.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeArmor_0.png rename to common/assets/mysticworld/textures/items/VerditeArmor_0.png diff --git a/common/assets/mysticmods/textures/items/VerditeArmor_1.png b/common/assets/mysticworld/textures/items/VerditeArmor_1.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeArmor_1.png rename to common/assets/mysticworld/textures/items/VerditeArmor_1.png diff --git a/common/assets/mysticmods/textures/items/VerditeArmor_2.png b/common/assets/mysticworld/textures/items/VerditeArmor_2.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeArmor_2.png rename to common/assets/mysticworld/textures/items/VerditeArmor_2.png diff --git a/common/assets/mysticmods/textures/items/VerditeArmor_3.png b/common/assets/mysticworld/textures/items/VerditeArmor_3.png similarity index 100% rename from common/assets/mysticmods/textures/items/VerditeArmor_3.png rename to common/assets/mysticworld/textures/items/VerditeArmor_3.png diff --git a/common/assets/mysticmods/textures/misc/airFX.png b/common/assets/mysticworld/textures/misc/airFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/airFX.png rename to common/assets/mysticworld/textures/misc/airFX.png diff --git a/common/assets/mysticmods/textures/misc/earthFX.png b/common/assets/mysticworld/textures/misc/earthFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/earthFX.png rename to common/assets/mysticworld/textures/misc/earthFX.png diff --git a/common/assets/mysticmods/textures/misc/energyFX.png b/common/assets/mysticworld/textures/misc/energyFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/energyFX.png rename to common/assets/mysticworld/textures/misc/energyFX.png diff --git a/common/assets/mysticmods/textures/misc/fireFX.png b/common/assets/mysticworld/textures/misc/fireFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/fireFX.png rename to common/assets/mysticworld/textures/misc/fireFX.png diff --git a/common/assets/mysticmods/textures/misc/lightCubeFX.png b/common/assets/mysticworld/textures/misc/lightCubeFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/lightCubeFX.png rename to common/assets/mysticworld/textures/misc/lightCubeFX.png diff --git a/common/assets/mysticmods/textures/misc/waterFX.png b/common/assets/mysticworld/textures/misc/waterFX.png similarity index 100% rename from common/assets/mysticmods/textures/misc/waterFX.png rename to common/assets/mysticworld/textures/misc/waterFX.png diff --git a/common/assets/mysticmods/textures/mob/MysticVillager.png b/common/assets/mysticworld/textures/mob/MysticVillager.png similarity index 100% rename from common/assets/mysticmods/textures/mob/MysticVillager.png rename to common/assets/mysticworld/textures/mob/MysticVillager.png diff --git a/common/assets/mysticmods/textures/models/AirStaff.png b/common/assets/mysticworld/textures/models/AirStaff.png similarity index 100% rename from common/assets/mysticmods/textures/models/AirStaff.png rename to common/assets/mysticworld/textures/models/AirStaff.png diff --git a/common/assets/mysticmods/textures/models/EarthStaff.png b/common/assets/mysticworld/textures/models/EarthStaff.png similarity index 100% rename from common/assets/mysticmods/textures/models/EarthStaff.png rename to common/assets/mysticworld/textures/models/EarthStaff.png diff --git a/common/assets/mysticmods/textures/models/EnergyStaff.png b/common/assets/mysticworld/textures/models/EnergyStaff.png similarity index 100% rename from common/assets/mysticmods/textures/models/EnergyStaff.png rename to common/assets/mysticworld/textures/models/EnergyStaff.png diff --git a/common/assets/mysticmods/textures/models/FireStaff.png b/common/assets/mysticworld/textures/models/FireStaff.png similarity index 100% rename from common/assets/mysticmods/textures/models/FireStaff.png rename to common/assets/mysticworld/textures/models/FireStaff.png diff --git a/common/assets/mysticmods/textures/models/OrbAir.png b/common/assets/mysticworld/textures/models/OrbAir.png similarity index 100% rename from common/assets/mysticmods/textures/models/OrbAir.png rename to common/assets/mysticworld/textures/models/OrbAir.png diff --git a/common/assets/mysticmods/textures/models/OrbEarth.png b/common/assets/mysticworld/textures/models/OrbEarth.png similarity index 100% rename from common/assets/mysticmods/textures/models/OrbEarth.png rename to common/assets/mysticworld/textures/models/OrbEarth.png diff --git a/common/assets/mysticmods/textures/models/OrbEnergy.png b/common/assets/mysticworld/textures/models/OrbEnergy.png similarity index 100% rename from common/assets/mysticmods/textures/models/OrbEnergy.png rename to common/assets/mysticworld/textures/models/OrbEnergy.png diff --git a/common/assets/mysticmods/textures/models/OrbFire.png b/common/assets/mysticworld/textures/models/OrbFire.png similarity index 100% rename from common/assets/mysticmods/textures/models/OrbFire.png rename to common/assets/mysticworld/textures/models/OrbFire.png diff --git a/common/assets/mysticmods/textures/models/OrbWater.png b/common/assets/mysticworld/textures/models/OrbWater.png similarity index 100% rename from common/assets/mysticmods/textures/models/OrbWater.png rename to common/assets/mysticworld/textures/models/OrbWater.png diff --git a/common/assets/mysticmods/textures/models/PillarInsert.png b/common/assets/mysticworld/textures/models/PillarInsert.png similarity index 100% rename from common/assets/mysticmods/textures/models/PillarInsert.png rename to common/assets/mysticworld/textures/models/PillarInsert.png diff --git a/common/assets/mysticmods/textures/models/PillarInsertFilled.png b/common/assets/mysticworld/textures/models/PillarInsertFilled.png similarity index 100% rename from common/assets/mysticmods/textures/models/PillarInsertFilled.png rename to common/assets/mysticworld/textures/models/PillarInsertFilled.png diff --git a/common/assets/mysticmods/textures/models/StaffAir.png b/common/assets/mysticworld/textures/models/StaffAir.png similarity index 100% rename from common/assets/mysticmods/textures/models/StaffAir.png rename to common/assets/mysticworld/textures/models/StaffAir.png diff --git a/common/assets/mysticmods/textures/models/StaffEarth.png b/common/assets/mysticworld/textures/models/StaffEarth.png similarity index 100% rename from common/assets/mysticmods/textures/models/StaffEarth.png rename to common/assets/mysticworld/textures/models/StaffEarth.png diff --git a/common/assets/mysticmods/textures/models/StaffEnergy.png b/common/assets/mysticworld/textures/models/StaffEnergy.png similarity index 100% rename from common/assets/mysticmods/textures/models/StaffEnergy.png rename to common/assets/mysticworld/textures/models/StaffEnergy.png diff --git a/common/assets/mysticmods/textures/models/StaffFire.png b/common/assets/mysticworld/textures/models/StaffFire.png similarity index 100% rename from common/assets/mysticmods/textures/models/StaffFire.png rename to common/assets/mysticworld/textures/models/StaffFire.png diff --git a/common/assets/mysticmods/textures/models/StaffWater.png b/common/assets/mysticworld/textures/models/StaffWater.png similarity index 100% rename from common/assets/mysticmods/textures/models/StaffWater.png rename to common/assets/mysticworld/textures/models/StaffWater.png diff --git a/common/assets/mysticmods/textures/models/WaterStaff.png b/common/assets/mysticworld/textures/models/WaterStaff.png similarity index 100% rename from common/assets/mysticmods/textures/models/WaterStaff.png rename to common/assets/mysticworld/textures/models/WaterStaff.png diff --git a/common/assets/mysticmods/textures/models/armor/Adamantine_layer_1.png b/common/assets/mysticworld/textures/models/armor/Adamantine_layer_1.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Adamantine_layer_1.png rename to common/assets/mysticworld/textures/models/armor/Adamantine_layer_1.png diff --git a/common/assets/mysticmods/textures/models/armor/Adamantine_layer_2.png b/common/assets/mysticworld/textures/models/armor/Adamantine_layer_2.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Adamantine_layer_2.png rename to common/assets/mysticworld/textures/models/armor/Adamantine_layer_2.png diff --git a/common/assets/mysticmods/textures/models/armor/Iridium_layer_1.png b/common/assets/mysticworld/textures/models/armor/Iridium_layer_1.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Iridium_layer_1.png rename to common/assets/mysticworld/textures/models/armor/Iridium_layer_1.png diff --git a/common/assets/mysticmods/textures/models/armor/Iridium_layer_2.png b/common/assets/mysticworld/textures/models/armor/Iridium_layer_2.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Iridium_layer_2.png rename to common/assets/mysticworld/textures/models/armor/Iridium_layer_2.png diff --git a/common/assets/mysticmods/textures/models/armor/Mithril_layer_1.png b/common/assets/mysticworld/textures/models/armor/Mithril_layer_1.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Mithril_layer_1.png rename to common/assets/mysticworld/textures/models/armor/Mithril_layer_1.png diff --git a/common/assets/mysticmods/textures/models/armor/Mithril_layer_2.png b/common/assets/mysticworld/textures/models/armor/Mithril_layer_2.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Mithril_layer_2.png rename to common/assets/mysticworld/textures/models/armor/Mithril_layer_2.png diff --git a/common/assets/mysticmods/textures/models/armor/Verdite_layer_1.png b/common/assets/mysticworld/textures/models/armor/Verdite_layer_1.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Verdite_layer_1.png rename to common/assets/mysticworld/textures/models/armor/Verdite_layer_1.png diff --git a/common/assets/mysticmods/textures/models/armor/Verdite_layer_2.png b/common/assets/mysticworld/textures/models/armor/Verdite_layer_2.png similarity index 100% rename from common/assets/mysticmods/textures/models/armor/Verdite_layer_2.png rename to common/assets/mysticworld/textures/models/armor/Verdite_layer_2.png diff --git a/common/build.gradle b/common/build.gradle new file mode 100644 index 0000000..6f9c779 --- /dev/null +++ b/common/build.gradle @@ -0,0 +1,43 @@ +buildscript { + repositories { + mavenCentral() + maven { + name = "forge" + url = "http://files.minecraftforge.net/maven" + } + maven { + name = "sonatype" + url = "https://oss.sonatype.org/content/repositories/snapshots/" + } + } + dependencies { + classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT' + } +} +apply plugin: 'forge' +sourceCompatibility = 1.6 +targetCompatibility = 1.6 +minecraft { + version = "1.7.10-10.13.2.1230" + runDir = "eclipse" +} +archivesBaseName = "MysticMods" +version = "0.1(1.7.10)" +sourceSets.main.java{srcDirs project.projectDir.getPath() include("mysticores/**", "mysticruins/**" , "mysticstones/**", "mysticworld/**")} +sourceSets.main.resources{srcDirs project.projectDir.getPath() include("assets/**" , "*.info")} +processResources { + // this will ensure that this task is redone when the versions change. + inputs.property "version", project.version + inputs.property "mcversion", project.minecraft.version + + // replace stuff in mcmod.info, nothing else + from(project.sourceSets.main.resources.srcDirs) { + include "mcmod.info" + // replace version and mcversion + expand([version:project.version, mcversion:project.minecraft.version]) + } + // copy everything else, thats not mcmod.info + from(project.sourceSets.main.resources.srcDirs) { + include("assets/**", "pack.mcmeta") + } +} \ No newline at end of file diff --git a/common/gradle/wrapper/gradle-wrapper.jar b/common/gradle/wrapper/gradle-wrapper.jar new file mode 100644 index 0000000..b761216 Binary files /dev/null and b/common/gradle/wrapper/gradle-wrapper.jar differ diff --git a/common/gradle/wrapper/gradle-wrapper.properties b/common/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..678d9d8 --- /dev/null +++ b/common/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +#Wed Jul 02 15:54:47 CDT 2014 +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-2.0-bin.zip diff --git a/common/gradlew b/common/gradlew new file mode 100644 index 0000000..91a7e26 --- /dev/null +++ b/common/gradlew @@ -0,0 +1,164 @@ +#!/usr/bin/env bash + +############################################################################## +## +## Gradle start up script for UN*X +## +############################################################################## + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS="" + +APP_NAME="Gradle" +APP_BASE_NAME=`basename "$0"` + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD="maximum" + +warn ( ) { + echo "$*" +} + +die ( ) { + echo + echo "$*" + echo + exit 1 +} + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +case "`uname`" in + CYGWIN* ) + cygwin=true + ;; + Darwin* ) + darwin=true + ;; + MINGW* ) + msys=true + ;; +esac + +# For Cygwin, ensure paths are in UNIX format before anything is touched. +if $cygwin ; then + [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` +fi + +# Attempt to set APP_HOME +# Resolve links: $0 may be a link +PRG="$0" +# Need this for relative symlinks. +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`"/$link" + fi +done +SAVED="`pwd`" +cd "`dirname \"$PRG\"`/" >&- +APP_HOME="`pwd -P`" +cd "$SAVED" >&- + +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD="$JAVA_HOME/jre/sh/java" + else + JAVACMD="$JAVA_HOME/bin/java" + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD="java" + which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." +fi + +# Increase the maximum file descriptors if we can. +if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then + MAX_FD_LIMIT=`ulimit -H -n` + if [ $? -eq 0 ] ; then + if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then + MAX_FD="$MAX_FD_LIMIT" + fi + ulimit -n $MAX_FD + if [ $? -ne 0 ] ; then + warn "Could not set maximum file descriptor limit: $MAX_FD" + fi + else + warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" + fi +fi + +# For Darwin, add options to specify how the application appears in the dock +if $darwin; then + GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" +fi + +# For Cygwin, switch paths to Windows format before running java +if $cygwin ; then + APP_HOME=`cygpath --path --mixed "$APP_HOME"` + CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` + + # We build the pattern for arguments to be converted via cygpath + ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` + SEP="" + for dir in $ROOTDIRSRAW ; do + ROOTDIRS="$ROOTDIRS$SEP$dir" + SEP="|" + done + OURCYGPATTERN="(^($ROOTDIRS))" + # Add a user-defined pattern to the cygpath arguments + if [ "$GRADLE_CYGPATTERN" != "" ] ; then + OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" + fi + # Now convert the arguments - kludge to limit ourselves to /bin/sh + i=0 + for arg in "$@" ; do + CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` + CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option + + if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition + eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` + else + eval `echo args$i`="\"$arg\"" + fi + i=$((i+1)) + done + case $i in + (0) set -- ;; + (1) set -- "$args0" ;; + (2) set -- "$args0" "$args1" ;; + (3) set -- "$args0" "$args1" "$args2" ;; + (4) set -- "$args0" "$args1" "$args2" "$args3" ;; + (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; + (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; + (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; + (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; + (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; + esac +fi + +# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules +function splitJvmOpts() { + JVM_OPTS=("$@") +} +eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS +JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" + +exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" diff --git a/common/gradlew.bat b/common/gradlew.bat new file mode 100644 index 0000000..8a0b282 --- /dev/null +++ b/common/gradlew.bat @@ -0,0 +1,90 @@ +@if "%DEBUG%" == "" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS= + +set DIRNAME=%~dp0 +if "%DIRNAME%" == "" set DIRNAME=. +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if "%ERRORLEVEL%" == "0" goto init + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto init + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:init +@rem Get command-line arguments, handling Windowz variants + +if not "%OS%" == "Windows_NT" goto win9xME_args +if "%@eval[2+2]" == "4" goto 4NT_args + +:win9xME_args +@rem Slurp the command line arguments. +set CMD_LINE_ARGS= +set _SKIP=2 + +:win9xME_args_slurp +if "x%~1" == "x" goto execute + +set CMD_LINE_ARGS=%* +goto execute + +:4NT_args +@rem Get arguments from the 4NT Shell from JP Software +set CMD_LINE_ARGS=%$ + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% + +:end +@rem End local scope for the variables with windows NT shell +if "%ERRORLEVEL%"=="0" goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 +exit /b 1 + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/common/mcmod.info b/common/mcmod.info new file mode 100644 index 0000000..36be79e --- /dev/null +++ b/common/mcmod.info @@ -0,0 +1,70 @@ +[ +{ + "modid": "mysticores", + "name": "Mystic Ores", + "description": "Adds ores into the Nether and Overworld", + "version": $version, + "credits": "oitsjustjose", + "logoFile": "", + "mcversion": $mcversion, + "url": "http://bit.ly/13ep6OW", + "updateUrl": "", + "authorList": [ "oitsjustjose", "GotoLink" ], + "parent":"", + "screenshots": [], + "dependencies": [ + "MinecraftForge" + ] +}, +{ + "modid": "mysticruins", + "name": "Mystic Ruins", + "description": "Magical structures to explore in your minecraft game!", + "version": $version, + "credits": "oitsjustjose", + "logoFile": "", + "mcversion": $mcversion, + "url": "http://bit.ly/13ep6OW", + "updateUrl": "", + "authorList": [ "oitsjustjose", "GotoLink" ], + "parent":"", + "screenshots": [], + "dependencies": [ + "MinecraftForge" + ] +}, +{ + "modid": "mysticstones", + "name": "Mystic Stones", + "description": "Adds stones into selected worlds", + "version": $version, + "credits": "oitsjustjose", + "logoFile": "", + "mcversion": $mcversion, + "url": "http://bit.ly/13ep6OW", + "updateUrl": "", + "authorList": [ "oitsjustjose", "GotoLink" ], + "parent":"", + "screenshots": [], + "dependencies": [ + "MinecraftForge" + ] +}, + { + "modid": "mysticworld", + "name": "Mystic World", + "description": "Adds a lot of stuff related to the other mystic mods", + "version": $version, + "credits": "oitsjustjose", + "logoFile": "", + "mcversion": $mcversion, + "url": "http://bit.ly/13ep6OW", + "updateUrl": "", + "authorList": [ "oitsjustjose", "GotoLink" ], + "parent":"", + "screenshots": [], + "dependencies": [ + "MinecraftForge" + ] + } +] diff --git a/common/mysticores/Items/ItemHatchet.java b/common/mysticores/Items/ItemHatchet.java new file mode 100644 index 0000000..59a074c --- /dev/null +++ b/common/mysticores/Items/ItemHatchet.java @@ -0,0 +1,9 @@ +package mysticores.items; + +import net.minecraft.item.ItemAxe; + +public class ItemHatchet extends ItemAxe{ + public ItemHatchet(ToolMaterial mat) { + super(mat); + } +} diff --git a/common/mysticores/Items/ItemPick.java b/common/mysticores/Items/ItemPick.java new file mode 100644 index 0000000..0c2d6f4 --- /dev/null +++ b/common/mysticores/Items/ItemPick.java @@ -0,0 +1,9 @@ +package mysticores.items; + +import net.minecraft.item.ItemPickaxe; + +public class ItemPick extends ItemPickaxe{ + public ItemPick(ToolMaterial mat) { + super(mat); + } +} diff --git a/common/mysticores/worldgen/WorldGenOres.java b/common/mysticores/worldgen/WorldGenOres.java index 07a4e2e..94970ab 100644 --- a/common/mysticores/worldgen/WorldGenOres.java +++ b/common/mysticores/worldgen/WorldGenOres.java @@ -1,74 +1,79 @@ package mysticores.worldgen; -import java.util.Random; - +import cpw.mods.fml.common.IWorldGenerator; import mysticores.blocks.BlockHandler; import mysticores.lib.Rarity; -import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.world.World; import net.minecraft.world.chunk.IChunkProvider; import net.minecraft.world.gen.feature.WorldGenMinable; -import cpw.mods.fml.common.IWorldGenerator; + +import java.util.Random; public class WorldGenOres implements IWorldGenerator { - public static final WorldGenMinable adamantine = new WorldGenMinable(BlockHandler.BlockBase.blockID, 0, 3); - public static final WorldGenMinable amethyst = new WorldGenMinable(BlockHandler.BlockBase.blockID, 1, 4, Block.stone.blockID); - public static final WorldGenMinable iridium = new WorldGenMinable(BlockHandler.BlockBase.blockID, 2, 6, Block.stone.blockID); - public static final WorldGenMinable mithril = new WorldGenMinable(BlockHandler.BlockBase.blockID, 3, 6, Block.stone.blockID); - public static final WorldGenMinable tourmaline = new WorldGenMinable(BlockHandler.BlockBase.blockID, 4, 4, Block.stone.blockID); - public static final WorldGenMinable topaz = new WorldGenMinable(BlockHandler.BlockBase.blockID, 5, 4, Block.stone.blockID); - public static final WorldGenMinable verdite = new WorldGenMinable(BlockHandler.BlockBase.blockID, 6, 9, Block.stone.blockID); - public static final WorldGenMinable agate = new WorldGenMinable(BlockHandler.BlockBase.blockID, 11, 4, Block.stone.blockID); + public static final WorldGenMinable adamantine = new WorldGenMinable(BlockHandler.BlockBase, 0, 3, Blocks.stone); + public static final WorldGenMinable amethyst = new WorldGenMinable(BlockHandler.BlockBase, 1, 4, Blocks.stone); + public static final WorldGenMinable iridium = new WorldGenMinable(BlockHandler.BlockBase, 2, 6, Blocks.stone); + public static final WorldGenMinable mithril = new WorldGenMinable(BlockHandler.BlockBase, 3, 6, Blocks.stone); + public static final WorldGenMinable tourmaline = new WorldGenMinable(BlockHandler.BlockBase, 4, 4, Blocks.stone); + public static final WorldGenMinable topaz = new WorldGenMinable(BlockHandler.BlockBase, 5, 4, Blocks.stone); + public static final WorldGenMinable verdite = new WorldGenMinable(BlockHandler.BlockBase, 6, 9, Blocks.stone); + public static final WorldGenMinable agate = new WorldGenMinable(BlockHandler.BlockBase, 11, 4, Blocks.stone); + public static final NetherGenHelper bloodstone = new NetherGenHelper(BlockHandler.BlockBase, 7, Rarity.BLOODSTONE + 1); + public static final NetherGenHelper blackSoulstone = new NetherGenHelper(BlockHandler.BlockBase, 8, Rarity.BLACKSOULSTONE + 1); + public static final NetherGenHelper blueSoulstone = new NetherGenHelper(BlockHandler.BlockBase, 9, Rarity.BLUESOULSTONE + 1); + public static final NetherGenHelper redSoulstone = new NetherGenHelper(BlockHandler.BlockBase, 10, Rarity.REDSOULSTONE); @Override public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { - switch (world.provider.dimensionId) { - case 0: + if (!world.provider.isHellWorld) { generateSurface(world, random, chunkX * 16, chunkZ * 16); - } + }else{ + generateNether(world, random, chunkX * 16, chunkZ * 16); + } } private void generateSurface(World world, Random random, int blockX, int blockZ) { for (int i = 0; i < Rarity.ADAMANTINE; i++) { - int Xcoord = blockX + random.nextInt(8); - int Ycoord = random.nextInt(16); - int Zcoord = blockZ + random.nextInt(8); + int Xcoord = blockX + random.nextInt(16); + int Ycoord = random.nextInt(13) + 3; + int Zcoord = blockZ + random.nextInt(16); adamantine.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.AGATE; i++) { - int Xcoord = blockX + random.nextInt(32); - int Ycoord = random.nextInt(60); - int Zcoord = blockZ + random.nextInt(32); + int Xcoord = blockX + random.nextInt(16); + int Ycoord = random.nextInt(57) + 3; + int Zcoord = blockZ + random.nextInt(16); agate.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.AMETHYST; i++) { - int Xcoord = blockX + random.nextInt(24); - int Ycoord = random.nextInt(60); - int Zcoord = blockZ + random.nextInt(24); + int Xcoord = blockX + random.nextInt(16); + int Ycoord = random.nextInt(57) + 3; + int Zcoord = blockZ + random.nextInt(16); amethyst.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.IRIDIUM; i++) { int Xcoord = blockX + random.nextInt(16); - int Ycoord = random.nextInt(12); + int Ycoord = random.nextInt(9) + 3; int Zcoord = blockZ + random.nextInt(16); iridium.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.MITHRIL; i++) { int Xcoord = blockX + random.nextInt(16); - int Ycoord = random.nextInt(64); + int Ycoord = random.nextInt(61) + 3; int Zcoord = blockZ + random.nextInt(16); mithril.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.TOPAZ; i++) { int Xcoord = blockX + random.nextInt(16); - int Ycoord = random.nextInt(60); + int Ycoord = random.nextInt(57) + 3; int Zcoord = blockZ + random.nextInt(16); topaz.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.TOURMALINE; i++) { - int Xcoord = blockX + random.nextInt(32); - int Ycoord = random.nextInt(60); - int Zcoord = blockZ + random.nextInt(32); + int Xcoord = blockX + random.nextInt(16); + int Ycoord = random.nextInt(57) + 3; + int Zcoord = blockZ + random.nextInt(16); tourmaline.generate(world, random, Xcoord, Ycoord, Zcoord); } for (int i = 0; i < Rarity.VERDITE; i++) { @@ -78,4 +83,31 @@ public class WorldGenOres implements IWorldGenerator { verdite.generate(world, random, Xcoord, Ycoord, Zcoord); } } + + private void generateNether(World world, Random random, int i, int j) { + for (int j1 = 0; j1 < 50; j1++) { + int Xcoordinate = i + random.nextInt(16); + int Zcoordinate = j + random.nextInt(16); + int Ycoordinate = random.nextInt(256); + bloodstone.generate(world, random, Xcoordinate, Ycoordinate, Zcoordinate); + } + for (int j1 = 0; j1 < 50; j1++) { + int Xcoordinate = i + random.nextInt(16); + int Zcoordinate = j + random.nextInt(16); + int Ycoordinate = random.nextInt(256); + blackSoulstone.generate(world, random, Xcoordinate, Ycoordinate, Zcoordinate); + } + for (int j1 = 0; j1 < 50; j1++) { + int Xcoordinate = i + random.nextInt(16); + int Zcoordinate = j + random.nextInt(16); + int Ycoordinate = random.nextInt(256); + blueSoulstone.generate(world, random, Xcoordinate, Ycoordinate, Zcoordinate); + } + for (int j1 = 0; j1 < 50; j1++) { + int Xcoordinate = i + random.nextInt(16); + int Zcoordinate = j + random.nextInt(16); + int Ycoordinate = random.nextInt(256); + redSoulstone.generate(world, random, Xcoordinate, Ycoordinate, Zcoordinate); + } + } } \ No newline at end of file diff --git a/common/mysticruins/ChestFiller.java b/common/mysticruins/ChestFiller.java index 372a79a..bac0989 100644 --- a/common/mysticruins/ChestFiller.java +++ b/common/mysticruins/ChestFiller.java @@ -1,66 +1,34 @@ package mysticruins; -import java.util.Random; - import net.minecraft.inventory.IInventory; -import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.tileentity.TileEntity; +import java.util.ArrayList; +import java.util.List; +import java.util.Random; + public class ChestFiller { + public static List rares = new ArrayList(); + public static List valuables = new ArrayList(); + public static void fillWithRares(TileEntity tile) { - if (tile instanceof IInventory) { - IInventory chest = (IInventory) tile; - Random rand = new Random(); - int num; - for (int slot = 0; slot < chest.getSizeInventory(); slot++) { - num = rand.nextInt(16); - if (num == 1) { - chest.setInventorySlotContents(slot, new ItemStack(Item.enderPearl, 4, 0)); - } - if (num == 2) { - chest.setInventorySlotContents(slot, new ItemStack(Item.diamond, 1, 0)); - } - if (num == 3) { - chest.setInventorySlotContents(slot, new ItemStack(Item.emerald, 1, 0)); - } - if (num == 4) { - chest.setInventorySlotContents(slot, new ItemStack(Item.appleGold, 1, 0)); - } - if (num == 5) { - chest.setInventorySlotContents(slot, new ItemStack(Item.ingotGold, 1, 0)); - } - if (num == 6) { - chest.setInventorySlotContents(slot, new ItemStack(Item.ingotIron, 1, 0)); - } - } - } + fill(tile, rares, 2.5D); } public static void fillWithValuables(TileEntity tile) { + fill(tile, valuables, 5D); + } + + private static void fill(TileEntity tile, List stacks, double factor) { if (tile instanceof IInventory) { IInventory chest = (IInventory) tile; Random rand = new Random(); int num; for (int slot = 0; slot < chest.getSizeInventory(); slot++) { - num = rand.nextInt(32); - if (num == 1) { - chest.setInventorySlotContents(slot, new ItemStack(Item.pickaxeIron, 1, 0)); - } - if (num == 2) { - chest.setInventorySlotContents(slot, new ItemStack(Item.axeIron, 1, 0)); - } - if (num == 3) { - chest.setInventorySlotContents(slot, new ItemStack(Item.swordIron, 1, 0)); - } - if (num == 4) { - chest.setInventorySlotContents(slot, new ItemStack(Item.shovelIron, 1, 0)); - } - if (num == 5) { - chest.setInventorySlotContents(slot, new ItemStack(Item.ingotGold, 1, 0)); - } - if (num == 6) { - chest.setInventorySlotContents(slot, new ItemStack(Item.ingotIron, 1, 0)); + num = rand.nextInt((int) (stacks.size() * factor)); + if (num < stacks.size()) { + chest.setInventorySlotContents(slot, stacks.get(num)); } } } diff --git a/common/mysticruins/WorldGenMystic.java b/common/mysticruins/WorldGenMystic.java index 8c1f622..82ff37a 100644 --- a/common/mysticruins/WorldGenMystic.java +++ b/common/mysticruins/WorldGenMystic.java @@ -1,11 +1,15 @@ package mysticruins; -import java.util.Random; - +import cpw.mods.fml.common.IWorldGenerator; import net.minecraft.world.World; +import net.minecraft.world.WorldType; +import net.minecraft.world.biome.BiomeGenBase; import net.minecraft.world.chunk.IChunkProvider; import net.minecraft.world.gen.feature.WorldGenerator; -import cpw.mods.fml.common.IWorldGenerator; +import net.minecraftforge.common.BiomeDictionary; + +import java.util.Arrays; +import java.util.Random; public class WorldGenMystic implements IWorldGenerator { public static final WorldGenerator ruin = new StructureRuin(); @@ -14,30 +18,48 @@ public class WorldGenMystic implements IWorldGenerator { @Override public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { - if (Config.ruinAllowId.contains(world.provider.dimensionId)) { + if (Config.RuinRarity>0 && Config.allowId[0].contains(world.provider.dimensionId)) { generateRuins(world, random, chunkX * 16, chunkZ * 16); } - if (Config.dungeonAllowId.contains(world.provider.dimensionId)) { + if (world.getWorldInfo().getTerrainType() == WorldType.FLAT) { + return; + } + if (Config.DunRarity>0 && Config.allowId[1].contains(world.provider.dimensionId)) { generateDungeon(world, random, chunkX * 16, chunkZ * 16); } } private void generateDungeon(World world, Random random, int blockX, int blockZ) { - for (int i = 0; i < Config.DunRarity; i++) { - int Xcoord1 = blockX + random.nextInt(16) + 8; - int Ycoord1 = random.nextInt(9) + 28; - int Zcoord1 = blockZ + random.nextInt(16) + 8; - dungeon.generate(world, random, Xcoord1, Ycoord1, Zcoord1); + int Xcoord1, Ycoord1, Zcoord1; + BiomeGenBase biome; + for (int i = 0; i-Config.DunRarity/100<0F; i++) { + if(random.nextInt(Config.DunRarity)>1){ + Xcoord1 = blockX + random.nextInt(16) + 8; + Ycoord1 = random.nextInt(9) + 28; + Zcoord1 = blockZ + random.nextInt(16) + 8; + biome = world.getBiomeGenForCoords(Xcoord1, Zcoord1); + if (Config.allowId[3].contains(biome.biomeID) && Config.allowType[1].containsAll(Arrays.asList(BiomeDictionary.getTypesForBiome(biome)))) { + if (dungeon.generate(world, random, Xcoord1, Ycoord1, Zcoord1)) + break; + } + } } } private void generateRuins(World world, Random random, int blockX, int blockZ) { - for (int i = 0; i < Config.RuinRarity; i++) { - int Xcoord1 = blockX + random.nextInt(16) + 8; - int Ycoord1 = random.nextInt(11) + 60; - int Zcoord1 = blockZ + random.nextInt(16) + 8; - ruin.generate(world, random, Xcoord1, Ycoord1, Zcoord1); - ruin1.generate(world, random, Xcoord1, Ycoord1, Zcoord1); + int Xcoord1, Ycoord1, Zcoord1; + BiomeGenBase biome; + for (int i = 0; i-Config.RuinRarity/100<0F; i++) { + if(random.nextInt(Config.RuinRarity)>1){ + Xcoord1 = blockX + random.nextInt(16) + 8; + Ycoord1 = random.nextInt(11) + 60; + Zcoord1 = blockZ + random.nextInt(16) + 8; + biome = world.getBiomeGenForCoords(Xcoord1, Zcoord1); + if (Config.allowId[2].contains(biome.biomeID) && Config.allowType[0].containsAll(Arrays.asList(BiomeDictionary.getTypesForBiome(biome)))) { + if (ruin.generate(world, random, Xcoord1, Ycoord1, Zcoord1) || ruin1.generate(world, random, Xcoord1, Ycoord1, Zcoord1)) + break; + } + } } } } \ No newline at end of file diff --git a/common/mysticstones/blocks/BlockMulti.java b/common/mysticstones/blocks/BlockMulti.java index b62d9a3..360ecfb 100644 --- a/common/mysticstones/blocks/BlockMulti.java +++ b/common/mysticstones/blocks/BlockMulti.java @@ -1,7 +1,5 @@ package mysticstones.blocks; -import java.util.List; - import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; import mysticstones.MysticStones; @@ -10,15 +8,17 @@ import net.minecraft.block.material.Material; import net.minecraft.creativetab.CreativeTabs; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; +import net.minecraft.util.IIcon; import net.minecraft.util.MovingObjectPosition; import net.minecraft.world.World; -public class BlockMulti extends Block { - Icon[] textures; +import java.util.List; - public BlockMulti(int par1, Material par2Material) { - super(par1, par2Material); +public class BlockMulti extends Block { + IIcon[] textures; + + public BlockMulti(Material par2Material) { + super(par2Material); setCreativeTab(MysticStones.MysticStonesTab); } @@ -29,26 +29,22 @@ public class BlockMulti extends Block { @Override @SideOnly(Side.CLIENT) - public Icon getIcon(int side, int meta) { + public IIcon getIcon(int side, int meta) { return textures[meta]; } @Override public ItemStack getPickBlock(MovingObjectPosition target, World world, int x, int y, int z) { - int id = idPicked(world, x, y, z); - if (id == 0) { - return null; - } - Item item = Item.itemsList[id]; + Item item = getItem(world, x, y, z); if (item == null) { return null; } - return new ItemStack(id, 1, getDamageValue(world, x, y, z)); + return new ItemStack(item, 1, getDamageValue(world, x, y, z)); } @Override @SideOnly(Side.CLIENT) - public void getSubBlocks(int i, CreativeTabs tab, List list) { + public void getSubBlocks(Item i, CreativeTabs tab, List list) { for (int j = 0; j < textures.length; j++) { list.add(new ItemStack(i, 1, j)); } diff --git a/common/mysticstones/blocks/ItemBlockMulti.java b/common/mysticstones/blocks/ItemBlockMulti.java index 952a23a..2a50eca 100644 --- a/common/mysticstones/blocks/ItemBlockMulti.java +++ b/common/mysticstones/blocks/ItemBlockMulti.java @@ -1,39 +1,22 @@ package mysticstones.blocks; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; import net.minecraft.block.Block; -import net.minecraft.item.ItemBlock; +import net.minecraft.item.ItemBlockWithMetadata; import net.minecraft.item.ItemStack; -import net.minecraft.util.Icon; import net.minecraft.util.MathHelper; -public class ItemBlockMulti extends ItemBlock { - private String[] types; - private Block block; +import java.util.ArrayList; - public ItemBlockMulti(int par1, Block block, String[] names) { - super(par1); +public class ItemBlockMulti extends ItemBlockWithMetadata { + private ArrayList types; + public ItemBlockMulti(Block block, ArrayList names) { + super(block, block); this.types = names; - this.block = block; - setMaxDamage(0); - setHasSubtypes(true); - } - - @Override - @SideOnly(Side.CLIENT) - public Icon getIconFromDamage(int par1) { - return block.getIcon(2, par1); - } - - @Override - public int getMetadata(int par1) { - return par1; } @Override public String getUnlocalizedName(ItemStack itemStack) { - int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, types.length); - return types[meta]; + int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, types.size()); + return types.get(meta); } } diff --git a/common/mysticstones/worldgen/WorldGeneratorStones.java b/common/mysticstones/worldgen/WorldGeneratorStones.java index ed20924..2f234ad 100644 --- a/common/mysticstones/worldgen/WorldGeneratorStones.java +++ b/common/mysticstones/worldgen/WorldGeneratorStones.java @@ -1,23 +1,23 @@ package mysticstones.worldgen; -import java.util.Random; - +import cpw.mods.fml.common.IWorldGenerator; import mysticstones.MysticStones; import mysticstones.util.Config; -import net.minecraft.block.Block; +import net.minecraft.init.Blocks; import net.minecraft.world.World; import net.minecraft.world.chunk.IChunkProvider; import net.minecraft.world.gen.feature.WorldGenMinable; -import cpw.mods.fml.common.IWorldGenerator; + +import java.util.Random; public class WorldGeneratorStones implements IWorldGenerator { - public static final WorldGenMinable anorthosite = new WorldGenMinable(MysticStones.Stones.blockID, 0, 24, Block.stone.blockID); - public static final WorldGenMinable limestone = new WorldGenMinable(MysticStones.Stones.blockID, 2, 48, Block.stone.blockID); - public static final WorldGenMinable marble = new WorldGenMinable(MysticStones.Stones.blockID, 4, 24, Block.stone.blockID); - public static final WorldGenMinable migmatite = new WorldGenMinable(MysticStones.Stones.blockID, 6, 48, Block.stone.blockID); - public static final WorldGenMinable orthogneiss = new WorldGenMinable(MysticStones.Stones.blockID, 8, 48, Block.stone.blockID); - public static final WorldGenMinable slate = new WorldGenMinable(MysticStones.Stones.blockID, 10, 24, Block.stone.blockID); - public static final WorldGenMinable travertine = new WorldGenMinable(MysticStones.Stones.blockID, 12, 24, Block.stone.blockID); + public static final WorldGenMinable anorthosite = new WorldGenMinable(MysticStones.stones, 0, 24, Blocks.stone); + public static final WorldGenMinable limestone = new WorldGenMinable(MysticStones.stones, 2, 48, Blocks.stone); + public static final WorldGenMinable marble = new WorldGenMinable(MysticStones.stones, 4, 24, Blocks.stone); + public static final WorldGenMinable migmatite = new WorldGenMinable(MysticStones.stones, 6, 48, Blocks.stone); + public static final WorldGenMinable orthogneiss = new WorldGenMinable(MysticStones.stones, 8, 48, Blocks.stone); + public static final WorldGenMinable slate = new WorldGenMinable(MysticStones.stones, 10, 24, Blocks.stone); + public static final WorldGenMinable travertine = new WorldGenMinable(MysticStones.stones, 12, 24, Blocks.stone); @Override public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { @@ -28,43 +28,43 @@ public class WorldGeneratorStones implements IWorldGenerator { private void generateSurface(World world, Random random, int blockX, int blockZ) { int Xcoord, Ycoord, Zcoord; - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[0]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); anorthosite.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[1]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); limestone.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[2]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); marble.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[3]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); migmatite.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[4]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); orthogneiss.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[5]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); slate.generate(world, random, Xcoord, Ycoord, Zcoord); } - for (int i = 0; i < Config.Rare; i++) { + for (int i = 0; i < Config.rare[6]; i++) { Xcoord = blockX + random.nextInt(16); Ycoord = random.nextInt(40) + 20; Zcoord = blockZ + random.nextInt(16); diff --git a/common/mysticworld/Blocks/BlockBushes.java b/common/mysticworld/Blocks/BlockBushes.java new file mode 100644 index 0000000..f933475 --- /dev/null +++ b/common/mysticworld/Blocks/BlockBushes.java @@ -0,0 +1,116 @@ +package mysticworld.blocks; + +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import mysticworld.MysticWorld; +import mysticworld.items.ItemHandler; +import net.minecraft.block.Block; +import net.minecraft.block.BlockBush; +import net.minecraft.block.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.init.Blocks; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.AxisAlignedBB; +import net.minecraft.util.IIcon; +import net.minecraft.world.ColorizerFoliage; +import net.minecraft.world.ColorizerGrass; +import net.minecraft.world.IBlockAccess; +import net.minecraft.world.World; +import net.minecraftforge.common.EnumPlantType; + +import java.util.List; +import java.util.Random; + +public class BlockBushes extends BlockBush { + IIcon[] textures; + + public BlockBushes() { + super(Material.leaves); + setCreativeTab(MysticWorld.MysticWorldTab); + setHardness(0.3F); + setResistance(0.1F); + setStepSound(Block.soundTypeGrass); + setBlockBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.5F, 0.75F); + } + + @Override + @SideOnly(Side.CLIENT) + public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4) { + int l = par1IBlockAccess.getBlockMetadata(par2, par3, par4); + return l == -1 ? 16777215 : par1IBlockAccess.getBiomeGenForCoords(par2, par4).getBiomeGrassColor(par2, par3, par4); + } + + @Override + public int damageDropped(int j) { + return j; + } + + @Override + @SideOnly(Side.CLIENT) + public int getBlockColor() { + double d0 = 0.5D; + double d1 = 1.0D; + return ColorizerGrass.getGrassColor(d0, d1); + } + + @Override + public AxisAlignedBB getCollisionBoundingBoxFromPool(World par1World, int par2, int par3, int par4) { + return AxisAlignedBB.getBoundingBox(par2 + this.getBlockBoundsMinX(), par3 + this.getBlockBoundsMinY(), par4 + this.getBlockBoundsMinZ(), par2 + this.getBlockBoundsMaxX(), par3 + this.getBlockBoundsMaxY(), par4 + this.getBlockBoundsMaxZ()); + } + + @Override + @SideOnly(Side.CLIENT) + public IIcon getIcon(int side, int meta) { + return textures[meta]; + } + + @Override + public EnumPlantType getPlantType(IBlockAccess world, int x, int y, int z) { + return EnumPlantType.Plains; + } + + @Override + @SideOnly(Side.CLIENT) + public int getRenderColor(int par1) { + return par1 == -1 ? 16777215 : ColorizerFoliage.getFoliageColorBasic(); + } + + @Override + public int getRenderType() { + return 0; + } + + @Override + @SideOnly(Side.CLIENT) + public void getSubBlocks(Item i, CreativeTabs tab, List list) { + for (int j = 0; j < 12; j++) { + list.add(new ItemStack(i, 1, j)); + } + } + + @Override + public Item getItemDropped(int par1, Random par2Random, int par3) { + return ItemHandler.bushFruit; + } + + @Override + public int quantityDroppedWithBonus(int par1, Random par2Random) { + return 1 + par2Random.nextInt(par1 * 2 + 1); + } + + @Override + @SideOnly(Side.CLIENT) + public void registerBlockIcons(IIconRegister iconRegister) { + textures = new IIcon[16]; + for (int i = 0; i < 12; i++) { + textures[i] = iconRegister.registerIcon("mysticworld:" + BlockHandler.BUSH_TYPES.get(i)); + } + } + + @Override + protected boolean canPlaceBlockOn(Block par1) { + return par1 == Blocks.grass || par1 == Blocks.dirt; + } +} diff --git a/common/mysticworld/Blocks/ItemBlockMulti.java b/common/mysticworld/Blocks/ItemBlockMulti.java new file mode 100644 index 0000000..2ab15ec --- /dev/null +++ b/common/mysticworld/Blocks/ItemBlockMulti.java @@ -0,0 +1,22 @@ +package mysticworld.blocks; + +import net.minecraft.block.Block; +import net.minecraft.item.ItemBlockWithMetadata; +import net.minecraft.item.ItemStack; +import net.minecraft.util.MathHelper; + +import java.util.ArrayList; + +public class ItemBlockMulti extends ItemBlockWithMetadata { + public final ArrayList names; + public ItemBlockMulti(Block block, ArrayList names) { + super(block, block); + this.names = names; + } + + @Override + public String getUnlocalizedName(ItemStack itemStack) { + int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, names.size()); + return names.get(meta); + } +} diff --git a/common/MysticWorld/Util/CommonProxy.java b/common/mysticworld/CommonProxy.java similarity index 89% rename from common/MysticWorld/Util/CommonProxy.java rename to common/mysticworld/CommonProxy.java index 9ce9558..c2ba2d8 100644 --- a/common/MysticWorld/Util/CommonProxy.java +++ b/common/mysticworld/CommonProxy.java @@ -1,11 +1,8 @@ -package mysticworld.util; +package mysticworld; import net.minecraft.world.World; public class CommonProxy { - public int addArmor(String armor) { - return 0; - } public void airFeetFX(World worldObj, double x, double y, double z, float scale, int age) { } diff --git a/common/mysticworld/WorldGen/WorldGenerators.java b/common/mysticworld/WorldGen/WorldGenerators.java new file mode 100644 index 0000000..080a7cc --- /dev/null +++ b/common/mysticworld/WorldGen/WorldGenerators.java @@ -0,0 +1,35 @@ +package mysticworld.worldgen; + +import cpw.mods.fml.common.IWorldGenerator; +import mysticworld.lib.Booleans; +import net.minecraft.world.World; +import net.minecraft.world.chunk.IChunkProvider; +import net.minecraft.world.gen.feature.WorldGenerator; + +import java.util.Random; + +public class WorldGenerators implements IWorldGenerator { + public static final WorldGenerator bushes = new BushesGen(); + public static final WorldGenerator stones = new StonesGen(); + + @Override + public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) { + if(world.provider.dimensionId==0) { + generateSurface(world, random, chunkX * 16, chunkZ * 16); + } + } + + private void generateSurface(World world, Random random, int blockX, int blockZ) { + int Ycoord1; + if(Booleans.ENABLE_IMBUED_STONE_GEN){ + int Xcoord1 = blockX + random.nextInt(16); + Ycoord1 = random.nextInt(15) + 56; + int Zcoord1 = blockZ + random.nextInt(16); + stones.generate(world, random, Xcoord1, Ycoord1, Zcoord1); + } + if (Booleans.ENABLE_BUSH_GEN){ + Ycoord1 = random.nextInt(11) + 60; + bushes.generate(world, random, blockX + 8, Ycoord1, blockZ + 8); + } + } +} \ No newline at end of file diff --git a/common/MysticWorld/Client/FX/PowerEnergyFX.java b/common/mysticworld/client/fx/PowerFX.java similarity index 86% rename from common/MysticWorld/Client/FX/PowerEnergyFX.java rename to common/mysticworld/client/fx/PowerFX.java index 6df6bde..32dfa4f 100644 --- a/common/MysticWorld/Client/FX/PowerEnergyFX.java +++ b/common/mysticworld/client/fx/PowerFX.java @@ -1,20 +1,21 @@ package mysticworld.client.fx; +import cpw.mods.fml.client.FMLClientHandler; +import mysticworld.client.ClientProxy; import net.minecraft.client.particle.EntityFX; import net.minecraft.client.renderer.Tessellator; import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; - import org.lwjgl.opengl.GL11; -import cpw.mods.fml.client.FMLClientHandler; +public class PowerFX extends EntityFX { + private ResourceLocation textureFX; -public class PowerEnergyFX extends EntityFX { - public PowerEnergyFX(World world, double x, double y, double z) { + public PowerFX(World world, double x, double y, double z) { super(world, x, y, z); } - public PowerEnergyFX(World world, double x, double y, double z, float scale) { + public PowerFX(World world, double x, double y, double z, float scale) { super(world, x, y, z); this.motionX *= 0.019999999552965164D; this.motionY *= 0.019999999552965164D; @@ -60,7 +61,7 @@ public class PowerEnergyFX extends EntityFX { GL11.glDepthMask(false); GL11.glEnable(3042); GL11.glBlendFunc(770, 1); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("MysticMods:textures" + "/misc/energyFX.png")); + FMLClientHandler.instance().getClient().renderEngine.bindTexture(textureFX); GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F); float scale = 0.1F * this.particleScale; float xPos = (float) (this.prevPosX + (this.posX - this.prevPosX) * par2 - interpPosX); @@ -77,7 +78,12 @@ public class PowerEnergyFX extends EntityFX { GL11.glDisable(3042); GL11.glDepthMask(true); GL11.glPopMatrix(); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("minecraft:textures" + "/particle/particles.png")); + FMLClientHandler.instance().getClient().renderEngine.bindTexture(ClientProxy.particle); tessellator.startDrawingQuads(); } + + public PowerFX setTexture(String loc) { + textureFX = new ResourceLocation("mysticworld", "textures/misc/" + loc + "FX.png"); + return this; + } } diff --git a/common/mysticworld/entity/EntityCharge.java b/common/mysticworld/entity/EntityCharge.java new file mode 100644 index 0000000..5afefa2 --- /dev/null +++ b/common/mysticworld/entity/EntityCharge.java @@ -0,0 +1,138 @@ +package mysticworld.entity; + +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import net.minecraft.entity.Entity; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.AxisAlignedBB; +import net.minecraft.util.MathHelper; +import net.minecraft.util.MovingObjectPosition; +import net.minecraft.util.Vec3; +import net.minecraft.world.World; + +import java.util.List; + +public class EntityCharge extends Entity{ + public EntityPlayer shootingEntity; + protected int ticksInAir = 0; + + public EntityCharge(World par1World) { + super(par1World); + } + + public EntityCharge(World par1World, EntityPlayer par2EntityPlayer) { + super(par1World); + this.setSize(0.25F, 0.25F); + this.setLocationAndAngles(par2EntityPlayer.posX, par2EntityPlayer.posY + par2EntityPlayer.getEyeHeight(), par2EntityPlayer.posZ, par2EntityPlayer.rotationYaw, par2EntityPlayer.rotationPitch); + this.setPosition(this.posX, this.posY, this.posZ); + this.motionX = -MathHelper.sin(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); + this.motionY = (-MathHelper.sin((this.rotationPitch) / 180.0F * (float) Math.PI)); + this.motionZ = MathHelper.cos(this.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(this.rotationPitch / 180.0F * (float) Math.PI); + this.shootingEntity = par2EntityPlayer; + } + + @Override + public void onUpdate() { + if (!this.worldObj.isRemote && (this.shootingEntity != null && this.shootingEntity.isDead || !this.worldObj.blockExists((int) this.posX, (int) this.posY, (int) this.posZ))) { + this.setDead(); + } else { + ticksInAir++; + super.onUpdate(); + Vec3 vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ); + Vec3 vec31 = Vec3.createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); + MovingObjectPosition movingobjectposition = this.worldObj.func_147447_a(vec3, vec31, true, true, false); + vec3 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ); + vec31 = Vec3.createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); + if (movingobjectposition != null) { + vec31 = Vec3.createVectorHelper(movingobjectposition.hitVec.xCoord, movingobjectposition.hitVec.yCoord, movingobjectposition.hitVec.zCoord); + } + Entity entity = null; + List list = this.worldObj.getEntitiesWithinAABBExcludingEntity(this, this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D)); + double d0 = 0.0D; + for (int j = 0; j < list.size(); ++j) { + Entity entity1 = (Entity) list.get(j); + if (entity1.canBeCollidedWith() && (!entity1.isEntityEqual(this.shootingEntity) || this.ticksInAir >= 25)) { + AxisAlignedBB axisalignedbb = entity1.boundingBox.expand(0.3F, 0.3F, 0.3F); + MovingObjectPosition movingobjectposition1 = axisalignedbb.calculateIntercept(vec3, vec31); + if (movingobjectposition1 != null) { + double d1 = vec3.distanceTo(movingobjectposition1.hitVec); + if (d1 < d0 || d0 == 0.0D) { + entity = entity1; + d0 = d1; + } + } + } + } + if (entity != null) { + movingobjectposition = new MovingObjectPosition(entity); + } + if (movingobjectposition != null) { + this.onImpact(movingobjectposition); + } + this.posX += this.motionX; + this.posY += this.motionY; + this.posZ += this.motionZ; + if (this.isInWater()) { + for (int k = 0; k < 4; ++k) { + float f3 = 0.25F; + this.worldObj.spawnParticle("bubble", this.posX - this.motionX * f3, this.posY - this.motionY * f3, this.posZ - this.motionZ * f3, this.motionX, this.motionY, this.motionZ); + } + } + chargeFX(); + this.setPosition(this.posX, this.posY, this.posZ); + } + } + + protected void onImpact(MovingObjectPosition par1MovingObjectPosition) {} + + public void chargeFX(){} + + @Override + @SideOnly(Side.CLIENT) + public boolean isInRangeToRenderDist(double par1){ + return par1 > 1.0D && super.isInRangeToRenderDist(par1); + } + + @Override + @SideOnly(Side.CLIENT) + public int getBrightnessForRender(float par1) { + return 15728880; + } + + @Override + public float getCollisionBorderSize() { + return 1.0F; + } + + @Override + @SideOnly(Side.CLIENT) + public float getShadowSize() { + return 0.0F; + } + + @Override + public float getBrightness(float par1) { + return 1.0F; + } + + @Override + protected void entityInit() { + + } + + @Override + protected void readEntityFromNBT(NBTTagCompound var1) { + + } + + @Override + protected void writeEntityToNBT(NBTTagCompound var1) { + + } + + @Override + public boolean canBeCollidedWith() { + return true; + } +} diff --git a/common/mysticworld/items/ItemHandler.java b/common/mysticworld/items/ItemHandler.java index 8c23157..e949b7d 100644 --- a/common/mysticworld/items/ItemHandler.java +++ b/common/mysticworld/items/ItemHandler.java @@ -1,10 +1,11 @@ package mysticworld.items; -import mysticworld.MysticWorld; -import mysticworld.lib.ItemIds; +import cpw.mods.fml.common.registry.GameRegistry; import mysticworld.lib.Strings; import net.minecraft.item.Item; +import java.lang.reflect.Field; + public class ItemHandler { public static Item staffParts; public static Item imbuedShard; @@ -13,12 +14,6 @@ public class ItemHandler { public static Item earthStaff; public static Item airStaff; public static Item energyStaff; - public static Item fireStaffPower; - public static Item waterStaffPower; - public static Item earthStaffPower; - public static Item airStaffPower; - public static Item energyStaffPower; - public static Item staffPower; public static Item fireOrb; public static Item waterOrb; public static Item earthOrb; @@ -44,43 +39,41 @@ public class ItemHandler { public static Item voidShard; public static void init() { - staffParts = new ItemStaffParts(ItemIds.STAFF_PARTS); - imbuedShard = new ItemImbuedShard(ItemIds.IMBUED_SHARD); - bushFruit = new ItemBushFruit(ItemIds.BUSH_FRUIT, 2); - fireStaff = new ItemStaffFire(ItemIds.FIRE_STAFF).setUnlocalizedName(Strings.FIRE_STAFF_NAME); - waterStaff = new ItemStaffWater(ItemIds.WATER_STAFF).setUnlocalizedName(Strings.WATER_STAFF_NAME); - earthStaff = new ItemStaffEarth(ItemIds.EARTH_STAFF).setUnlocalizedName(Strings.EARTH_STAFF_NAME); - airStaff = new ItemStaffAir(ItemIds.AIR_STAFF).setUnlocalizedName(Strings.AIR_STAFF_NAME); - energyStaff = new ItemStaffEnegy(ItemIds.ENERGY_STAFF).setUnlocalizedName(Strings.ENERGY_STAFF_NAME); - staffPower = new ItemStaffPower(ItemIds.STAFF_POWER); - fireOrb = new ItemOrbFire(ItemIds.FIRE_ORB).setUnlocalizedName(Strings.FIRE_ORB_NAME); - waterOrb = new ItemOrbWater(ItemIds.WATER_ORB).setUnlocalizedName(Strings.WATER_ORB_NAME); - earthOrb = new ItemOrbEarth(ItemIds.EARTH_ORB).setUnlocalizedName(Strings.EARTH_ORB_NAME); - airOrb = new ItemOrbAir(ItemIds.AIR_ORB).setUnlocalizedName(Strings.AIR_ORB_NAME); - energyOrb = new ItemOrbEnergy(ItemIds.ENERGY_ORB).setUnlocalizedName(Strings.ENERGY_ORB_NAME); - verditeHelmet = new ItemArmorVerdite(ItemIds.VERDITE_HELMET, EnumArmor.Verdite, MysticWorld.proxy.addArmor(EnumArmor.Verdite.name()), 0).setUnlocalizedName(Strings.VERDITE_HELMET_NAME); - verditeChestplate = new ItemArmorVerdite(ItemIds.VERDITE_CHESTPLATE, EnumArmor.Verdite, MysticWorld.proxy.addArmor(EnumArmor.Verdite.name()), 1) - .setUnlocalizedName(Strings.VERDITE_CHESTPLATE_NAME); - verditeLeggings = new ItemArmorVerdite(ItemIds.VERDITE_LEGGINGS, EnumArmor.Verdite, MysticWorld.proxy.addArmor(EnumArmor.Verdite.name()), 2).setUnlocalizedName(Strings.VERDITE_LEGGINGS_NAME); - verditeBoots = new ItemArmorVerdite(ItemIds.VERDITE_BOOTS, EnumArmor.Verdite, MysticWorld.proxy.addArmor(EnumArmor.Verdite.name()), 3).setUnlocalizedName(Strings.VERDITE_BOOTS_NAME); - mithrilHelmet = new ItemArmorMithril(ItemIds.MITHRIL_HELMET, EnumArmor.Mithril, MysticWorld.proxy.addArmor(EnumArmor.Mithril.name()), 0).setUnlocalizedName(Strings.MITHRIL_HELMET_NAME); - mithrilChestplate = new ItemArmorMithril(ItemIds.MITHRIL_CHESTPLATE, EnumArmor.Mithril, MysticWorld.proxy.addArmor(EnumArmor.Mithril.name()), 1) - .setUnlocalizedName(Strings.MITHRIL_CHESTPLATE_NAME); - mithrilLeggings = new ItemArmorMithril(ItemIds.MITHRIL_LEGGINGS, EnumArmor.Mithril, MysticWorld.proxy.addArmor(EnumArmor.Mithril.name()), 2).setUnlocalizedName(Strings.MITHRIL_LEGGINGS_NAME); - mithrilBoots = new ItemArmorMithril(ItemIds.MITHRIL_BOOTS, EnumArmor.Mithril, MysticWorld.proxy.addArmor(EnumArmor.Mithril.name()), 3).setUnlocalizedName(Strings.MITHRIL_BOOTS_NAME); - adamantineHelmet = new ItemArmorAdamantine(ItemIds.ADAMANTINE_HELMET, EnumArmor.Adamantine, MysticWorld.proxy.addArmor(EnumArmor.Adamantine.name()), 0) - .setUnlocalizedName(Strings.ADAMANTINE_HELMET_NAME); - adamantineChestplate = new ItemArmorAdamantine(ItemIds.ADAMANTINE_CHESTPLATE, EnumArmor.Adamantine, MysticWorld.proxy.addArmor(EnumArmor.Adamantine.name()), 1) - .setUnlocalizedName(Strings.ADAMANTINE_CHESTPLATE_NAME); - adamantineLeggings = new ItemArmorAdamantine(ItemIds.ADAMANTINE_LEGGINGS, EnumArmor.Adamantine, MysticWorld.proxy.addArmor(EnumArmor.Adamantine.name()), 2) - .setUnlocalizedName(Strings.ADAMANTINE_LEGGINGS_NAME); - adamantineBoots = new ItemArmorAdamantine(ItemIds.ADAMANTINE_BOOTS, EnumArmor.Adamantine, MysticWorld.proxy.addArmor(EnumArmor.Adamantine.name()), 3) - .setUnlocalizedName(Strings.ADAMANTINE_BOOTS_NAME); - iridiumHelmet = new ItemArmorIridium(ItemIds.IRIDIUM_HELMET, EnumArmor.Iridium, MysticWorld.proxy.addArmor(EnumArmor.Iridium.name()), 0).setUnlocalizedName(Strings.IRIDIUM_HELMET_NAME); - iridiumChestplate = new ItemArmorIridium(ItemIds.IRIDIUM_CHESTPLATE, EnumArmor.Iridium, MysticWorld.proxy.addArmor(EnumArmor.Iridium.name()), 1) - .setUnlocalizedName(Strings.IRIDIUM_CHESTPLATE_NAME); - iridiumLeggings = new ItemArmorIridium(ItemIds.IRIDIUM_LEGGINGS, EnumArmor.Iridium, MysticWorld.proxy.addArmor(EnumArmor.Iridium.name()), 2).setUnlocalizedName(Strings.IRIDIUM_LEGGINGS_NAME); - iridiumBoots = new ItemArmorIridium(ItemIds.IRIDIUM_BOOTS, EnumArmor.Iridium, MysticWorld.proxy.addArmor(EnumArmor.Iridium.name()), 3).setUnlocalizedName(Strings.IRIDIUM_BOOTS_NAME); - voidShard = new ItemVoidShard(ItemIds.VOID_SHARD).setUnlocalizedName(Strings.VOID_SHARD_NAME); + staffParts = new ItemStaffParts().setUnlocalizedName(Strings.STAFF_PART_NAME); + imbuedShard = new ItemImbuedShard().setUnlocalizedName(Strings.IMBUED_SHARD_NAME); + bushFruit = new ItemBushFruit(2).setUnlocalizedName(Strings.BUSH_FRUIT_NAME); + fireStaff = new ItemStaffFire().setUnlocalizedName(Strings.FIRE_STAFF_NAME); + waterStaff = new ItemStaffWater().setUnlocalizedName(Strings.WATER_STAFF_NAME); + earthStaff = new ItemStaffEarth().setUnlocalizedName(Strings.EARTH_STAFF_NAME); + airStaff = new ItemStaffAir().setUnlocalizedName(Strings.AIR_STAFF_NAME); + energyStaff = new ItemStaffEnegy().setUnlocalizedName(Strings.ENERGY_STAFF_NAME); + fireOrb = new ItemOrbFire().setUnlocalizedName(Strings.FIRE_ORB_NAME); + waterOrb = new ItemOrbWater().setUnlocalizedName(Strings.WATER_ORB_NAME); + earthOrb = new ItemOrbEarth().setUnlocalizedName(Strings.EARTH_ORB_NAME); + airOrb = new ItemOrbAir().setUnlocalizedName(Strings.AIR_ORB_NAME); + energyOrb = new ItemOrbEnergy().setUnlocalizedName(Strings.ENERGY_ORB_NAME); + verditeHelmet = new ItemMaterialArmor(EnumArmor.Verdite, 0).setUnlocalizedName(Strings.VERDITE_HELMET_NAME).setMaxDamage(262); + verditeChestplate = new ItemMaterialArmor(EnumArmor.Verdite, 1).setUnlocalizedName(Strings.VERDITE_CHESTPLATE_NAME).setMaxDamage(262); + verditeLeggings = new ItemMaterialArmor(EnumArmor.Verdite, 2).setUnlocalizedName(Strings.VERDITE_LEGGINGS_NAME).setMaxDamage(262); + verditeBoots = new ItemMaterialArmor(EnumArmor.Verdite, 3).setUnlocalizedName(Strings.VERDITE_BOOTS_NAME).setMaxDamage(262); + mithrilHelmet = new ItemMaterialArmor(EnumArmor.Mithril, 0).setUnlocalizedName(Strings.MITHRIL_HELMET_NAME).setMaxDamage(500); + mithrilChestplate = new ItemMaterialArmor(EnumArmor.Mithril, 1).setUnlocalizedName(Strings.MITHRIL_CHESTPLATE_NAME).setMaxDamage(500); + mithrilLeggings = new ItemMaterialArmor(EnumArmor.Mithril, 2).setUnlocalizedName(Strings.MITHRIL_LEGGINGS_NAME).setMaxDamage(500); + mithrilBoots = new ItemMaterialArmor(EnumArmor.Mithril, 3).setUnlocalizedName(Strings.MITHRIL_BOOTS_NAME).setMaxDamage(500); + adamantineHelmet = new ItemMaterialArmor(EnumArmor.Adamantine, 0).setUnlocalizedName(Strings.ADAMANTINE_HELMET_NAME).setMaxDamage(3000); + adamantineChestplate = new ItemMaterialArmor(EnumArmor.Adamantine, 1).setUnlocalizedName(Strings.ADAMANTINE_CHESTPLATE_NAME).setMaxDamage(3000); + adamantineLeggings = new ItemMaterialArmor(EnumArmor.Adamantine, 2).setUnlocalizedName(Strings.ADAMANTINE_LEGGINGS_NAME).setMaxDamage(3000); + adamantineBoots = new ItemMaterialArmor(EnumArmor.Adamantine, 3).setUnlocalizedName(Strings.ADAMANTINE_BOOTS_NAME).setMaxDamage(3000); + iridiumHelmet = new ItemArmorIridium(EnumArmor.Iridium, 0).setUnlocalizedName(Strings.IRIDIUM_HELMET_NAME); + iridiumChestplate = new ItemArmorIridium(EnumArmor.Iridium, 1).setUnlocalizedName(Strings.IRIDIUM_CHESTPLATE_NAME); + iridiumLeggings = new ItemArmorIridium(EnumArmor.Iridium, 2).setUnlocalizedName(Strings.IRIDIUM_LEGGINGS_NAME); + iridiumBoots = new ItemArmorIridium(EnumArmor.Iridium, 3).setUnlocalizedName(Strings.IRIDIUM_BOOTS_NAME); + voidShard = new ItemVoidShard().setUnlocalizedName(Strings.VOID_SHARD_NAME).setTextureName("mysticworld:ShardVoid"); + for(Field f:ItemHandler.class.getFields()){ + try{ + Item item = (Item)f.get(null); + GameRegistry.registerItem(item,item.getUnlocalizedName().substring(5)); + }catch (Exception e){} + } } } diff --git a/common/mysticworld/items/ItemMaterialArmor.java b/common/mysticworld/items/ItemMaterialArmor.java new file mode 100644 index 0000000..2ec2004 --- /dev/null +++ b/common/mysticworld/items/ItemMaterialArmor.java @@ -0,0 +1,25 @@ +package mysticworld.items; + +import mysticworld.MysticWorld; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.entity.Entity; +import net.minecraft.item.ItemArmor; +import net.minecraft.item.ItemStack; + +public class ItemMaterialArmor extends ItemArmor{ + public ItemMaterialArmor(ArmorMaterial par2EnumArmorMaterial, int par4) { + super(par2EnumArmorMaterial, 0, par4); + this.setCreativeTab(MysticWorld.MysticWorldTab); + } + + @Override + public String getArmorTexture(ItemStack stack, Entity entity, int slot, String layer) { + int suffix = this.armorType == 2 ? 2 : 1; + return "mysticworld:textures/models/armor/"+getArmorMaterial().name()+"_layer_" + suffix + ".png"; + } + + @Override + public void registerIcons(IIconRegister iconRegister) { + itemIcon = iconRegister.registerIcon("mysticworld:"+getArmorMaterial().name()+"Armor_" + armorType); + } +} diff --git a/common/mysticworld/renderer/BaseItemRenderer.java b/common/mysticworld/renderer/BaseItemRenderer.java new file mode 100644 index 0000000..688e5c4 --- /dev/null +++ b/common/mysticworld/renderer/BaseItemRenderer.java @@ -0,0 +1,39 @@ +package mysticworld.renderer; + +import net.minecraft.item.ItemStack; +import net.minecraft.util.ResourceLocation; +import net.minecraftforge.client.IItemRenderer; + +public abstract class BaseItemRenderer implements IItemRenderer { + protected final ResourceLocation texture; + + public BaseItemRenderer(String loc) { + texture = new ResourceLocation("mysticworld", "textures/models/" + loc + ".png"); + } + + @Override + public boolean handleRenderType(ItemStack item, ItemRenderType type) { + switch (type) { + case ENTITY: + case EQUIPPED: + case EQUIPPED_FIRST_PERSON: + case INVENTORY: + return true; + default: + return false; + } + } + + @Override + public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { + switch (type) { + case ENTITY: + case EQUIPPED: + case INVENTORY: + case EQUIPPED_FIRST_PERSON: + return true; + default: + return false; + } + } +} diff --git a/common/MysticWorld/Renderer/ItemOrbAirRenderer.java b/common/mysticworld/renderer/OrbItemRenderer.java similarity index 51% rename from common/MysticWorld/Renderer/ItemOrbAirRenderer.java rename to common/mysticworld/renderer/OrbItemRenderer.java index d76d1cd..ce1cb75 100644 --- a/common/MysticWorld/Renderer/ItemOrbAirRenderer.java +++ b/common/mysticworld/renderer/OrbItemRenderer.java @@ -1,35 +1,15 @@ package mysticworld.renderer; +import cpw.mods.fml.client.FMLClientHandler; import mysticworld.model.ModelOrb; import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - import org.lwjgl.opengl.GL11; -import cpw.mods.fml.client.FMLClientHandler; +public class OrbItemRenderer extends BaseItemRenderer { + private final ModelOrb modelOrb = new ModelOrb(); -public class ItemOrbAirRenderer implements IItemRenderer { - private ModelOrb modelOrb; - - public ItemOrbAirRenderer() { - modelOrb = new ModelOrb(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } + public OrbItemRenderer(String loc) { + super("Orb" + loc); } @Override @@ -58,25 +38,9 @@ public class ItemOrbAirRenderer implements IItemRenderer { GL11.glTranslatef(x, y, z); GL11.glScalef(scale, scale, scale); GL11.glRotatef(180f, 0f, 1f, 0f); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/OrbAir.png")); + FMLClientHandler.instance().getClient().renderEngine.bindTexture(texture); modelOrb.render(); GL11.glEnable(GL11.GL_LIGHTING); GL11.glPopMatrix(); } - - @Override - public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case INVENTORY: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - default: - return false; - } - } } diff --git a/common/MysticWorld/Renderer/ItemStaffAirRenderer.java b/common/mysticworld/renderer/StaffItemRenderer.java similarity index 68% rename from common/MysticWorld/Renderer/ItemStaffAirRenderer.java rename to common/mysticworld/renderer/StaffItemRenderer.java index a232d72..7c6228b 100644 --- a/common/MysticWorld/Renderer/ItemStaffAirRenderer.java +++ b/common/mysticworld/renderer/StaffItemRenderer.java @@ -1,35 +1,15 @@ package mysticworld.renderer; +import cpw.mods.fml.client.FMLClientHandler; import mysticworld.model.ModelStaff; import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; -import net.minecraftforge.client.IItemRenderer; - import org.lwjgl.opengl.GL11; -import cpw.mods.fml.client.FMLClientHandler; +public class StaffItemRenderer extends BaseItemRenderer { + private final ModelStaff model = new ModelStaff(); -public class ItemStaffAirRenderer implements IItemRenderer { - private final ModelStaff model; - - public ItemStaffAirRenderer() { - this.model = new ModelStaff(); - } - - @Override - public boolean handleRenderType(ItemStack item, ItemRenderType type) { - switch (type) { - case ENTITY: - return true; - case EQUIPPED: - return true; - case EQUIPPED_FIRST_PERSON: - return true; - case INVENTORY: - return true; - default: - return false; - } + public StaffItemRenderer(String loc) { + super("Staff" + loc); } @Override @@ -56,13 +36,8 @@ public class ItemStaffAirRenderer implements IItemRenderer { public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) { switch (type) { case ENTITY: - return true; - case EQUIPPED: - return false; case INVENTORY: return true; - case EQUIPPED_FIRST_PERSON: - return false; default: return false; } @@ -74,7 +49,7 @@ public class ItemStaffAirRenderer implements IItemRenderer { GL11.glScalef(scale, scale, scale); GL11.glTranslatef(x, y, z); GL11.glRotatef(180.0F, 0.0F, 0.0F, 0.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffAir.png")); + FMLClientHandler.instance().getClient().renderEngine.bindTexture(texture); model.renderModel(0.0625f); GL11.glEnable(GL11.GL_LIGHTING); GL11.glPopMatrix(); @@ -87,7 +62,7 @@ public class ItemStaffAirRenderer implements IItemRenderer { GL11.glTranslatef(x, y, z); GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F); GL11.glRotatef(-45.0F, 0.0F, 0.0F, 1.0F); - FMLClientHandler.instance().getClient().renderEngine.bindTexture(new ResourceLocation("mysticmods:textures" + "/models/StaffAir.png")); + FMLClientHandler.instance().getClient().renderEngine.bindTexture(texture); model.renderModel(0.0625f); GL11.glEnable(GL11.GL_LIGHTING); GL11.glPopMatrix(); diff --git a/common/mysticworld/tiles/TileEntityHandler.java b/common/mysticworld/tiles/TileEntityHandler.java index 44e712d..89cfc07 100644 --- a/common/mysticworld/tiles/TileEntityHandler.java +++ b/common/mysticworld/tiles/TileEntityHandler.java @@ -1,7 +1,7 @@ package mysticworld.tiles; -import mysticworld.lib.Strings; import cpw.mods.fml.common.registry.GameRegistry; +import mysticworld.lib.Strings; public class TileEntityHandler { public static void init() { diff --git a/common/mysticworld/tiles/TileEntityPillarInsert.java b/common/mysticworld/tiles/TileEntityPillarInsert.java index c74307f..dea1dfa 100644 --- a/common/mysticworld/tiles/TileEntityPillarInsert.java +++ b/common/mysticworld/tiles/TileEntityPillarInsert.java @@ -1,9 +1,9 @@ package mysticworld.tiles; 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.network.NetworkManager; +import net.minecraft.network.Packet; +import net.minecraft.network.play.server.S35PacketUpdateTileEntity; import net.minecraft.tileentity.TileEntity; public class TileEntityPillarInsert extends TileEntity { @@ -11,21 +11,11 @@ public class TileEntityPillarInsert extends TileEntity { public Packet getDescriptionPacket() { NBTTagCompound nbtTag = new NBTTagCompound(); this.writeToNBT(nbtTag); - return new Packet132TileEntityData(this.xCoord, this.yCoord, this.zCoord, 1, nbtTag); + return new S35PacketUpdateTileEntity(this.xCoord, this.yCoord, this.zCoord, 1, nbtTag); } @Override - public void onDataPacket(INetworkManager net, Packet132TileEntityData packet) { - readFromNBT(packet.data); - } - - @Override - public void readFromNBT(NBTTagCompound par1) { - super.readFromNBT(par1); - } - - @Override - public void writeToNBT(NBTTagCompound par1) { - super.writeToNBT(par1); + public void onDataPacket(NetworkManager net, S35PacketUpdateTileEntity packet) { + readFromNBT(packet.func_148857_g()); } }