From 64e822626e26175f359721799b4335307c5aee17 Mon Sep 17 00:00:00 2001 From: garyantonyo Date: Thu, 22 Jul 2021 11:12:21 -0400 Subject: [PATCH] update PotatoCannonItem damage description to reflect changes to PotatoProjectileEntity --- .../content/curiosities/weapons/PotatoCannonItem.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/simibubi/create/content/curiosities/weapons/PotatoCannonItem.java b/src/main/java/com/simibubi/create/content/curiosities/weapons/PotatoCannonItem.java index 6e2b6c9e8..7c7db65a1 100644 --- a/src/main/java/com/simibubi/create/content/curiosities/weapons/PotatoCannonItem.java +++ b/src/main/java/com/simibubi/create/content/curiosities/weapons/PotatoCannonItem.java @@ -161,7 +161,7 @@ public class PotatoCannonItem extends ShootableItem { Vector3d sprayOffset = VecHelper.rotate(sprayBase, i * sprayChange + imperfection, Axis.Z); splitMotion = splitMotion.add(VecHelper.lookAt(sprayOffset, motion)); } - + if (i != 0) projectile.recoveryChance = 0; @@ -226,9 +226,9 @@ public class PotatoCannonItem extends ShootableItem { public void appendHoverText(ItemStack stack, World world, List tooltip, ITooltipFlag flag) { int power = EnchantmentHelper.getItemEnchantmentLevel(Enchantments.POWER_ARROWS, stack); int punch = EnchantmentHelper.getItemEnchantmentLevel(Enchantments.PUNCH_ARROWS, stack); - final float additionalDamage = power * 2; + final float additionalDamageMult = 1 + power * .2f; final float additionalKnockback = punch * .5f; - + getAmmoforPreview(stack).ifPresent(ammo -> { String _attack = "potato_cannon.ammo.attack_damage"; String _reload = "potato_cannon.ammo.reload_ticks"; @@ -243,14 +243,14 @@ public class PotatoCannonItem extends ShootableItem { TextFormatting green = TextFormatting.GREEN; TextFormatting darkGreen = TextFormatting.DARK_GREEN; - float damageF = type.getDamage() + additionalDamage; + float damageF = type.getDamage() * additionalDamageMult; IFormattableTextComponent damage = new StringTextComponent( damageF == MathHelper.floor(damageF) ? "" + MathHelper.floor(damageF) : "" + damageF); IFormattableTextComponent reloadTicks = new StringTextComponent("" + type.getReloadTicks()); IFormattableTextComponent knockback = new StringTextComponent("" + (type.getKnockback() + additionalKnockback)); - damage = damage.withStyle(additionalDamage > 0 ? green : darkGreen); + damage = damage.withStyle(additionalDamageMult > 1 ? green : darkGreen); knockback = knockback.withStyle(additionalKnockback > 0 ? green : darkGreen); reloadTicks = reloadTicks.withStyle(darkGreen);