From 8fc70259e7fbec6ff7eb9707ff6a1e1cee396ebd Mon Sep 17 00:00:00 2001 From: CongratsIsTrash <1q2w3e4dasd@gmail.com> Date: Mon, 17 Jun 2024 11:43:49 -0400 Subject: [PATCH] Fixed NER recoil changing based on bullet velocity --- Items/Weapons/Ranged/NitroExpressRifle.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Items/Weapons/Ranged/NitroExpressRifle.cs b/Items/Weapons/Ranged/NitroExpressRifle.cs index eab45c79d1..c7111ac95b 100644 --- a/Items/Weapons/Ranged/NitroExpressRifle.cs +++ b/Items/Weapons/Ranged/NitroExpressRifle.cs @@ -65,7 +65,9 @@ namespace CalamityMod.Items.Weapons.Ranged public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback) { - player.velocity += -velocity * 0.3f; + Vector2 recoilVelocity = velocity; + recoilVelocity.Normalize(); + player.velocity += -recoilVelocity * 7f; if (type == ProjectileID.Bullet) type = ModContent.ProjectileType(); Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI, 0f);