This commit is contained in:
mountaindrew10 committed 2023-02-01 08:55:39 -06:00
commit 2e62796e60
16 files changed
+123 -27

No files matched your search

+5 -3
View File
@@ -997,7 +997,6 @@ namespace CalamityMod.CalPlayer
{
Main.projectile[projectileIndex].DamageType = DamageClass.Generic;
Main.projectile[projectileIndex].netUpdate = true;
Main.projectile[projectileIndex].localNPCHitCooldown = 10;
}
}
@@ -1192,7 +1191,7 @@ namespace CalamityMod.CalPlayer
{
Vector2 velocity = CalamityUtils.RandomVelocity(50f, 30f, 60f);
int damage = (int)Player.GetTotalDamage<RogueDamageClass>().ApplyTo(10);
int spark = Projectile.NewProjectile(spawnSource, position, velocity, ProjectileType<Spark>(), damage, 0f, Player.whoAmI);
int spark = Projectile.NewProjectile(spawnSource, position, velocity, ProjectileType<EGloveSpark>(), damage, 0f, Player.whoAmI);
if (spark.WithinBounds(Main.maxProjectiles))
{
Main.projectile[spark].DamageType = DamageClass.Generic;
@@ -1537,7 +1536,7 @@ namespace CalamityMod.CalPlayer
Main.player[Main.myPlayer].lifeSteal -= cooldown;
}
if (vampiricTalisman && proj.CountsAsClass<ThrowingDamageClass>() && crit)
if (vampiricTalisman && proj.CountsAsClass<RogueDamageClass>() && crit)
{
float heal = MathHelper.Clamp(damage * 0.011f, 0f, 5f);
if ((int)heal > 0)
@@ -1550,8 +1549,11 @@ namespace CalamityMod.CalPlayer
if (bloodyGlove && proj.CountsAsClass<RogueDamageClass>() && modProj.stealthStrike)
{
float cooldown = 0;
cooldown += 20;
Player.statLife += 2;
Player.HealEffect(2);
Main.player[Main.myPlayer].lifeSteal -= cooldown;
}
if ((target.damage > 5 || target.boss) && !target.SpawnedFromStatue)
+1 -1
View File
@@ -16,7 +16,7 @@ Here, I disposed of the burgeoning remains of Silva, the Goddess of Life itself.
My wishes were that she would be forgotten, but her tenacity is remarkable.
Diffused, her influence inundated that pit of crushing pressure with flora and fauna aplenty.
Her great roots continue to thrash and tear at the impossibly dense stone, growing uncontrollably.
She will soon remake it in her image. I can think of no worse fate for this accursed, benthic domain.";
She will soon remake it in her image. I can think of no worse fate for this accursed, hadal domain.";
public override void SetStaticDefaults()
{
+1 -1
View File
@@ -11,7 +11,7 @@ namespace CalamityMod.Items.LoreItems
public override string Lore =>
@"I had seen this monster roaming the night in the past, and thought nothing of it.
With its technology, it was certainly one of Draedon's creations.
But, to think it was housing a clone of the Witch… Irremissible.
But, to think it was housing a clone of the Witch… Detestable.
Surely Calamitas would want nothing to do with such a project.
I know not how it wields her brimstone magic. Perhaps some day one of us may find answers.";
+1 -1
View File
@@ -16,7 +16,7 @@ I ordered Draedon to armor his gargantuan form, so he could safely best even gre
Fittingly, he had a serpent's tongue. He manipulated me incessantly, driving me to awful acts.
I recruited him out of desperation. My war had dragged on for decades, and I would do anything to have it end.
It was then my negligence was born. My descent began the moment recruiting this scoundrel crossed my mind.
His dearth of loyalty was clear as day, even at the time. However, I suspect it goes beyond that.
His absence of loyalty was clear as day, even at the time. However, I suspect it goes beyond that.
The Devourer's alien capabilities and domineering tactics hint that his allegiance lay elsewhere.
Is he but one soldier, of a malevolence far beyond…?";
+1 -1
View File
@@ -10,7 +10,7 @@ namespace CalamityMod.Items.LoreItems
In broad daylight, she can channel the Primordial Light itself, making her nigh untouchable.
Thankfully, left with only starlight to wield, she falls like any other graceless despot.
Her penchant for leeching the strength of other great beings is uniquely deplorable.
It made her obsequious. Dependent, but willingly so, as they enabled her to slake her base thirst.
It made her sickeningly obedient. Dependent, but willingly so, as they enabled her to slake her base thirst.
I had deigned to slay her myself for her treachery, but she was a notoriously evasive mark.";
public override void SetStaticDefaults()
+1 -1
View File
@@ -8,7 +8,7 @@ namespace CalamityMod.Items.LoreItems
public class LoreQueenBee : LoreItem
{
public override string Lore =>
@"While of tremendous size, these creatures are docile until aggravated. Their idyll is a rarity nowadays, a thing of beauty.
@"While of tremendous size, these creatures are docile until aggravated. Their idyllic demeanor is a rarity nowadays, a thing of beauty.
In the past, entire villages would spring up around these grand hives, peacefully harvesting their share of the honey and protecting them from danger.
Though its death is understandable given the circumstances, I do feel pity for these majestic beings.
Fate was cruel to many of their kind.";
Binary file not shown.

Before

Width:  |  Height:  |  Size: 357 B

After

Width:  |  Height:  |  Size: 331 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 529 B

After

Width:  |  Height:  |  Size: 362 B

+2 -1
View File
@@ -24,7 +24,8 @@ namespace CalamityMod.Items.Weapons.Rogue
Item.width = Item.height = 120;
Item.damage = 616;
Item.knockBack = 8.5f;
Item.useAnimation = Item.useTime = 17;
Item.useAnimation = 16; //Has to be different than UseTime to prevent clockwork
Item.useTime = 17;
Item.DamageType = RogueDamageClass.Instance;
Item.autoReuse = true;
Item.shootSpeed = 18f;
+1 -1
View File
@@ -25,7 +25,7 @@ namespace CalamityMod.Items.Weapons.Rogue
Item.damage = 150;
Item.noMelee = true;
Item.noUseGraphic = true;
Item.useAnimation = 38;
Item.useAnimation = 37; //Has to be different than UseTime to prevent clockwork
Item.useStyle = ItemUseStyleID.Swing;
Item.useTime = 38;
Item.knockBack = 10f;
+4 -4
View File
@@ -21,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Rogue
DisplayName.SetDefault("Stormfront Razor");
Tooltip.SetDefault("Throws a knife that summons lightning on hit.\n" +
"Stealth strikes cause the knife to be faster and summon multiple lightning bolts on hit\n" +
"[c/24c7f0:Quite shocking]");
"[c/24c7f0:Strike and stem the flow]");
Main.RegisterItemAnimation(Item.type, new DrawAnimationVertical(6, 4));
ItemID.Sets.AnimatesAsSoul[Type] = true;
SacrificeTotal = 1;
@@ -40,17 +40,17 @@ namespace CalamityMod.Items.Weapons.Rogue
Item.rare = ItemRarityID.Pink;
Item.useAnimation = 20;
Item.useTime = 20;
Item.damage = 43;
Item.damage = 38;
Item.knockBack = 7f;
Item.shoot = ModContent.ProjectileType<StormfrontRazorProjectile>();
Item.shootSpeed = 8f;
Item.shootSpeed = 8.2f;
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 => 1f;
public override float StealthDamageMultiplier => 1.2f;
public override float StealthVelocityMultiplier => 1.5f;
public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback)
@@ -15,7 +15,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal
get => Projectile.ai[0];
set => Projectile.ai[0] = value;
}
public const int Lifetime = 360;
public const int Lifetime = 240;
public override void SetStaticDefaults()
{
DisplayName.SetDefault("Pulse Energy");
@@ -29,10 +29,12 @@ namespace CalamityMod.Projectiles.DraedonsArsenal
Projectile.friendly = true;
Projectile.ignoreWater = true;
Projectile.timeLeft = 180;
Projectile.penetrate = 4;
Projectile.penetrate = 2;
Projectile.extraUpdates = 1;
Projectile.DamageType = RogueDamageClass.Instance;
Projectile.tileCollide = false;
Projectile.usesIDStaticNPCImmunity = true;
Projectile.idStaticNPCHitCooldown = 45;
}
public override void AI()
@@ -88,7 +90,7 @@ namespace CalamityMod.Projectiles.DraedonsArsenal
if (Main.myPlayer != Projectile.owner)
return;
// Explode if the projectile is a stealth strike projectile.
int totalEnergyParticlesToSpawn = 4;
int totalEnergyParticlesToSpawn = 3;
if (Projectile.Calamity().stealthStrike)
{
SoundEngine.PlaySound(SoundID.Item14, Projectile.Center);
+90
View File
@@ -0,0 +1,90 @@
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ModLoader;
namespace CalamityMod.Projectiles.Rogue
{
public class EGloveSpark : ModProjectile
{
public override string Texture => "CalamityMod/Projectiles/InvisibleProj";
public override void SetStaticDefaults()
{
DisplayName.SetDefault("Spark");
}
public override void SetDefaults()
{
Projectile.width = 6;
Projectile.height = 12;
Projectile.friendly = true;
Projectile.penetrate = -1;
Projectile.timeLeft = 60;
Projectile.usesIDStaticNPCImmunity = true;
Projectile.idStaticNPCHitCooldown = 20;
Projectile.DamageType = DamageClass.Generic; //No triggering nanoblades
}
public override void AI()
{
if (Projectile.velocity.X != Projectile.velocity.X)
{
Projectile.velocity.X = Projectile.velocity.X * -0.05f;
}
if (Projectile.velocity.X != Projectile.velocity.X)
{
Projectile.velocity.X = Projectile.velocity.X * -0.3f;
}
if (Projectile.velocity.Y != Projectile.velocity.Y && Projectile.velocity.Y > 0.5f)
{
Projectile.velocity.Y = Projectile.velocity.Y * -0.3f;
}
Projectile.ai[0] += 1f;
if (Projectile.ai[0] > 5f)
{
Projectile.ai[0] = 5f;
if (Projectile.velocity.Y == 0f && Projectile.velocity.X != 0f)
{
Projectile.velocity.X = Projectile.velocity.X * 0.97f;
if ((double)Projectile.velocity.X > -0.01 && (double)Projectile.velocity.X < 0.01)
{
Projectile.velocity.X = 0f;
Projectile.netUpdate = true;
}
}
Projectile.velocity.Y = Projectile.velocity.Y + 0.2f;
}
Projectile.rotation += Projectile.velocity.X * 0.1f;
int num199 = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 206, 0f, 0f, 100, new Color(Main.rand.Next(20, 100), 204, 250), 1f);
Dust expr_8976_cp_0 = Main.dust[num199];
expr_8976_cp_0.position.X -= 2f;
Dust expr_8994_cp_0 = Main.dust[num199];
expr_8994_cp_0.position.Y += 2f;
Main.dust[num199].scale += (float)Main.rand.Next(50) * 0.01f;
Main.dust[num199].noGravity = true;
Dust expr_89E7_cp_0 = Main.dust[num199];
expr_89E7_cp_0.velocity.Y -= 2f;
if (Main.rand.NextBool(2))
{
int num200 = Dust.NewDust(Projectile.position, Projectile.width, Projectile.height, 206, 0f, 0f, 100, new Color(Main.rand.Next(20, 100), 204, 250), 1f);
Dust expr_8A4E_cp_0 = Main.dust[num200];
expr_8A4E_cp_0.position.X -= 2f;
Dust expr_8A6C_cp_0 = Main.dust[num200];
expr_8A6C_cp_0.position.Y += 2f;
Main.dust[num200].scale += 0.3f + (float)Main.rand.Next(50) * 0.01f;
Main.dust[num200].noGravity = true;
Main.dust[num200].velocity *= 0.1f;
}
if ((double)Projectile.velocity.Y < 0.25 && (double)Projectile.velocity.Y > 0.15)
{
Projectile.velocity.X = Projectile.velocity.X * 0.8f;
}
Projectile.rotation = -Projectile.velocity.X * 0.05f;
if (Projectile.velocity.Y > 16f)
{
Projectile.velocity.Y = 16f;
}
}
public override bool OnTileCollide(Vector2 oldVelocity) => false;
}
}
+5 -5
View File
@@ -45,10 +45,10 @@ namespace CalamityMod.Projectiles.Rogue
public override void SetDefaults()
{
Projectile.width = 25;
Projectile.height = 25;
Projectile.width = 35;
Projectile.height = 35;
Projectile.alpha = 255;
Projectile.penetrate =3;
Projectile.penetrate =4;
Projectile.ignoreWater = true;
Projectile.tileCollide = false;
Projectile.friendly = true;
@@ -166,14 +166,14 @@ namespace CalamityMod.Projectiles.Rogue
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
{
SoundEngine.PlaySound(SoundID.Item93, Projectile.position);
target.AddBuff(BuffID.Electrified, 120);
target.AddBuff(BuffID.Electrified, 150);
Sparks();
}
public override void OnHitPvp(Player target, int damage, bool crit)
{
SoundEngine.PlaySound(SoundID.Item93, Projectile.position);
target.AddBuff(BuffID.Electrified, 120);
target.AddBuff(BuffID.Electrified, 150);
Sparks();
}
@@ -79,8 +79,8 @@ namespace CalamityMod.Projectiles.Rogue
for (int i = 0; i < times; i++)
{
int lightningDamage = (int)(Projectile.damage * StormfrontRazor.LightningDamageFactor);
Vector2 lightningSpawnPosition = Projectile.Center - Vector2.UnitY.RotatedByRandom(0.2f) * 1100f;
Vector2 lightningShootVelocity = (target.Center - lightningSpawnPosition + target.velocity * 7.5f).SafeNormalize(Vector2.UnitY) * 14f;
Vector2 lightningSpawnPosition = Projectile.Center - Vector2.UnitY.RotatedByRandom(0.2f) * 1000f;
Vector2 lightningShootVelocity = (target.Center - lightningSpawnPosition + target.velocity * 7.5f).SafeNormalize(Vector2.UnitY) * 15f;
int lightning = Projectile.NewProjectile(Projectile.GetSource_FromThis(), lightningSpawnPosition, lightningShootVelocity, ModContent.ProjectileType<StormfrontLightning>(), lightningDamage, 0f, Projectile.owner);
if (Main.projectile.IndexInRange(lightning))
{
@@ -97,7 +97,7 @@ namespace CalamityMod.Projectiles.Rogue
target.AddBuff(BuffID.Electrified, 45);
if (Main.rand.NextBool(10))
{
int d = Dust.NewDust(Projectile.Center, Projectile.width, Projectile.height, 226, 0f, 0f, 100, new Color(Main.rand.Next(20,100), 204, 250), 1f);
int d = Dust.NewDust(Projectile.Center, Projectile.width, Projectile.height, 226, 0f, 0f, 100, new Color(Main.rand.Next(20, 100), 204, 250), 1f);
Main.dust[d].scale += (float)Main.rand.Next(50) * 0.01f;
Main.dust[d].noGravity = true;
Main.dust[d].position = Projectile.Center;
@@ -111,14 +111,15 @@ namespace CalamityMod.Projectiles.Rogue
for (int i = 0; i < times; i++)
{
int lightningDamage = (int)(Projectile.damage * StormfrontRazor.LightningDamageFactor);
Vector2 lightningSpawnPosition = Projectile.Center - Vector2.UnitY.RotatedByRandom(0.2f) * 1100f;
Vector2 lightningShootVelocity = (target.Center - lightningSpawnPosition + target.velocity * 7.5f).SafeNormalize(Vector2.UnitY) * 14f;
Vector2 lightningSpawnPosition = Projectile.Center - Vector2.UnitY.RotatedByRandom(0.2f) * 1000f;
Vector2 lightningShootVelocity = (target.Center - lightningSpawnPosition + target.velocity * 7.5f).SafeNormalize(Vector2.UnitY) * 15f;
int lightning = Projectile.NewProjectile(Projectile.GetSource_FromThis(), lightningSpawnPosition, lightningShootVelocity, ModContent.ProjectileType<StormfrontLightning>(), lightningDamage, 0f, Projectile.owner);
if (Main.projectile.IndexInRange(lightning))
{
Main.projectile[lightning].CritChance = Projectile.CritChance;
Main.projectile[lightning].ai[0] = lightningShootVelocity.ToRotation();
Main.projectile[lightning].ai[1] = Main.rand.Next(100);
//I'll probably need some delay here
}
}
}