Files
CalamityModPublic/Items/Weapons/Rogue/BurningStrife.cs
T
Ozzatron 22afdd3933 1 - Calamity sell prices increase much more sharply with rarity.
2 - (Example) Post DoG items are now 2 platinum instead of 1 platinum 40 gold.
3 - (Example) Dev items are now 2 platinum 80 gold instead of 2 platinum.
4 - Privated numeric rarity item values.
5 - All assigned item values use the rarity's names, e.g. RarityLightPurpleBuyPrice.
2024-04-17 21:20:17 -04:00

51 lines
1.8 KiB
C#

using CalamityMod.Projectiles.Rogue;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.DataStructures;
using Terraria.ID;
using Terraria.ModLoader;
namespace CalamityMod.Items.Weapons.Rogue
{
public class BurningStrife : RogueWeapon
{
public override void SetDefaults()
{
Item.width = 16;
Item.height = 28;
Item.UseSound = SoundID.Item1;
Item.useStyle = ItemUseStyleID.Swing;
Item.value = CalamityGlobalItem.RarityPinkBuyPrice;
Item.rare = ItemRarityID.Pink;
Item.autoReuse = true;
Item.noUseGraphic = true;
Item.noMelee = true;
Item.useAnimation = 25;
Item.useTime = 25;
Item.damage = 96;
Item.shootSpeed = 8f;
Item.shoot = ModContent.ProjectileType<BurningStrifeProj>();
Item.DamageType = RogueDamageClass.Instance;
}
// Terraria seems to really dislike high crit values in SetDefaults
public override void ModifyWeaponCrit(Player player, ref float crit) => crit += 8;
public override float StealthDamageMultiplier => 1.3f;
public override float StealthVelocityMultiplier => 1.25f;
public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback)
{
int proj = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI);
if (player.Calamity().StealthStrikeAvailable() && proj.WithinBounds(Main.maxProjectiles))
{
Main.projectile[proj].Calamity().stealthStrike = true;
Main.projectile[proj].penetrate = 5;
}
return false;
}
}
}