diff --git a/mods/tinker/resources/manuals/materials.xml b/mods/tinker/resources/manuals/materials.xml index fd7fb81..ca8125d 100644 --- a/mods/tinker/resources/manuals/materials.xml +++ b/mods/tinker/resources/manuals/materials.xml @@ -387,7 +387,7 @@ Natural Abilities: Class: Heavy Melee Weapon cleavericon - Large Blade + Large Sword Blade largeswordblade diff --git a/mods/tinker/tconstruct/TConstruct.java b/mods/tinker/tconstruct/TConstruct.java index c7f5542..945a22c 100644 --- a/mods/tinker/tconstruct/TConstruct.java +++ b/mods/tinker/tconstruct/TConstruct.java @@ -38,7 +38,7 @@ import cpw.mods.fml.common.registry.VillagerRegistry; * @dependencies: IC2 API, MFR API */ -@Mod(modid = "TConstruct", name = "TConstruct", version = "1.5.1_1.3.dev.67", dependencies = "required-after:Forge@[7.7.1.675,)") +@Mod(modid = "TConstruct", name = "TConstruct", version = "1.5.1_1.3.dev.69", dependencies = "required-after:Forge@[7.7.1.675,)") @NetworkMod(serverSideRequired = false, clientSideRequired = true, channels = { "TConstruct" }, packetHandler = mods.tinker.tconstruct.util.network.TPacketHandler.class) public class TConstruct { diff --git a/mods/tinker/tconstruct/common/TContent.java b/mods/tinker/tconstruct/common/TContent.java index c46c382..a46d201 100644 --- a/mods/tinker/tconstruct/common/TContent.java +++ b/mods/tinker/tconstruct/common/TContent.java @@ -399,6 +399,22 @@ public class TContent implements IFuelHandler metalPattern = new MetalPattern(PHConstruct.metalPattern, "MetalPattern", "cast_", "materials/").setUnlocalizedName("tconstruct.MetalPattern"); //netherPattern = new Pattern(PHTools.netherPattern, 128, patternTexture).setUnlocalizedName("tconstruct.Pattern"); + TConstructRegistry.addItemToDirectory("blankPattern", blankPattern); + TConstructRegistry.addItemToDirectory("woodPattern", woodPattern); + TConstructRegistry.addItemToDirectory("metalPattern", metalPattern); + + String[] patternTypes = { "ingot", "toolRod", "pickaxeHead", "shovelHead", "hatchetHead", "swordBlade", "wideGuard", "handGuard", "crossbar", "binding", "frypanHead", "signHead", + "knifeBlade", "chiselHead", "toughRod", "toughBinding", "largePlate", "broadAxeHead", "scytheHead", "excavatorHead", "largeBlade", "hammerHead", "fullGuard" }; + + for (int i = 1; i < patternTypes.length; i++) + { + TConstructRegistry.addItemStackToDirectory(patternTypes[i] + "Pattern", new ItemStack(woodPattern, 1, i)); + } + for (int i = 0; i < patternTypes.length; i++) + { + TConstructRegistry.addItemStackToDirectory(patternTypes[i] + "Cast", new ItemStack(metalPattern, 1, i)); + } + manualBook = new Manual(PHConstruct.manual); buckets = new FilledBucket(PHConstruct.buckets); @@ -1040,8 +1056,11 @@ public class TContent implements IFuelHandler GameRegistry.addRecipe(new ItemStack(knapsack, 1, 0), "###", "rmr", "###", '#', new ItemStack(Item.leather), 'r', new ItemStack(toughRod, 1, 2), 'm', new ItemStack(materials, 1, 14)); //Remove vanilla recipes - RecipeRemover.removeShapedRecipe(new ItemStack(Block.blockIron)); - RecipeRemover.removeShapedRecipe(new ItemStack(Block.blockGold)); + if (!PHConstruct.vanillaMetalBlocks) + { + RecipeRemover.removeShapedRecipe(new ItemStack(Block.blockIron)); + RecipeRemover.removeShapedRecipe(new ItemStack(Block.blockGold)); + } } void setupToolTabs () diff --git a/mods/tinker/tconstruct/items/tools/Battleaxe.java b/mods/tinker/tconstruct/items/tools/Battleaxe.java index 68f3dda..2d8d8ca 100644 --- a/mods/tinker/tconstruct/items/tools/Battleaxe.java +++ b/mods/tinker/tconstruct/items/tools/Battleaxe.java @@ -52,7 +52,7 @@ public class Battleaxe extends HarvestTool return AbilityHelper.onBlockChanged(itemstack, world, bID, x, y, z, player, random); } - static Material[] materials = { Material.wood, Material.leaves, Material.vine, Material.circuits, Material.cactus, Material.pumpkin }; + static Material[] materials = { Material.wood, Material.vine, Material.circuits, Material.cactus, Material.pumpkin }; @Override public Item getHeadItem () @@ -153,45 +153,64 @@ public class Battleaxe extends HarvestTool } /* Battleaxe Specific */ + + @Override + public boolean onItemUse (ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float clickX, float clickY, float clickZ) + { + return false; + } + @Override public EnumAction getItemUseAction (ItemStack par1ItemStack) { return EnumAction.bow; } + @Override public ItemStack onItemRightClick (ItemStack stack, World world, EntityPlayer player) { - if (player.onGround) - { + //player.rotationYaw += 1; + //if (player.onGround) + //{ player.setItemInUse(stack, this.getMaxItemUseDuration(stack)); - //player.motionY += 0.52; - } + //} return stack; } @Override public void onPlayerStoppedUsing (ItemStack stack, World world, EntityPlayer player, int useCount) { - player.addExhaustion(0.2F); - world.playSoundEffect(player.posX, player.posY, player.posZ, "sounds.frypan_hit", 1.0F, (random.nextFloat() - random.nextFloat()) * 0.2F + 1.0F); - player.swingItem(); - /*player.setSprinting(true); + //if (player.onGround) + { + int time = this.getMaxItemUseDuration(stack) - useCount; + int boost = time / 100; + if (boost > 2) + boost = 2; + player.addPotionEffect(new PotionEffect(Potion.moveSpeed.id, time*4, boost)); + player.addPotionEffect(new PotionEffect(Potion.jump.id, time*4, boost)); + if (time > 5 && player.onGround) + { + player.addExhaustion(0.2F); + player.setSprinting(true); - float increase = (float) (0.02 * 20 + 0.2); - if (increase > 0.56f) - increase = 0.56f; - player.motionY += increase; + float speed = 0.025F * time; + if (speed > 0.925f) + speed = 0.925f; - float speed = 0.05F * 20; - if (speed > 0.925f) - speed = 0.925f; - player.motionX = (double) (-MathHelper.sin(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed); - player.motionZ = (double) (MathHelper.cos(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed);*/ + float increase = (float) (0.02 * time + 0.2); + if (increase > 0.56f) + increase = 0.56f; + player.motionY += increase; + + player.motionX = (double) (-MathHelper.sin(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed); + player.motionZ = (double) (MathHelper.cos(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed); + } + } } public int getMaxItemUseDuration (ItemStack par1ItemStack) { - return 80; + return 72000; } @Override @@ -201,7 +220,7 @@ public class Battleaxe extends HarvestTool return true; } - @Override + /*@Override public void onUpdate (ItemStack stack, World world, Entity entity, int par4, boolean par5) { super.onUpdate(stack, world, entity, par4, par5); @@ -214,7 +233,7 @@ public class Battleaxe extends HarvestTool player.addPotionEffect(new PotionEffect(Potion.digSlowdown.id, 1, 1)); } } - } + }*/ @Override public boolean onBlockStartBreak (ItemStack stack, int x, int y, int z, EntityPlayer player) diff --git a/mods/tinker/tconstruct/items/tools/Longsword.java b/mods/tinker/tconstruct/items/tools/Longsword.java index 75c2fc2..f8c2018 100644 --- a/mods/tinker/tconstruct/items/tools/Longsword.java +++ b/mods/tinker/tconstruct/items/tools/Longsword.java @@ -40,6 +40,27 @@ public class Longsword extends Weapon public void onPlayerStoppedUsing (ItemStack stack, World world, EntityPlayer player, int useCount) { + /*if (player.onGround) + { + int time = this.getMaxItemUseDuration(stack) - useCount; + if (time > 5) + { + player.addExhaustion(0.2F); + player.setSprinting(true); + + float speed = 0.05F * time; + if (speed > 0.925f) + speed = 0.925f; + + float increase = (float) (0.02 * time + 0.2); + if (increase > 0.56f) + increase = 0.56f; + player.motionY += increase + speed/3; + + player.motionX = (double) (-MathHelper.sin(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed); + player.motionZ = (double) (MathHelper.cos(player.rotationYaw / 180.0F * (float) Math.PI) * MathHelper.cos(player.rotationPitch / 180.0F * (float) Math.PI) * speed); + } + }*/ int time = this.getMaxItemUseDuration(stack) - useCount; if (time > 5) { diff --git a/mods/tinker/tconstruct/library/TConstructRegistry.java b/mods/tinker/tconstruct/library/TConstructRegistry.java index c1d1962..521babb 100644 --- a/mods/tinker/tconstruct/library/TConstructRegistry.java +++ b/mods/tinker/tconstruct/library/TConstructRegistry.java @@ -36,6 +36,9 @@ public class TConstructRegistry * frypan, battlesign, mattock, chisel * lumberaxe, cleaver, scythe, excavator, hammer, battleaxe * + * Patterns: + * blankPattern, woodPattern, metalPattern + * * Tool crafting parts: * toolRod, toolShard, binding, toughBinding, toughRod, heavyPlate * pickaxeHead, shovelhead, hatchetHead, swordBlade, wideguard, handGuard, crossbar, knifeBlade, @@ -84,6 +87,9 @@ public class TConstructRegistry * oreberryIron, oreberryGold, oreberryCopper, oreberryTin, oreberryTin, oreberrySilver, * diamondApple, blueSlimeFood, canisterEmpty, miniRedHeart, canisterRedHeart * + * Patterns - These have a suffix of Pattern or Cast. ex: hatchetHeadPattern + * ingot, toolRod, pickaxeHead, shovelHead, hatchetHead, swordBlade, wideGuard, handGuard, crossbar, binding, frypanHead, signHead, + * knifeBlade, chiselHead, toughRod, toughBinding, largePlate, broadAxeHead, scytheHead, excavatorHead, largeBlade, hammerHead, fullGuard */ static HashMap itemstackDirectory = new HashMap(); diff --git a/mods/tinker/tconstruct/util/PHConstruct.java b/mods/tinker/tconstruct/util/PHConstruct.java index 6205fe1..513fb28 100644 --- a/mods/tinker/tconstruct/util/PHConstruct.java +++ b/mods/tinker/tconstruct/util/PHConstruct.java @@ -59,6 +59,7 @@ public class PHConstruct enableTCactus = config.get("Difficulty Changes", "Enable mod cactus tools", true).getBoolean(true); enableTBone = config.get("Difficulty Changes", "Enable mod bone tools", true).getBoolean(true); craftMetalTools = config.get("Difficulty Changes", "Craft metals with Wood Patterns", false).getBoolean(false); + craftMetalTools = config.get("Difficulty Changes", "Craft vanilla metal blocks", true).getBoolean(true); blueSlime = config.get("Mob Spawning", "Activate Blue Slime Spawns", true).getBoolean(true); blueSlimeWeight = config.get("Mob Spawning", "Spawn Weight for Blue Slime", 7).getInt(7); @@ -466,6 +467,7 @@ public class PHConstruct public static boolean enableTBone; public static boolean craftMetalTools; + public static boolean vanillaMetalBlocks; //Superfun public static boolean superfunWorld; diff --git a/mods/tinker/textures/items/axe/beheading_axe_effect.png b/mods/tinker/textures/items/axe/beheading_axe_effect.png new file mode 100644 index 0000000..a7e5414 Binary files /dev/null and b/mods/tinker/textures/items/axe/beheading_axe_effect.png differ diff --git a/mods/tinker/textures/items/axe/piston_axe_effect.png b/mods/tinker/textures/items/axe/piston_axe_effect.png new file mode 100644 index 0000000..fb28c9b Binary files /dev/null and b/mods/tinker/textures/items/axe/piston_axe_effect.png differ diff --git a/mods/tinker/textures/items/axe/smite_axe_effect.png b/mods/tinker/textures/items/axe/smite_axe_effect.png new file mode 100644 index 0000000..712e0ef Binary files /dev/null and b/mods/tinker/textures/items/axe/smite_axe_effect.png differ diff --git a/mods/tinker/textures/items/axe/spider_axe_effect.png b/mods/tinker/textures/items/axe/spider_axe_effect.png new file mode 100644 index 0000000..016911d Binary files /dev/null and b/mods/tinker/textures/items/axe/spider_axe_effect.png differ diff --git a/mods/tinker/textures/items/excavator/quartz_excavator_effect.png b/mods/tinker/textures/items/excavator/quartz_excavator_effect.png new file mode 100644 index 0000000..3a8cd2c Binary files /dev/null and b/mods/tinker/textures/items/excavator/quartz_excavator_effect.png differ diff --git a/mods/tinker/textures/items/shovel/beheading_shovel_effect.png b/mods/tinker/textures/items/shovel/beheading_shovel_effect.png new file mode 100644 index 0000000..ddec07e Binary files /dev/null and b/mods/tinker/textures/items/shovel/beheading_shovel_effect.png differ diff --git a/mods/tinker/textures/items/shovel/piston_shovel_effect.png b/mods/tinker/textures/items/shovel/piston_shovel_effect.png new file mode 100644 index 0000000..1262761 Binary files /dev/null and b/mods/tinker/textures/items/shovel/piston_shovel_effect.png differ diff --git a/mods/tinker/textures/items/shovel/smite_shovel_effect.png b/mods/tinker/textures/items/shovel/smite_shovel_effect.png new file mode 100644 index 0000000..841e095 Binary files /dev/null and b/mods/tinker/textures/items/shovel/smite_shovel_effect.png differ diff --git a/mods/tinker/textures/items/shovel/spider_shovel_effect.png b/mods/tinker/textures/items/shovel/spider_shovel_effect.png new file mode 100644 index 0000000..852d6b5 Binary files /dev/null and b/mods/tinker/textures/items/shovel/spider_shovel_effect.png differ diff --git a/spritesheets/broadsword.png b/spritesheets/broadsword.png index a61d6ec..ad5d7a6 100644 Binary files a/spritesheets/broadsword.png and b/spritesheets/broadsword.png differ diff --git a/spritesheets/shovels.png b/spritesheets/shovels.png index 2fc25f3..9594b59 100644 Binary files a/spritesheets/shovels.png and b/spritesheets/shovels.png differ