2 - Mantis Claws now inflict Hellfire. 3 - Vulcanite Lance now inflicts Hellfire instead of On Fire! 4 - Fault Line now inflicts Hellfire instead of On Fire! 5 - Blood Bath now inflicts Burning Blood. 6 - Shaderain Staff no longer inflicts any debuffs. 7 - Icicle Trident no longer inflicts Glacial State. 8 - Infernal Rift now inflicts Hellfire instead of Brimstone Flames. 9 - Vesuvius no longer buffs the player with Molten and now inflicts Hellfire. 10 - Deathhail Staff now inflicts God Slayer Inferno instead of On Fire! and Frostburn. 11 - Divine Retribution no longer inflicts Crush Depth. 12 - Elemental Ray no longer inflicts any debuffs. 13 - Helium Flash no longer inflicts Irradiated. 14 - Ice Barrage no longer inflicts Exo Freeze. 15 - Sanguine Flare no longer inflicts any debuffs. 16 - Soul Piercer now inflicts God Slayer Inferno. 17 - Staff of Blushie now only inflicts Daybroken. 18 - Ultra Liquidator no longer inflicts any debuffs and no longer requires Ichor/Cursed Flames to craft. 19 - Venusian Trident now inflicts Daybroken instead of On Fire! 20 - The Wand now only inflicts Dragonfire. 21 - Gatling Laser no longer inflicts any debuffs. 22 - Ion Blaster no longer inflicts any debuffs. 23 - Lazhar now inflicts Daybroken instead of On Fire! 24 - Aetherflux Cannon now inflicts Holy Flames. 25 - Apoctosis Array no longer inflicts any debuffs. 26 - Plasma Caster no longer inflicts any debuffs. 27 - Purge Guzzler no longer inflicts On Fire! 28 - Death Valley Duster now inflicts Armor Crunch. 29 - Forbidden Sun now inflicts Hellfire instead of On Fire! 30 - Frigidflash Bolt now inflicts Hellfire instead of On Fire! 31 - Poseidon now inflicts Eutrophication. 32 - Primordial Earth now inflicts Armor Crunch. 33 - Seething Discharge now inflicts Brimstone Flames. 34 - Tome of Fates no longer inflicts Brimstone Flames. 35 - Apotheosis no longer inflicts Armor Crunch, Demon Flames and Exo Freeze, but now inflicts Whispering Death. 36 - Augur of the Elements no longer inflicts any debuffs. 37 - Event Horizon no longer inflicts any debuffs. 38 - Nuclear Fury no longer inflicts any debuffs. 39 - Primordial Ancient now inflicts Armor Crunch. 40 - Recitation of the Beast no longer inflicts any debuffs. 41 - Arctic Bear Paw no longer inflicts Confused. 42 - Mad Alchemist's Cocktail Glove no longer inflicts Poisoned, On Fire!, Cursed Inferno, Shadowflame and Frostburn, but now inflicts Electrified and the debuff durations have been doubled. 43 - Yharim's Crystal now inflicts Dragonfire.
97 lines
3.5 KiB
C#
97 lines
3.5 KiB
C#
using CalamityMod.Buffs.DamageOverTime;
|
|
using Microsoft.Xna.Framework;
|
|
using System;
|
|
using Terraria;
|
|
using Terraria.ID;
|
|
using Terraria.ModLoader;
|
|
namespace CalamityMod.Projectiles.Magic
|
|
{
|
|
public class ElementTentacle : ModProjectile
|
|
{
|
|
public override string Texture => "CalamityMod/Projectiles/InvisibleProj";
|
|
|
|
public override void SetStaticDefaults()
|
|
{
|
|
DisplayName.SetDefault("Tentacle");
|
|
}
|
|
|
|
public override void SetDefaults()
|
|
{
|
|
Projectile.width = 40;
|
|
Projectile.height = 40;
|
|
Projectile.friendly = true;
|
|
Projectile.penetrate = 1;
|
|
Projectile.MaxUpdates = 3;
|
|
Projectile.DamageType = DamageClass.Magic;
|
|
Projectile.tileCollide = false;
|
|
}
|
|
|
|
public override void AI()
|
|
{
|
|
if (Projectile.velocity.X != Projectile.velocity.X)
|
|
{
|
|
if (Math.Abs(Projectile.velocity.X) < 1f)
|
|
{
|
|
Projectile.velocity.X = -Projectile.velocity.X;
|
|
}
|
|
else
|
|
{
|
|
Projectile.Kill();
|
|
}
|
|
}
|
|
if (Projectile.velocity.Y != Projectile.velocity.Y)
|
|
{
|
|
if (Math.Abs(Projectile.velocity.Y) < 1f)
|
|
{
|
|
Projectile.velocity.Y = -Projectile.velocity.Y;
|
|
}
|
|
else
|
|
{
|
|
Projectile.Kill();
|
|
}
|
|
}
|
|
Vector2 center10 = Projectile.Center;
|
|
Projectile.scale = 1f - Projectile.localAI[0];
|
|
Projectile.width = (int)(20f * Projectile.scale);
|
|
Projectile.height = Projectile.width;
|
|
Projectile.position.X = center10.X - (float)(Projectile.width / 2);
|
|
Projectile.position.Y = center10.Y - (float)(Projectile.height / 2);
|
|
if ((double)Projectile.localAI[0] < 0.1)
|
|
{
|
|
Projectile.localAI[0] += 0.01f;
|
|
}
|
|
else
|
|
{
|
|
Projectile.localAI[0] += 0.025f;
|
|
}
|
|
if (Projectile.localAI[0] >= 0.95f)
|
|
{
|
|
Projectile.Kill();
|
|
}
|
|
Projectile.velocity.X = Projectile.velocity.X + Projectile.ai[0] * 2f;
|
|
Projectile.velocity.Y = Projectile.velocity.Y + Projectile.ai[1] * 2f;
|
|
if (Projectile.velocity.Length() > 16f)
|
|
{
|
|
Projectile.velocity.Normalize();
|
|
Projectile.velocity *= 16f;
|
|
}
|
|
Projectile.ai[0] *= 1.05f;
|
|
Projectile.ai[1] *= 1.05f;
|
|
if (Projectile.scale < 1f)
|
|
{
|
|
int num897 = 0;
|
|
while ((float)num897 < Projectile.scale * 10f)
|
|
{
|
|
int num898 = Dust.NewDust(new Vector2(Projectile.position.X, Projectile.position.Y), Projectile.width, Projectile.height, 66, Projectile.velocity.X, Projectile.velocity.Y, 100, new Color(Main.DiscoR, Main.DiscoG, Main.DiscoB), 1.1f);
|
|
Main.dust[num898].position = (Main.dust[num898].position + Projectile.Center) / 2f;
|
|
Main.dust[num898].noGravity = true;
|
|
Main.dust[num898].velocity *= 0.1f;
|
|
Main.dust[num898].velocity -= Projectile.velocity * (1.3f - Projectile.scale);
|
|
Main.dust[num898].scale += Projectile.scale * 0.75f;
|
|
num897++;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|