Files
CalamityModPublic/Items/Weapons/Rogue/Supernova.cs
T
Altixal 8cc0d88cf6 sounds and ounds
fully integrated the gfb bool
gfb polter gets a bit spookier (wip)
resprited armor crunch, cal eye banner
added sounds:
- astrum deus shoot sounds
- final dawn use sound
- supernova explosion sound
- plasma rifle use sounds
- aew charge and death sounds
2023-07-12 23:54:33 +07:00

65 lines
2.3 KiB
C#

using CalamityMod.Items.Materials;
using CalamityMod.Items.Weapons.Summon;
using CalamityMod.Projectiles.Rogue;
using CalamityMod.Rarities;
using CalamityMod.Tiles.Furniture.CraftingStations;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.Audio;
using Terraria.DataStructures;
using Terraria.ID;
using Terraria.ModLoader;
namespace CalamityMod.Items.Weapons.Rogue
{
public class Supernova : RogueWeapon
{
public static readonly SoundStyle ExplosionSound = new("CalamityMod/Sounds/Item/SupernovaBoom") { Volume = 0.8f };
public override void SetDefaults()
{
Item.width = 34;
Item.damage = 675;
Item.noMelee = true;
Item.noUseGraphic = true;
Item.useAnimation = 24;
Item.useStyle = ItemUseStyleID.Swing;
Item.useTime = 24;
Item.knockBack = 8f;
Item.UseSound = SoundID.Item15;
Item.autoReuse = true;
Item.height = 36;
Item.value = CalamityGlobalItem.Rarity15BuyPrice;
Item.shoot = ModContent.ProjectileType<SupernovaBomb>();
Item.shootSpeed = 16f;
Item.DamageType = RogueDamageClass.Instance;
Item.rare = ModContent.RarityType<Violet>();
}
public override float StealthDamageMultiplier => 1.08f;
public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback)
{
if (player.Calamity().StealthStrikeAvailable()) //setting the stealth strike
{
int stealth = Projectile.NewProjectile(source, position, velocity, type, damage, knockback, player.whoAmI);
if (stealth.WithinBounds(Main.maxProjectiles))
Main.projectile[stealth].Calamity().stealthStrike = true;
return false;
}
return true;
}
public override void AddRecipes()
{
CreateRecipe().
AddIngredient<SealedSingularity>().
AddIngredient<StarofDestruction>().
AddIngredient<TotalityBreakers>().
AddIngredient<BallisticPoisonBomb>().
AddIngredient<MiracleMatter>().
AddTile<DraedonsForge>().
Register();
}
}
}