2 - Amalgam now inflicts Acid Venom instead of Brimstone Flames and Plague and Astral Infection instead of God Slayer Inferno. 3 - Elemental Gauntlet now only inflicts Hellfire. 4 - Frosty Flare now inflicts Frostburn on all hits instead of just melee. 5 - Corrosive Spine now inflicts Acid Venom instead of Poisoned. 6 - Void of Extinction now inflicts Brimstone Flames on all hits instead of Hellfire on melee hits. 7 - Necklace of Vexation now inflicts Acid Venom instead of Cursed Inferno and Venom while wearing Reaver Armor. 8 - The Camper no longer inflicts On Fire! 9 - Increased Alicorn mount run speed to 90 mph, gave it infinite flight and increased vertical speed to 70 mph. 10 - Increased Gaze of Crysthamyr mount horizontal flight acceleration by 70%, decreased run speed to 50 mph and made holding W while flying up greatly boost vertical acceleration. 11 - Gaze of Crysthamyr now requires 10 Souls of Night to craft instead of 100. 12 - Dragon Scales infernadoes and fireballs now inflict Dragonfire. 13 - Abyssal Mirror projectiles now inflict Crush Depth. 14 - Statis Void Sash projectiles no longer inflict God Slayer Inferno. 15 - Venerated Locket projectiles now inflict God Slayer Inferno. 16 - Hallowed Rune projectiles no longer inflict Astral Infection. 17 - Nebulous Core projectiles now inflict God Slayer Inferno.
77 lines
2.4 KiB
C#
77 lines
2.4 KiB
C#
using CalamityMod.Buffs.DamageOverTime;
|
|
using Microsoft.Xna.Framework;
|
|
using System;
|
|
using Terraria;
|
|
using Terraria.ID;
|
|
using Terraria.ModLoader;
|
|
|
|
namespace CalamityMod.Projectiles.Typeless
|
|
{
|
|
public class NebulaDust : ModProjectile
|
|
{
|
|
public override void SetStaticDefaults()
|
|
{
|
|
DisplayName.SetDefault("Dust");
|
|
}
|
|
|
|
public override void SetDefaults()
|
|
{
|
|
Projectile.width = 32;
|
|
Projectile.height = 32;
|
|
Projectile.friendly = true;
|
|
Projectile.Opacity = 0f;
|
|
Projectile.penetrate = -1;
|
|
Projectile.tileCollide = false;
|
|
Projectile.ignoreWater = true;
|
|
Projectile.timeLeft = 3600;
|
|
Projectile.usesLocalNPCImmunity = true;
|
|
Projectile.localNPCHitCooldown = 3;
|
|
}
|
|
|
|
public override void AI()
|
|
{
|
|
Projectile.rotation += Projectile.velocity.X * 0.02f;
|
|
|
|
if (Projectile.velocity.X < 0f)
|
|
Projectile.rotation -= Math.Abs(Projectile.velocity.Y) * 0.02f;
|
|
else
|
|
Projectile.rotation += Math.Abs(Projectile.velocity.Y) * 0.02f;
|
|
|
|
Projectile.velocity *= 0.98f;
|
|
|
|
Projectile.ai[0] += 1f;
|
|
if (Projectile.ai[0] >= 60f)
|
|
{
|
|
if (Projectile.Opacity > 0f)
|
|
{
|
|
Projectile.Opacity -= 0.02f;
|
|
if (Projectile.Opacity < 0f)
|
|
Projectile.Opacity = 0f;
|
|
}
|
|
else if (Projectile.owner == Main.myPlayer)
|
|
Projectile.Kill();
|
|
}
|
|
else if (Projectile.Opacity < 0.7f)
|
|
{
|
|
Projectile.Opacity += 0.1f;
|
|
if (Projectile.Opacity > 0.7f)
|
|
Projectile.Opacity = 0.7f;
|
|
}
|
|
}
|
|
|
|
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
|
{
|
|
target.AddBuff(ModContent.BuffType<GodSlayerInferno>(), 90);
|
|
}
|
|
|
|
public override bool PreDraw(ref Color lightColor)
|
|
{
|
|
lightColor.R = (byte)(255 * Projectile.Opacity);
|
|
lightColor.G = (byte)(255 * Projectile.Opacity);
|
|
lightColor.B = (byte)(255 * Projectile.Opacity);
|
|
CalamityUtils.DrawAfterimagesCentered(Projectile, ProjectileID.Sets.TrailingMode[Projectile.type], lightColor, 1);
|
|
return false;
|
|
}
|
|
}
|
|
}
|