From d34f691e0af74ee20c4247e220d95d2da41069be Mon Sep 17 00:00:00 2001 From: Adubbz Date: Mon, 1 Apr 2013 08:58:42 +1100 Subject: [PATCH 1/5] Made achievements configurable --- .../tdwp_ftw/biomesop/mod_BiomesOPlenty.java | 139 ++++++++++-------- 1 file changed, 75 insertions(+), 64 deletions(-) diff --git a/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java b/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java index 31878b394..1cd146f1e 100644 --- a/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java +++ b/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java @@ -79,6 +79,7 @@ public class mod_BiomesOPlenty config.load(); skyColors = true; biomeSize = config.get("Biome Settings", "Biome Size", 4, null).getInt(); + achievements = config.get("Achievement Settings", "Add Biomes O Plenty Achievemnets (Currently Broken)", false).getBoolean(false); addToDefault = config.get("Biome Settings", "Add Biomes To Default World", false).getBoolean(false); vanillaEnhanced = config.get("Biome Settings", "Enhanced Vanilla Biomes", true).getBoolean(false); promisedLandDimID = config.get("Dimension Settings", "Promised Land Dimension ID", 20, null).getInt(); @@ -676,19 +677,22 @@ public class mod_BiomesOPlenty bootsAmethyst = (new ArmorAmethyst(bootsAmethystID, EnumArmorMaterialAmethyst, proxy.addArmor("amethyst"), 3)).setCreativeTab(tabBiomesOPlenty).setUnlocalizedName("bootsAmethyst"); // Achievement declaration - achFlower2 = (new Achievement(3057, "achFlower2", 0, 0, Block.plantRed, (Achievement)null)).registerAchievement(); - achRedRock2 = (new Achievement(3058, "achRedRock2", -1, 2, redRock, achFlower2)).registerAchievement(); - achThorn2 = (new Achievement(3059, "achThorn2", 2, 1, thorn, achFlower2)).registerAchievement(); - achAsh2 = (new Achievement(3060, "achAsh2", 1, 3, ashes, achFlower2)).registerAchievement(); - achOrigin2 = (new Achievement(3061, "achOrigin2", 0, 5, originGrass, achFlower2)).setSpecial().registerAchievement(); - achPromised2 = (new Achievement(3062, "achPromised2", 0, -5, holyGrass, achFlower2)).setSpecial().registerAchievement(); - achMud2 = (new Achievement(3063, "achMud2", -2, -1, mudBall, achFlower2)).registerAchievement(); - achShroom2 = (new Achievement(3064, "achShroom2", 1, -2, toadstool, achFlower2)).registerAchievement(); - achBarley2 = (new Achievement(3065, "achBarley2", -2, 4, barleyItem, achFlower2)).registerAchievement(); - achMoss2 = (new Achievement(3066, "achMoss2", -1, -3, mossItem, achFlower2)).registerAchievement(); - - pageBOP = new AchievementPage("Biomes O\' Plenty", achFlower2, achRedRock2, achThorn2, achAsh2, achOrigin2, achPromised2, achMud2, achShroom2, achBarley2, achMoss2); - AchievementPage.registerAchievementPage(pageBOP); + if (achievements == true) + { + achFlower2 = (new Achievement(3057, "achFlower2", 0, 0, Block.plantRed, (Achievement)null)).registerAchievement(); + achRedRock2 = (new Achievement(3058, "achRedRock2", -1, 2, redRock, achFlower2)).registerAchievement(); + achThorn2 = (new Achievement(3059, "achThorn2", 2, 1, thorn, achFlower2)).registerAchievement(); + achAsh2 = (new Achievement(3060, "achAsh2", 1, 3, ashes, achFlower2)).registerAchievement(); + achOrigin2 = (new Achievement(3061, "achOrigin2", 0, 5, originGrass, achFlower2)).setSpecial().registerAchievement(); + achPromised2 = (new Achievement(3062, "achPromised2", 0, -5, holyGrass, achFlower2)).setSpecial().registerAchievement(); + achMud2 = (new Achievement(3063, "achMud2", -2, -1, mudBall, achFlower2)).registerAchievement(); + achShroom2 = (new Achievement(3064, "achShroom2", 1, -2, toadstool, achFlower2)).registerAchievement(); + achBarley2 = (new Achievement(3065, "achBarley2", -2, 4, barleyItem, achFlower2)).registerAchievement(); + achMoss2 = (new Achievement(3066, "achMoss2", -1, -3, mossItem, achFlower2)).registerAchievement(); + + pageBOP = new AchievementPage("Biomes O\' Plenty", achFlower2, achRedRock2, achThorn2, achAsh2, achOrigin2, achPromised2, achMud2, achShroom2, achBarley2, achMoss2); + AchievementPage.registerAchievementPage(pageBOP); + } // Add block names LanguageRegistry.addName(mud, "Mud"); @@ -1217,17 +1221,20 @@ public class mod_BiomesOPlenty GameRegistry.addSmelting(redRockCobble.blockID, new ItemStack(redRock, 1), 0.1F); GameRegistry.addSmelting(tinyCactus.blockID, new ItemStack(Item.dyePowder, 1, 2), 0.2F); - // Add Achievement registration - addAchievementDesc("achFlower2", "Flower Child", "Pick some flowers!"); - addAchievementDesc("achRedRock2", "Red Rocky Mountain High", "Dig out some red rocks."); - addAchievementDesc("achThorn2", "Rather Thorny...", "Don\'t get cut!"); - addAchievementDesc("achAsh2", "Ash-ievement", "Get it? \'Cause it\'s ash."); - addAchievementDesc("achOrigin2", "Alpha...", "Get some grass from the Origin Valley."); - addAchievementDesc("achPromised2", "...Omega", "Welcome to the Promised Land!"); - addAchievementDesc("achMud2", "Sticky Situation", "I just had these boots cleaned!"); - addAchievementDesc("achShroom2", "Trippin\'", "Don\'t try this at home, kids!"); - addAchievementDesc("achBarley2", "Fields Of Gold", "Upon the fields of barley."); - addAchievementDesc("achMoss2", "Mossman", "Mothman's long-lost cousin."); + if (achievements == true) + { + // Add Achievement registration + addAchievementDesc("achFlower2", "Flower Child", "Pick some flowers!"); + addAchievementDesc("achRedRock2", "Red Rocky Mountain High", "Dig out some red rocks."); + addAchievementDesc("achThorn2", "Rather Thorny...", "Don\'t get cut!"); + addAchievementDesc("achAsh2", "Ash-ievement", "Get it? \'Cause it\'s ash."); + addAchievementDesc("achOrigin2", "Alpha...", "Get some grass from the Origin Valley."); + addAchievementDesc("achPromised2", "...Omega", "Welcome to the Promised Land!"); + addAchievementDesc("achMud2", "Sticky Situation", "I just had these boots cleaned!"); + addAchievementDesc("achShroom2", "Trippin\'", "Don\'t try this at home, kids!"); + addAchievementDesc("achBarley2", "Fields Of Gold", "Upon the fields of barley."); + addAchievementDesc("achMoss2", "Mossman", "Mothman's long-lost cousin."); + } LanguageRegistry.instance().addStringLocalization("generator.BIOMESOP", "en_US", "Biomes O\' Plenty"); @@ -2245,6 +2252,7 @@ public class mod_BiomesOPlenty private Configuration config; public static boolean skyColors; public static int biomeSize; + public static boolean achievements; public static boolean addToDefault; public static boolean vanillaEnhanced; public static int promisedLandDimID; @@ -2805,46 +2813,49 @@ public class mod_BiomesOPlenty // Achievement checker public static void onItemPickup(EntityPlayer player, ItemStack item) { - if (item.itemID == glowFlower.blockID || item.itemID == orangeFlower.blockID || item.itemID == blueFlower.blockID || item.itemID == purpleFlower.blockID || item.itemID == pinkFlower.blockID || item.itemID == whiteFlower.blockID || item.itemID == tinyFlower.blockID || item.itemID == deathbloom.blockID || item.itemID == hydrangea.blockID || item.itemID == violet.blockID || item.itemID == Block.plantRed.blockID || item.itemID == Block.plantYellow.blockID) - { - player.addStat(achFlower2, 1); - } - if (item.itemID == redRockCobble.blockID) - { - player.addStat(achRedRock2, 1); - } - if (item.itemID == thorn.blockID) - { - player.addStat(achThorn2, 1); - } - if (item.itemID == ashes.itemID) - { - player.addStat(achAsh2, 1); - } - if (item.itemID == originGrass.blockID) - { - player.addStat(achOrigin2, 1); - } - if (item.itemID == holyGrass.blockID || item.itemID == holyStone.blockID) - { - player.addStat(achPromised2, 1); - } - if (item.itemID == mudBall.itemID) - { - player.addStat(achMud2, 1); - } - if (item.itemID == toadstool.blockID) - { - player.addStat(achShroom2, 1); - } - if (item.itemID == barleyItem.itemID) - { - player.addStat(achBarley2, 1); - } - if (item.itemID == mossItem.itemID) - { - player.addStat(achMoss2, 1); - } + if (achievements == true) + { + if (item.itemID == glowFlower.blockID || item.itemID == orangeFlower.blockID || item.itemID == blueFlower.blockID || item.itemID == purpleFlower.blockID || item.itemID == pinkFlower.blockID || item.itemID == whiteFlower.blockID || item.itemID == tinyFlower.blockID || item.itemID == deathbloom.blockID || item.itemID == hydrangea.blockID || item.itemID == violet.blockID || item.itemID == Block.plantRed.blockID || item.itemID == Block.plantYellow.blockID) + { + player.addStat(achFlower2, 1); + } + if (item.itemID == redRockCobble.blockID) + { + player.addStat(achRedRock2, 1); + } + if (item.itemID == thorn.blockID) + { + player.addStat(achThorn2, 1); + } + if (item.itemID == ashes.itemID) + { + player.addStat(achAsh2, 1); + } + if (item.itemID == originGrass.blockID) + { + player.addStat(achOrigin2, 1); + } + if (item.itemID == holyGrass.blockID || item.itemID == holyStone.blockID) + { + player.addStat(achPromised2, 1); + } + if (item.itemID == mudBall.itemID) + { + player.addStat(achMud2, 1); + } + if (item.itemID == toadstool.blockID) + { + player.addStat(achShroom2, 1); + } + if (item.itemID == barleyItem.itemID) + { + player.addStat(achBarley2, 1); + } + if (item.itemID == mossItem.itemID) + { + player.addStat(achMoss2, 1); + } + } } public static void addAchievementDesc(String ach, String name, String desc) From 12231459948c08760569335d821e98f64ebea3b7 Mon Sep 17 00:00:00 2001 From: Adubbz Date: Mon, 1 Apr 2013 16:07:44 +1100 Subject: [PATCH 2/5] Fixed all the tools being swords, fixed the duplicate messages on creation of the Promised Lands portal as well as fancying it up :) Also fixed a bug where you could get an endless supply of endstone by recreating the portal. --- .../biomesop/items/ItemAncientStaff.java | 226 +++++++++--------- .../tdwp_ftw/biomesop/items/ItemBOPAxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPHoe.java | 3 +- .../biomesop/items/ItemBOPPickaxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPSpade.java | 3 +- 5 files changed, 125 insertions(+), 113 deletions(-) diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java index 9661d0ed7..4d61cadad 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java @@ -35,117 +35,125 @@ public class ItemAncientStaff extends Item public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { if (par3EntityPlayer.dimension == 0) + { + + if (par2World.getBlockId(0, 64 - 32, 0) != mod_BiomesOPlenty.promisedPortal.blockID) { - par3EntityPlayer.addChatMessage("A gateway to the Promised Land has been buried at the origin of this world."); - - int var99 = 32; - - par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 1, 0); - par2World.setBlock(0, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 0, 0); - par2World.setBlock(1, 63 - var99, -1, 0); - par2World.setBlock(0, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, 0, 0); - par2World.setBlock(0, 63 - var99, 0, 0); - - par2World.setBlock(-1, 64 - var99, 1, 0); - par2World.setBlock(0, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 0, 0); - par2World.setBlock(1, 64 - var99, -1, 0); - par2World.setBlock(0, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, 0, 0); - - par2World.setBlock(-1, 65 - var99, 1, 0); - par2World.setBlock(0, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 0, 0); - par2World.setBlock(1, 65 - var99, -1, 0); - par2World.setBlock(0, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, 0, 0); - par2World.setBlock(0, 65 - var99, 0, 0); - - par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); - - par2World.setBlock(-2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, -2, 0); - par2World.setBlock(-2, 64 - var99, -2, 0); - - par2World.setBlock(-2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, -2, 0); - par2World.setBlock(-2, 65 - var99, -2, 0); - - par2World.setBlock(-2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, -2, 0); - par2World.setBlock(-2, 66 - var99, -2, 0); + + if (!par3EntityPlayer.worldObj.isRemote) + { + par3EntityPlayer.addChatMessage("\u00a75A gateway to the \u00a76\u00a7l\u00a7nPromised Land\u00a75 has been buried at the origin of this world."); + } + + int var99 = 32; + + par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 1, 0); + par2World.setBlock(0, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 0, 0); + par2World.setBlock(1, 63 - var99, -1, 0); + par2World.setBlock(0, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, 0, 0); + par2World.setBlock(0, 63 - var99, 0, 0); + + par2World.setBlock(-1, 64 - var99, 1, 0); + par2World.setBlock(0, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 0, 0); + par2World.setBlock(1, 64 - var99, -1, 0); + par2World.setBlock(0, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, 0, 0); + + par2World.setBlock(-1, 65 - var99, 1, 0); + par2World.setBlock(0, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 0, 0); + par2World.setBlock(1, 65 - var99, -1, 0); + par2World.setBlock(0, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, 0, 0); + par2World.setBlock(0, 65 - var99, 0, 0); + + par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); + + par2World.setBlock(-2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, -2, 0); + par2World.setBlock(-2, 64 - var99, -2, 0); + + par2World.setBlock(-2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, -2, 0); + par2World.setBlock(-2, 65 - var99, -2, 0); + + par2World.setBlock(-2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, -2, 0); + par2World.setBlock(-2, 66 - var99, -2, 0); } - + } + return par1ItemStack; } } diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java index 2eb524fc1..b41880cfa 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemAxe; import net.minecraft.item.ItemSword; -public class ItemBOPAxe extends ItemSword +public class ItemBOPAxe extends ItemAxe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java index 69f6c1940..e0d8655b4 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemHoe; import net.minecraft.item.ItemSword; -public class ItemBOPHoe extends ItemSword +public class ItemBOPHoe extends ItemHoe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java index 3202d6e42..ca00102eb 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemPickaxe; import net.minecraft.item.ItemSword; -public class ItemBOPPickaxe extends ItemSword +public class ItemBOPPickaxe extends ItemPickaxe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java index 47146ac86..4f2a26122 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemSpade; import net.minecraft.item.ItemSword; -public class ItemBOPSpade extends ItemSword +public class ItemBOPSpade extends ItemSpade { public int TextureID = 0; From 9f8c33526e98c4464d5faf4e6185f851222035d1 Mon Sep 17 00:00:00 2001 From: Adubbz Date: Mon, 1 Apr 2013 16:09:50 +1100 Subject: [PATCH 3/5] Revert "Fixed all the tools being swords, fixed the duplicate messages on creation of the Promised Lands portal as well as fancying it up :) Also fixed a bug where you could get an endless supply of endstone by recreating the portal." This reverts commit 12231459948c08760569335d821e98f64ebea3b7. --- .../biomesop/items/ItemAncientStaff.java | 226 +++++++++--------- .../tdwp_ftw/biomesop/items/ItemBOPAxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPHoe.java | 3 +- .../biomesop/items/ItemBOPPickaxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPSpade.java | 3 +- 5 files changed, 113 insertions(+), 125 deletions(-) diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java index 4d61cadad..9661d0ed7 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java @@ -35,125 +35,117 @@ public class ItemAncientStaff extends Item public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { if (par3EntityPlayer.dimension == 0) - { - - if (par2World.getBlockId(0, 64 - 32, 0) != mod_BiomesOPlenty.promisedPortal.blockID) { - - if (!par3EntityPlayer.worldObj.isRemote) - { - par3EntityPlayer.addChatMessage("\u00a75A gateway to the \u00a76\u00a7l\u00a7nPromised Land\u00a75 has been buried at the origin of this world."); - } - - int var99 = 32; - - par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 1, 0); - par2World.setBlock(0, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 0, 0); - par2World.setBlock(1, 63 - var99, -1, 0); - par2World.setBlock(0, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, 0, 0); - par2World.setBlock(0, 63 - var99, 0, 0); - - par2World.setBlock(-1, 64 - var99, 1, 0); - par2World.setBlock(0, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 0, 0); - par2World.setBlock(1, 64 - var99, -1, 0); - par2World.setBlock(0, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, 0, 0); - - par2World.setBlock(-1, 65 - var99, 1, 0); - par2World.setBlock(0, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 0, 0); - par2World.setBlock(1, 65 - var99, -1, 0); - par2World.setBlock(0, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, 0, 0); - par2World.setBlock(0, 65 - var99, 0, 0); - - par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); - - par2World.setBlock(-2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, -2, 0); - par2World.setBlock(-2, 64 - var99, -2, 0); - - par2World.setBlock(-2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, -2, 0); - par2World.setBlock(-2, 65 - var99, -2, 0); - - par2World.setBlock(-2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, -2, 0); - par2World.setBlock(-2, 66 - var99, -2, 0); + par3EntityPlayer.addChatMessage("A gateway to the Promised Land has been buried at the origin of this world."); + + int var99 = 32; + + par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 1, 0); + par2World.setBlock(0, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 0, 0); + par2World.setBlock(1, 63 - var99, -1, 0); + par2World.setBlock(0, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, 0, 0); + par2World.setBlock(0, 63 - var99, 0, 0); + + par2World.setBlock(-1, 64 - var99, 1, 0); + par2World.setBlock(0, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 0, 0); + par2World.setBlock(1, 64 - var99, -1, 0); + par2World.setBlock(0, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, 0, 0); + + par2World.setBlock(-1, 65 - var99, 1, 0); + par2World.setBlock(0, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 0, 0); + par2World.setBlock(1, 65 - var99, -1, 0); + par2World.setBlock(0, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, 0, 0); + par2World.setBlock(0, 65 - var99, 0, 0); + + par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); + + par2World.setBlock(-2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, -2, 0); + par2World.setBlock(-2, 64 - var99, -2, 0); + + par2World.setBlock(-2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, -2, 0); + par2World.setBlock(-2, 65 - var99, -2, 0); + + par2World.setBlock(-2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, -2, 0); + par2World.setBlock(-2, 66 - var99, -2, 0); } - } - + return par1ItemStack; } } diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java index b41880cfa..2eb524fc1 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java @@ -2,10 +2,9 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemAxe; import net.minecraft.item.ItemSword; -public class ItemBOPAxe extends ItemAxe +public class ItemBOPAxe extends ItemSword { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java index e0d8655b4..69f6c1940 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java @@ -2,10 +2,9 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemHoe; import net.minecraft.item.ItemSword; -public class ItemBOPHoe extends ItemHoe +public class ItemBOPHoe extends ItemSword { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java index ca00102eb..3202d6e42 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java @@ -2,10 +2,9 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemPickaxe; import net.minecraft.item.ItemSword; -public class ItemBOPPickaxe extends ItemPickaxe +public class ItemBOPPickaxe extends ItemSword { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java index 4f2a26122..47146ac86 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java @@ -2,10 +2,9 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; -import net.minecraft.item.ItemSpade; import net.minecraft.item.ItemSword; -public class ItemBOPSpade extends ItemSpade +public class ItemBOPSpade extends ItemSword { public int TextureID = 0; From d24610896ebc3135731610cad6345ece86e0b012 Mon Sep 17 00:00:00 2001 From: Adubbz Date: Mon, 1 Apr 2013 16:10:09 +1100 Subject: [PATCH 4/5] Revert "Revert "Fixed all the tools being swords, fixed the duplicate messages on creation of the Promised Lands portal as well as fancying it up :) Also fixed a bug where you could get an endless supply of endstone by recreating the portal."" This reverts commit 9f8c33526e98c4464d5faf4e6185f851222035d1. --- .../biomesop/items/ItemAncientStaff.java | 226 +++++++++--------- .../tdwp_ftw/biomesop/items/ItemBOPAxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPHoe.java | 3 +- .../biomesop/items/ItemBOPPickaxe.java | 3 +- .../tdwp_ftw/biomesop/items/ItemBOPSpade.java | 3 +- 5 files changed, 125 insertions(+), 113 deletions(-) diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java index 9661d0ed7..4d61cadad 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemAncientStaff.java @@ -35,117 +35,125 @@ public class ItemAncientStaff extends Item public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer) { if (par3EntityPlayer.dimension == 0) + { + + if (par2World.getBlockId(0, 64 - 32, 0) != mod_BiomesOPlenty.promisedPortal.blockID) { - par3EntityPlayer.addChatMessage("A gateway to the Promised Land has been buried at the origin of this world."); - - int var99 = 32; - - par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); - - par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); - par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); - par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); - - par2World.setBlock(-1, 63 - var99, 1, 0); - par2World.setBlock(0, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 1, 0); - par2World.setBlock(1, 63 - var99, 0, 0); - par2World.setBlock(1, 63 - var99, -1, 0); - par2World.setBlock(0, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, -1, 0); - par2World.setBlock(-1, 63 - var99, 0, 0); - par2World.setBlock(0, 63 - var99, 0, 0); - - par2World.setBlock(-1, 64 - var99, 1, 0); - par2World.setBlock(0, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 1, 0); - par2World.setBlock(1, 64 - var99, 0, 0); - par2World.setBlock(1, 64 - var99, -1, 0); - par2World.setBlock(0, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, -1, 0); - par2World.setBlock(-1, 64 - var99, 0, 0); - - par2World.setBlock(-1, 65 - var99, 1, 0); - par2World.setBlock(0, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 1, 0); - par2World.setBlock(1, 65 - var99, 0, 0); - par2World.setBlock(1, 65 - var99, -1, 0); - par2World.setBlock(0, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, -1, 0); - par2World.setBlock(-1, 65 - var99, 0, 0); - par2World.setBlock(0, 65 - var99, 0, 0); - - par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); - - par2World.setBlock(-2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, 2, 0); - par2World.setBlock(2, 64 - var99, -2, 0); - par2World.setBlock(-2, 64 - var99, -2, 0); - - par2World.setBlock(-2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, 2, 0); - par2World.setBlock(2, 65 - var99, -2, 0); - par2World.setBlock(-2, 65 - var99, -2, 0); - - par2World.setBlock(-2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, 2, 0); - par2World.setBlock(2, 66 - var99, -2, 0); - par2World.setBlock(-2, 66 - var99, -2, 0); + + if (!par3EntityPlayer.worldObj.isRemote) + { + par3EntityPlayer.addChatMessage("\u00a75A gateway to the \u00a76\u00a7l\u00a7nPromised Land\u00a75 has been buried at the origin of this world."); + } + + int var99 = 32; + + par2World.setBlock(-1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 62 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 62 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 63 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 63 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 64 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 64 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, 2, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(0, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-1, 65 - var99, -2, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(-2, 65 - var99, 1, Block.whiteStone.blockID); + + par2World.setBlock(-1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 1, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, -1, Block.whiteStone.blockID); + par2World.setBlock(-1, 66 - var99, 0, Block.whiteStone.blockID); + par2World.setBlock(0, 66 - var99, 0, Block.whiteStone.blockID); + + par2World.setBlock(-1, 63 - var99, 1, 0); + par2World.setBlock(0, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 1, 0); + par2World.setBlock(1, 63 - var99, 0, 0); + par2World.setBlock(1, 63 - var99, -1, 0); + par2World.setBlock(0, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, -1, 0); + par2World.setBlock(-1, 63 - var99, 0, 0); + par2World.setBlock(0, 63 - var99, 0, 0); + + par2World.setBlock(-1, 64 - var99, 1, 0); + par2World.setBlock(0, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 1, 0); + par2World.setBlock(1, 64 - var99, 0, 0); + par2World.setBlock(1, 64 - var99, -1, 0); + par2World.setBlock(0, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, -1, 0); + par2World.setBlock(-1, 64 - var99, 0, 0); + + par2World.setBlock(-1, 65 - var99, 1, 0); + par2World.setBlock(0, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 1, 0); + par2World.setBlock(1, 65 - var99, 0, 0); + par2World.setBlock(1, 65 - var99, -1, 0); + par2World.setBlock(0, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, -1, 0); + par2World.setBlock(-1, 65 - var99, 0, 0); + par2World.setBlock(0, 65 - var99, 0, 0); + + par2World.setBlock(0, 64 - var99, 0, mod_BiomesOPlenty.promisedPortal.blockID); + + par2World.setBlock(-2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, 2, 0); + par2World.setBlock(2, 64 - var99, -2, 0); + par2World.setBlock(-2, 64 - var99, -2, 0); + + par2World.setBlock(-2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, 2, 0); + par2World.setBlock(2, 65 - var99, -2, 0); + par2World.setBlock(-2, 65 - var99, -2, 0); + + par2World.setBlock(-2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, 2, 0); + par2World.setBlock(2, 66 - var99, -2, 0); + par2World.setBlock(-2, 66 - var99, -2, 0); } - + } + return par1ItemStack; } } diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java index 2eb524fc1..b41880cfa 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPAxe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemAxe; import net.minecraft.item.ItemSword; -public class ItemBOPAxe extends ItemSword +public class ItemBOPAxe extends ItemAxe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java index 69f6c1940..e0d8655b4 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPHoe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemHoe; import net.minecraft.item.ItemSword; -public class ItemBOPHoe extends ItemSword +public class ItemBOPHoe extends ItemHoe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java index 3202d6e42..ca00102eb 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPPickaxe.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemPickaxe; import net.minecraft.item.ItemSword; -public class ItemBOPPickaxe extends ItemSword +public class ItemBOPPickaxe extends ItemPickaxe { public int TextureID = 0; diff --git a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java index 47146ac86..4f2a26122 100644 --- a/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java +++ b/src/minecraft/tdwp_ftw/biomesop/items/ItemBOPSpade.java @@ -2,9 +2,10 @@ package tdwp_ftw.biomesop.items; import net.minecraft.client.renderer.texture.IconRegister; import net.minecraft.item.EnumToolMaterial; +import net.minecraft.item.ItemSpade; import net.minecraft.item.ItemSword; -public class ItemBOPSpade extends ItemSword +public class ItemBOPSpade extends ItemSpade { public int TextureID = 0; From 46a4b164581573b6c0d605eaa6ed44c69eda745e Mon Sep 17 00:00:00 2001 From: Adubbz Date: Mon, 1 Apr 2013 16:16:07 +1100 Subject: [PATCH 5/5] Revert "Made achievements configurable" This reverts commit d34f691e0af74ee20c4247e220d95d2da41069be. --- .../tdwp_ftw/biomesop/mod_BiomesOPlenty.java | 139 ++++++++---------- 1 file changed, 64 insertions(+), 75 deletions(-) diff --git a/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java b/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java index 1cd146f1e..31878b394 100644 --- a/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java +++ b/src/minecraft/tdwp_ftw/biomesop/mod_BiomesOPlenty.java @@ -79,7 +79,6 @@ public class mod_BiomesOPlenty config.load(); skyColors = true; biomeSize = config.get("Biome Settings", "Biome Size", 4, null).getInt(); - achievements = config.get("Achievement Settings", "Add Biomes O Plenty Achievemnets (Currently Broken)", false).getBoolean(false); addToDefault = config.get("Biome Settings", "Add Biomes To Default World", false).getBoolean(false); vanillaEnhanced = config.get("Biome Settings", "Enhanced Vanilla Biomes", true).getBoolean(false); promisedLandDimID = config.get("Dimension Settings", "Promised Land Dimension ID", 20, null).getInt(); @@ -677,22 +676,19 @@ public class mod_BiomesOPlenty bootsAmethyst = (new ArmorAmethyst(bootsAmethystID, EnumArmorMaterialAmethyst, proxy.addArmor("amethyst"), 3)).setCreativeTab(tabBiomesOPlenty).setUnlocalizedName("bootsAmethyst"); // Achievement declaration - if (achievements == true) - { - achFlower2 = (new Achievement(3057, "achFlower2", 0, 0, Block.plantRed, (Achievement)null)).registerAchievement(); - achRedRock2 = (new Achievement(3058, "achRedRock2", -1, 2, redRock, achFlower2)).registerAchievement(); - achThorn2 = (new Achievement(3059, "achThorn2", 2, 1, thorn, achFlower2)).registerAchievement(); - achAsh2 = (new Achievement(3060, "achAsh2", 1, 3, ashes, achFlower2)).registerAchievement(); - achOrigin2 = (new Achievement(3061, "achOrigin2", 0, 5, originGrass, achFlower2)).setSpecial().registerAchievement(); - achPromised2 = (new Achievement(3062, "achPromised2", 0, -5, holyGrass, achFlower2)).setSpecial().registerAchievement(); - achMud2 = (new Achievement(3063, "achMud2", -2, -1, mudBall, achFlower2)).registerAchievement(); - achShroom2 = (new Achievement(3064, "achShroom2", 1, -2, toadstool, achFlower2)).registerAchievement(); - achBarley2 = (new Achievement(3065, "achBarley2", -2, 4, barleyItem, achFlower2)).registerAchievement(); - achMoss2 = (new Achievement(3066, "achMoss2", -1, -3, mossItem, achFlower2)).registerAchievement(); - - pageBOP = new AchievementPage("Biomes O\' Plenty", achFlower2, achRedRock2, achThorn2, achAsh2, achOrigin2, achPromised2, achMud2, achShroom2, achBarley2, achMoss2); - AchievementPage.registerAchievementPage(pageBOP); - } + achFlower2 = (new Achievement(3057, "achFlower2", 0, 0, Block.plantRed, (Achievement)null)).registerAchievement(); + achRedRock2 = (new Achievement(3058, "achRedRock2", -1, 2, redRock, achFlower2)).registerAchievement(); + achThorn2 = (new Achievement(3059, "achThorn2", 2, 1, thorn, achFlower2)).registerAchievement(); + achAsh2 = (new Achievement(3060, "achAsh2", 1, 3, ashes, achFlower2)).registerAchievement(); + achOrigin2 = (new Achievement(3061, "achOrigin2", 0, 5, originGrass, achFlower2)).setSpecial().registerAchievement(); + achPromised2 = (new Achievement(3062, "achPromised2", 0, -5, holyGrass, achFlower2)).setSpecial().registerAchievement(); + achMud2 = (new Achievement(3063, "achMud2", -2, -1, mudBall, achFlower2)).registerAchievement(); + achShroom2 = (new Achievement(3064, "achShroom2", 1, -2, toadstool, achFlower2)).registerAchievement(); + achBarley2 = (new Achievement(3065, "achBarley2", -2, 4, barleyItem, achFlower2)).registerAchievement(); + achMoss2 = (new Achievement(3066, "achMoss2", -1, -3, mossItem, achFlower2)).registerAchievement(); + + pageBOP = new AchievementPage("Biomes O\' Plenty", achFlower2, achRedRock2, achThorn2, achAsh2, achOrigin2, achPromised2, achMud2, achShroom2, achBarley2, achMoss2); + AchievementPage.registerAchievementPage(pageBOP); // Add block names LanguageRegistry.addName(mud, "Mud"); @@ -1221,20 +1217,17 @@ public class mod_BiomesOPlenty GameRegistry.addSmelting(redRockCobble.blockID, new ItemStack(redRock, 1), 0.1F); GameRegistry.addSmelting(tinyCactus.blockID, new ItemStack(Item.dyePowder, 1, 2), 0.2F); - if (achievements == true) - { - // Add Achievement registration - addAchievementDesc("achFlower2", "Flower Child", "Pick some flowers!"); - addAchievementDesc("achRedRock2", "Red Rocky Mountain High", "Dig out some red rocks."); - addAchievementDesc("achThorn2", "Rather Thorny...", "Don\'t get cut!"); - addAchievementDesc("achAsh2", "Ash-ievement", "Get it? \'Cause it\'s ash."); - addAchievementDesc("achOrigin2", "Alpha...", "Get some grass from the Origin Valley."); - addAchievementDesc("achPromised2", "...Omega", "Welcome to the Promised Land!"); - addAchievementDesc("achMud2", "Sticky Situation", "I just had these boots cleaned!"); - addAchievementDesc("achShroom2", "Trippin\'", "Don\'t try this at home, kids!"); - addAchievementDesc("achBarley2", "Fields Of Gold", "Upon the fields of barley."); - addAchievementDesc("achMoss2", "Mossman", "Mothman's long-lost cousin."); - } + // Add Achievement registration + addAchievementDesc("achFlower2", "Flower Child", "Pick some flowers!"); + addAchievementDesc("achRedRock2", "Red Rocky Mountain High", "Dig out some red rocks."); + addAchievementDesc("achThorn2", "Rather Thorny...", "Don\'t get cut!"); + addAchievementDesc("achAsh2", "Ash-ievement", "Get it? \'Cause it\'s ash."); + addAchievementDesc("achOrigin2", "Alpha...", "Get some grass from the Origin Valley."); + addAchievementDesc("achPromised2", "...Omega", "Welcome to the Promised Land!"); + addAchievementDesc("achMud2", "Sticky Situation", "I just had these boots cleaned!"); + addAchievementDesc("achShroom2", "Trippin\'", "Don\'t try this at home, kids!"); + addAchievementDesc("achBarley2", "Fields Of Gold", "Upon the fields of barley."); + addAchievementDesc("achMoss2", "Mossman", "Mothman's long-lost cousin."); LanguageRegistry.instance().addStringLocalization("generator.BIOMESOP", "en_US", "Biomes O\' Plenty"); @@ -2252,7 +2245,6 @@ public class mod_BiomesOPlenty private Configuration config; public static boolean skyColors; public static int biomeSize; - public static boolean achievements; public static boolean addToDefault; public static boolean vanillaEnhanced; public static int promisedLandDimID; @@ -2813,49 +2805,46 @@ public class mod_BiomesOPlenty // Achievement checker public static void onItemPickup(EntityPlayer player, ItemStack item) { - if (achievements == true) - { - if (item.itemID == glowFlower.blockID || item.itemID == orangeFlower.blockID || item.itemID == blueFlower.blockID || item.itemID == purpleFlower.blockID || item.itemID == pinkFlower.blockID || item.itemID == whiteFlower.blockID || item.itemID == tinyFlower.blockID || item.itemID == deathbloom.blockID || item.itemID == hydrangea.blockID || item.itemID == violet.blockID || item.itemID == Block.plantRed.blockID || item.itemID == Block.plantYellow.blockID) - { - player.addStat(achFlower2, 1); - } - if (item.itemID == redRockCobble.blockID) - { - player.addStat(achRedRock2, 1); - } - if (item.itemID == thorn.blockID) - { - player.addStat(achThorn2, 1); - } - if (item.itemID == ashes.itemID) - { - player.addStat(achAsh2, 1); - } - if (item.itemID == originGrass.blockID) - { - player.addStat(achOrigin2, 1); - } - if (item.itemID == holyGrass.blockID || item.itemID == holyStone.blockID) - { - player.addStat(achPromised2, 1); - } - if (item.itemID == mudBall.itemID) - { - player.addStat(achMud2, 1); - } - if (item.itemID == toadstool.blockID) - { - player.addStat(achShroom2, 1); - } - if (item.itemID == barleyItem.itemID) - { - player.addStat(achBarley2, 1); - } - if (item.itemID == mossItem.itemID) - { - player.addStat(achMoss2, 1); - } - } + if (item.itemID == glowFlower.blockID || item.itemID == orangeFlower.blockID || item.itemID == blueFlower.blockID || item.itemID == purpleFlower.blockID || item.itemID == pinkFlower.blockID || item.itemID == whiteFlower.blockID || item.itemID == tinyFlower.blockID || item.itemID == deathbloom.blockID || item.itemID == hydrangea.blockID || item.itemID == violet.blockID || item.itemID == Block.plantRed.blockID || item.itemID == Block.plantYellow.blockID) + { + player.addStat(achFlower2, 1); + } + if (item.itemID == redRockCobble.blockID) + { + player.addStat(achRedRock2, 1); + } + if (item.itemID == thorn.blockID) + { + player.addStat(achThorn2, 1); + } + if (item.itemID == ashes.itemID) + { + player.addStat(achAsh2, 1); + } + if (item.itemID == originGrass.blockID) + { + player.addStat(achOrigin2, 1); + } + if (item.itemID == holyGrass.blockID || item.itemID == holyStone.blockID) + { + player.addStat(achPromised2, 1); + } + if (item.itemID == mudBall.itemID) + { + player.addStat(achMud2, 1); + } + if (item.itemID == toadstool.blockID) + { + player.addStat(achShroom2, 1); + } + if (item.itemID == barleyItem.itemID) + { + player.addStat(achBarley2, 1); + } + if (item.itemID == mossItem.itemID) + { + player.addStat(achMoss2, 1); + } } public static void addAchievementDesc(String ach, String name, String desc)