Merge branch '1.4' of https://github.com/CalamityTeam/CalamityMod into 1.4
This commit is contained in:
commit
d7bbca0f39
533 files changed
+1432
-4260
No files matched your search
@@ -20,7 +20,7 @@ namespace CalamityMod.Buffs
|
||||
}
|
||||
else if (type == BuffID.MagicPower)
|
||||
{
|
||||
player.GetDamage(DamageClass.Magic) -= 0.1f;
|
||||
player.GetDamage<MagicDamageClass>() -= 0.1f;
|
||||
}
|
||||
else if (type == BuffID.Panic)
|
||||
{
|
||||
@@ -57,7 +57,7 @@ namespace CalamityMod.Buffs
|
||||
else if (type >= BuffID.NebulaUpDmg1 && type <= BuffID.NebulaUpDmg3)
|
||||
{
|
||||
float nebulaDamage = 0.075f * player.nebulaLevelDamage; // 15% to 45% changed to 7.5% to 22.5%
|
||||
player.GetDamage(DamageClass.Generic) -= nebulaDamage;
|
||||
player.GetDamage<GenericDamageClass>() -= nebulaDamage;
|
||||
}
|
||||
else if (type == BuffID.Warmth)
|
||||
{
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace CalamityMod.Buffs.DamageOverTime
|
||||
// Only deal damage once every several frames.
|
||||
if (applicator.miscCounter % FramesPerDamageTick == 0)
|
||||
{
|
||||
int dmg = (int)(BaseDamage * cgn.somaShredStacks * applicator.GetDamage(DamageClass.Ranged).Base);
|
||||
int dmg = (int)(BaseDamage * cgn.somaShredStacks * applicator.GetDamage<RangedDamageClass>().Base);
|
||||
Projectile tick = Projectile.NewProjectileDirect(target.GetSource_FromThis(), target.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), dmg, 0f, applicator.whoAmI, target.whoAmI);
|
||||
tick.DamageType = DamageClass.Ranged; // Uncommon for DirectStrikes, but it needs to be able to crit.
|
||||
tick.Calamity().canSupercrit = true;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Buffs.StatBuffs
|
||||
public override void Update(Player player, ref int buffIndex)
|
||||
{
|
||||
player.Calamity().hallowedPower = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
using Terraria;
|
||||
using Terraria;
|
||||
using Terraria.Audio;
|
||||
using Terraria.ModLoader;
|
||||
using CalamityMod.Items.Weapons.Typeless;
|
||||
|
||||
namespace CalamityMod.Buffs.StatBuffs
|
||||
{
|
||||
@@ -21,7 +22,7 @@ namespace CalamityMod.Buffs.StatBuffs
|
||||
{
|
||||
player.Calamity().kamiBoost = true;
|
||||
if (player.buffTime[buffIndex] == 1)
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/YanmeiKnifeExpire"), player.Center);
|
||||
SoundEngine.PlaySound(YanmeisKnife.ExpireSound, player.Center);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Buffs.StatBuffs
|
||||
|
||||
public override void Update(Player player, ref int buffIndex)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
using CalamityMod.CalPlayer;
|
||||
using CalamityMod.CalPlayer;
|
||||
using Terraria;
|
||||
using Terraria.Audio;
|
||||
using Terraria.ID;
|
||||
@@ -33,7 +33,7 @@ namespace CalamityMod.Buffs.StatBuffs
|
||||
// Otherwise, Rage Mode ends instantly.
|
||||
else
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/RageEnd"), player.position);
|
||||
SoundEngine.PlaySound(CalamityPlayer.RageEndSound, player.position);
|
||||
player.DelBuff(buffIndex--); // TML documentation requires you to decrement buffIndex if deleting the buff during Update.
|
||||
mp.rageModeActive = false;
|
||||
mp.rage = 0f;
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Buffs.StatBuffs
|
||||
|
||||
public override void Update(Player player, ref int buffIndex)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Buffs.Summon
|
||||
{
|
||||
CalamityPlayer mp = player.Calamity();
|
||||
int count = player.ownedProjectileCounts[ModContent.ProjectileType<VoidConcentrationAura>()];
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f; //5%
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f; //5%
|
||||
mp.voidConcentrationAura = true;
|
||||
if (!mp.voidAuraDamage && count == 0)
|
||||
{
|
||||
|
||||
+166
-161
@@ -231,6 +231,17 @@ namespace CalamityMod.CalPlayer
|
||||
public bool playRogueStealthSound = false;
|
||||
public bool playFullRageSound = true;
|
||||
public bool playFullAdrenalineSound = true;
|
||||
|
||||
public static readonly SoundStyle RageFilledSound = new("CalamityMod/Sounds/Custom/AbilitySounds/FullRage");
|
||||
public static readonly SoundStyle RageActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/RageActivate");
|
||||
public static readonly SoundStyle RageEndSound = new("CalamityMod/Sounds/Custom/AbilitySounds/RageEnd");
|
||||
|
||||
public static readonly SoundStyle AdrenalineFilledSound = new("CalamityMod/Sounds/Custom/AbilitySounds/FullAdrenaline");
|
||||
public static readonly SoundStyle AdrenalineActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/AdrenalineActivate");
|
||||
|
||||
public static readonly SoundStyle RogueStealthSound = new("CalamityMod/Sounds/Custom/RogueStealth");
|
||||
public static readonly SoundStyle DefenseDamageSound = new("CalamityMod/Sounds/Custom/DefenseDamage");
|
||||
|
||||
#endregion
|
||||
|
||||
#region Proficiency
|
||||
@@ -2603,7 +2614,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
int seconds = CalamityUtils.SecondsToFrames(15f);
|
||||
Player.AddBuff(ModContent.BuffType<Buffs.StatBuffs.DivineBless>(), seconds, false);
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/AngelicAllianceActivation"), Player.Center);
|
||||
SoundEngine.PlaySound(AngelicAlliance.ActivationSound, Player.Center);
|
||||
|
||||
// Spawn an archangel for every minion you have
|
||||
float angelAmt = 0f;
|
||||
@@ -2636,7 +2647,7 @@ namespace CalamityMod.CalPlayer
|
||||
var source = Player.GetSource_Accessory(FindAccessory(ModContent.ItemType<Items.Accessories.SandCloak>()));
|
||||
rogueStealth -= rogueStealthMax * 0.25f;
|
||||
Projectile.NewProjectile(source, Player.Center, Vector2.Zero, ModContent.ProjectileType<SandCloakVeil>(), 7, 8, Player.whoAmI);
|
||||
SoundEngine.PlaySound(SoundID.Item, Player.position, 45);
|
||||
SoundEngine.PlaySound(SoundID.Item45, Player.position);
|
||||
}
|
||||
if (CalamityKeybinds.SpectralVeilHotKey.JustPressed && spectralVeil && Main.myPlayer == Player.whoAmI && rogueStealth >= rogueStealthMax * 0.25f &&
|
||||
wearingRogueArmor && rogueStealthMax > 0)
|
||||
@@ -2711,7 +2722,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
brimflameFrenzy = true;
|
||||
Player.AddBuff(ModContent.BuffType<BrimflameFrenzyBuff>(), 10 * 60, true);
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/AbilitySounds/BrimflameAbility"), Player.Center);
|
||||
SoundEngine.PlaySound(BrimflameScowl.ActivationSound, Player.Center);
|
||||
for (int num502 = 0; num502 < 36; num502++)
|
||||
{
|
||||
int dust = Dust.NewDust(new Vector2(Player.position.X, Player.position.Y + 16f), Player.width, Player.height - 16, (int)CalamityDusts.Brimstone, 0f, 0f, 0, default, 1f);
|
||||
@@ -2744,7 +2755,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.whoAmI == Main.myPlayer)
|
||||
Player.AddCooldown(BloodflareRangedSet.ID, 1800);
|
||||
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/BloodflareRangerActivation"), Player.Center);
|
||||
SoundEngine.PlaySound(BloodflareHornedHelm.ActivationSound, Player.Center);
|
||||
for (int d = 0; d < 64; d++)
|
||||
{
|
||||
int dust = Dust.NewDust(new Vector2(Player.position.X, Player.position.Y + 16f), Player.width, Player.height - 16, (int)CalamityDusts.Phantoplasm, 0f, 0f, 0, default, 1f);
|
||||
@@ -2793,7 +2804,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.AddBuff(ModContent.BuffType<AbyssalMadness>(), 300, false);
|
||||
}
|
||||
Player.AddCooldown(OmegaBlue.ID, 1800);
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/OmegaBlueAbility"), Player.Center);
|
||||
SoundEngine.PlaySound(OmegaBlueHelmet.ActivationSound, Player.Center);
|
||||
for (int i = 0; i < 66; i++)
|
||||
{
|
||||
int d = Dust.NewDust(Player.position, Player.width, Player.height, 20, 0, 0, 100, Color.Transparent, 2.6f);
|
||||
@@ -2805,7 +2816,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
if (dsSetBonus)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/DemonshadeEnrage"), Player.Center);
|
||||
SoundEngine.PlaySound(DemonshadeHelm.ActivationSound, Player.Center);
|
||||
for (int num502 = 0; num502 < 36; num502++)
|
||||
{
|
||||
int dust = Dust.NewDust(new Vector2(Player.position.X, Player.position.Y + 16f), Player.width, Player.height - 16, (int)CalamityDusts.Brimstone, 0f, 0f, 0, default, 1f);
|
||||
@@ -2841,7 +2852,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
if (plagueReaper && !Player.HasCooldown(PlagueBlackout.ID))
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/PlagueReaperAbility"), Player.Center);
|
||||
SoundEngine.PlaySound(PlagueReaperMask.ActivationSound, Player.Center);
|
||||
Player.AddCooldown(PlagueBlackout.ID, 1800);
|
||||
}
|
||||
if (forbiddenCirclet && forbiddenCooldown <= 0)
|
||||
@@ -2890,7 +2901,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Main.netMode == NetmodeID.SinglePlayer)
|
||||
{
|
||||
Player.TeleportationPotion();
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 6);
|
||||
SoundEngine.PlaySound(SoundID.Item6, Player.position);
|
||||
}
|
||||
else if (Main.netMode == NetmodeID.MultiplayerClient && Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
@@ -2921,7 +2932,7 @@ namespace CalamityMod.CalPlayer
|
||||
// Gael's Greatsword replaces Rage Mode with an uber skull attack
|
||||
if (gaelRageAttackCooldown == 0 && Player.ActiveItem().type == ModContent.ItemType<GaelsGreatsword>() && rage > 0f)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/SilvaDispel"), Player.Center);
|
||||
SoundEngine.PlaySound(SilvaHelmet.DispelSound, Player.Center);
|
||||
|
||||
for (int i = 0; i < 3; i++)
|
||||
Dust.NewDust(Player.position, 120, 120, 218, 0f, 0f, 100, default, 1.5f);
|
||||
@@ -2967,7 +2978,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.AddBuff(ModContent.BuffType<RageMode>(), 2);
|
||||
|
||||
// Play Rage Activation sound
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/RageActivate"), Player.position);
|
||||
SoundEngine.PlaySound( RageActivationSound, Player.position);
|
||||
|
||||
// TODO -- improve Rage activation visuals
|
||||
for (int num502 = 0; num502 < 64; num502++)
|
||||
@@ -2998,7 +3009,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.AddBuff(ModContent.BuffType<AdrenalineMode>(), AdrenalineDuration);
|
||||
|
||||
// Play Adrenaline Activation sound
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/AdrenalineActivate"), Player.position);
|
||||
SoundEngine.PlaySound(AdrenalineActivationSound, Player.position);
|
||||
|
||||
// TODO -- improve Adrenaline activation visuals
|
||||
for (int num502 = 0; num502 < 64; num502++)
|
||||
@@ -3040,7 +3051,7 @@ namespace CalamityMod.CalPlayer
|
||||
int offset = Player.height;
|
||||
if (Player.gravDir == -1f)
|
||||
offset = 0;
|
||||
SoundEngine.PlaySound(SoundID.DoubleJump, (int)Player.position.X, (int)Player.position.Y, 1, 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.DoubleJump, Player.position);
|
||||
Player.velocity.Y = -Player.jumpSpeed * Player.gravDir;
|
||||
Player.jump = (int)(Player.jumpHeight * 1.25);
|
||||
for (int d = 0; d < 30; ++d)
|
||||
@@ -3062,7 +3073,7 @@ namespace CalamityMod.CalPlayer
|
||||
int offset = Player.height;
|
||||
if (Player.gravDir == -1f)
|
||||
offset = 0;
|
||||
SoundEngine.PlaySound(SoundID.DoubleJump, (int)Player.position.X, (int)Player.position.Y, 1, 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.DoubleJump, Player.position);
|
||||
Player.velocity.Y = -Player.jumpSpeed * Player.gravDir;
|
||||
Player.jump = (int)(Player.jumpHeight * 1.5);
|
||||
for (int d = 0; d < 30; ++d)
|
||||
@@ -3261,7 +3272,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
Main.TeleportEffect(player.getRect(), 1);
|
||||
Main.TeleportEffect(player.getRect(), 3);
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)player.position.X, (int)player.position.Y, 6);
|
||||
SoundEngine.PlaySound(SoundID.Item6, player.position);
|
||||
if (Main.netMode != NetmodeID.Server)
|
||||
{
|
||||
return;
|
||||
@@ -3511,25 +3522,25 @@ namespace CalamityMod.CalPlayer
|
||||
if (GemTechState.IsYellowGemActive)
|
||||
meleeSpeedMult += GemTechHeadgear.MeleeSpeedBoost;
|
||||
|
||||
Player.GetAttackSpeed(DamageClass.Melee) += meleeSpeedMult;
|
||||
Player.GetAttackSpeed<MeleeDamageClass>() += meleeSpeedMult;
|
||||
|
||||
// Reduce melee speed bonus by 0.25x for Astral Blade, Mantis Claws, Omniblade and Blade of Enmity.
|
||||
if (Player.ActiveItem().type == ModContent.ItemType<AstralBlade>() || Player.ActiveItem().type == ModContent.ItemType<MantisClaws>() ||
|
||||
Player.ActiveItem().type == ModContent.ItemType<Omniblade>() || Player.ActiveItem().type == ModContent.ItemType<BladeofEnmity>())
|
||||
{
|
||||
float newMeleeSpeed = 1f + ((Player.GetAttackSpeed(DamageClass.Melee) - 1f) * 0.25f);
|
||||
Player.GetAttackSpeed(DamageClass.Melee) = newMeleeSpeed;
|
||||
float newMeleeSpeed = 1f + ((Player.GetAttackSpeed<MeleeDamageClass>() - 1f) * 0.25f);
|
||||
Player.GetAttackSpeed<MeleeDamageClass>() = newMeleeSpeed;
|
||||
}
|
||||
|
||||
// Melee speed does not affect non-true melee weapon projectile rate of fire.
|
||||
if (Player.HoldingProjectileMeleeWeapon())
|
||||
{
|
||||
// Melee weapons that fire any kind of projectile don't benefit from melee speed anymore, so they get a damage boost from it instead.
|
||||
Player.GetDamage(DamageClass.Melee) += Player.GetAttackSpeed(DamageClass.Melee) - 1f;
|
||||
Player.GetDamage<MeleeDamageClass>() += Player.GetAttackSpeed<MeleeDamageClass>() - 1f;
|
||||
|
||||
// Set melee speed to 1f.
|
||||
float newMeleeSpeed = 1f + ((Player.GetAttackSpeed(DamageClass.Melee) - 1f) * projectileMeleeWeaponMeleeSpeedMultiplier);
|
||||
Player.GetAttackSpeed(DamageClass.Melee) = newMeleeSpeed;
|
||||
float newMeleeSpeed = 1f + ((Player.GetAttackSpeed<MeleeDamageClass>() - 1f) * projectileMeleeWeaponMeleeSpeedMultiplier);
|
||||
Player.GetAttackSpeed<MeleeDamageClass>() = newMeleeSpeed;
|
||||
}
|
||||
#endregion
|
||||
|
||||
@@ -3878,7 +3889,7 @@ namespace CalamityMod.CalPlayer
|
||||
Main.dust[sVeilDustIndex2].noLight = false;
|
||||
}
|
||||
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/SilvaDispel"), Player.Center);
|
||||
SoundEngine.PlaySound(SilvaHelmet.DispelSound, Player.Center);
|
||||
|
||||
NetMessage.SendData(MessageID.Dodge, -1, -1, null, Player.whoAmI, 1f, 0f, 0f, 0, 0, 0);
|
||||
}
|
||||
@@ -3886,7 +3897,7 @@ namespace CalamityMod.CalPlayer
|
||||
private void GodSlayerDodge()
|
||||
{
|
||||
Player.GiveIFrames(Player.longInvince ? 100 : 60, true);
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 67);
|
||||
SoundEngine.PlaySound(SoundID.Item67, Player.position);
|
||||
|
||||
for (int j = 0; j < 30; j++)
|
||||
{
|
||||
@@ -3952,7 +3963,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
Player.GiveIFrames(Player.longInvince ? 100 : 60, true);
|
||||
rogueStealth += 0.5f;
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/SilvaActivation"), Player.Center);
|
||||
SoundEngine.PlaySound(SilvaHelmet.ActivationSound, Player.Center);
|
||||
|
||||
var source = Player.GetSource_Accessory(FindAccessory(ModContent.ItemType<EclipseMirror>()));
|
||||
for (int i = 0; i < 10; i++)
|
||||
@@ -4094,7 +4105,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (nCore && !Player.HasCooldown(Cooldowns.NebulousCore.ID))
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 67);
|
||||
SoundEngine.PlaySound(SoundID.Item67, Player.position);
|
||||
|
||||
for (int j = 0; j < 50; j++)
|
||||
{
|
||||
@@ -4131,7 +4142,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (silvaCountdown == silvaReviveDuration && !hasSilvaEffect)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/SilvaActivation"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(SilvaHelmet.ActivationSound, Player.position);
|
||||
|
||||
Player.AddBuff(ModContent.BuffType<SilvaRevival>(), silvaReviveDuration);
|
||||
|
||||
@@ -4612,7 +4623,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
if (item.CountsAsClass<MeleeDamageClass>() && badgeOfBravery)
|
||||
{
|
||||
int penetratableDefense = (int)Math.Max(target.defense - Player.GetArmorPenetration(DamageClass.Generic), 0);
|
||||
int penetratableDefense = (int)Math.Max(target.defense - Player.GetArmorPenetration<GenericDamageClass>(), 0);
|
||||
int penetratedDefense = Math.Min(penetratableDefense, 5);
|
||||
damage += (int)(0.5f * penetratedDefense);
|
||||
}
|
||||
@@ -4757,7 +4768,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
penetrateAmt += 5;
|
||||
}
|
||||
int penetratableDefense = (int)Math.Max(target.defense - Player.GetArmorPenetration(DamageClass.Generic), 0); //if find how much defense we can penetrate
|
||||
int penetratableDefense = (int)Math.Max(target.defense - Player.GetArmorPenetration<GenericDamageClass>(), 0); //if find how much defense we can penetrate
|
||||
int penetratedDefense = Math.Min(penetratableDefense, penetrateAmt); //if we have more penetrate than enemy defense, use enemy defense
|
||||
damage += (int)(0.5f * penetratedDefense);
|
||||
#endregion
|
||||
@@ -5973,31 +5984,25 @@ namespace CalamityMod.CalPlayer
|
||||
if ((profanedCrystal || profanedCrystalForce) && !profanedCrystalHide)
|
||||
{
|
||||
playSound = false;
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/NPCHit/ProvidenceHurt"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(Providence.DeathSound, Player.position);
|
||||
hurtSoundTimer = 20;
|
||||
}
|
||||
else if ((abyssalDivingSuitPower || abyssalDivingSuitForce) && !abyssalDivingSuitHide)
|
||||
{
|
||||
playSound = false;
|
||||
SoundEngine.PlaySound(SoundID.NPCHit, (int)Player.position.X, (int)Player.position.Y, 4, 1f, 0f); //metal hit noise
|
||||
SoundEngine.PlaySound(SoundID.NPCHit4, Player.position); //metal hit noise
|
||||
hurtSoundTimer = 10;
|
||||
}
|
||||
else if ((aquaticHeartPower || aquaticHeartForce) && !aquaticHeartHide)
|
||||
{
|
||||
playSound = false;
|
||||
SoundEngine.PlaySound(SoundID.FemaleHit, (int)Player.position.X, (int)Player.position.Y, 1, 1f, 0f); //female hit noise
|
||||
SoundEngine.PlaySound(SoundID.FemaleHit, Player.position); //female hit noise
|
||||
hurtSoundTimer = 10;
|
||||
}
|
||||
else if (titanHeartSet)
|
||||
{
|
||||
playSound = false;
|
||||
Terraria.Audio.LegacySoundStyle atlasHurt = Utils.SelectRandom(Main.rand, new Terraria.Audio.LegacySoundStyle[]
|
||||
{
|
||||
SoundLoader.GetLegacySoundSlot(Mod, "Sounds/NPCHit/AtlasHurt0"),
|
||||
SoundLoader.GetLegacySoundSlot(Mod, "Sounds/NPCHit/AtlasHurt1"),
|
||||
SoundLoader.GetLegacySoundSlot(Mod, "Sounds/NPCHit/AtlasHurt2")
|
||||
});
|
||||
SoundEngine.PlaySound(atlasHurt, (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(NPCs.Astral.Atlas.HurtSound, Player.position);
|
||||
hurtSoundTimer = 10;
|
||||
}
|
||||
}
|
||||
@@ -6141,7 +6146,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (amidiasBlessing)
|
||||
{
|
||||
Player.ClearBuff(ModContent.BuffType<AmidiasBlessing>());
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 96);
|
||||
SoundEngine.PlaySound(SoundID.Item96, Player.position);
|
||||
}
|
||||
|
||||
if ((gShell || flameLickedShell) && !Player.panic)
|
||||
@@ -6158,7 +6163,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (abyssalDivingSuitPlateHits >= 3)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.NPCKilled, (int)Player.position.X, (int)Player.position.Y, 14);
|
||||
SoundEngine.PlaySound(SoundID.NPCDeath14, Player.position);
|
||||
if (plateCDExists)
|
||||
cooldowns.Remove(DivingPlatesBreaking.ID);
|
||||
Player.AddCooldown(DivingPlatesBroken.ID, 10830);
|
||||
@@ -6185,7 +6190,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (aquaticHeartIce)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.NPCKilled, (int)Player.Center.X, (int)Player.Center.Y, 7);
|
||||
SoundEngine.PlaySound(SoundID.NPCDeath7, Player.Center);
|
||||
Player.AddCooldown(AquaticHeartIceShield.ID, CalamityUtils.SecondsToFrames(30));
|
||||
|
||||
for (int d = 0; d < 10; d++)
|
||||
@@ -6226,7 +6231,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if ((fBarrier || (aquaticHeart && NPC.downedBoss3)) && !areThereAnyDamnBosses)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 27);
|
||||
SoundEngine.PlaySound(SoundID.Item27, Player.position);
|
||||
for (int m = 0; m < Main.maxNPCs; m++)
|
||||
{
|
||||
NPC npc = Main.npc[m];
|
||||
@@ -6426,7 +6431,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (aBulwarkRare)
|
||||
{
|
||||
var source = Player.GetSource_Accessory(FindAccessory(ModContent.ItemType<HideofAstrumDeus>()));
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 74);
|
||||
SoundEngine.PlaySound(SoundID.Item74, Player.position);
|
||||
int blazeDamage = (int)Player.GetBestClassDamage().ApplyTo(25);
|
||||
int astralStarDamage = (int)Player.GetBestClassDamage().ApplyTo(320);
|
||||
Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, 0f, 0f, ModContent.ProjectileType<GodSlayerBlaze>(), blazeDamage, 5f, Player.whoAmI, 0f, 1f);
|
||||
@@ -6455,7 +6460,7 @@ namespace CalamityMod.CalPlayer
|
||||
var source = Player.GetSource_Accessory(FindAccessory(ModContent.ItemType<FungalCarapace>()));
|
||||
if (damage > 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.NPCHit, (int)Player.position.X, (int)Player.position.Y, 45);
|
||||
SoundEngine.PlaySound(SoundID.NPCHit45, Player.position);
|
||||
float spread = 45f * 0.0174f;
|
||||
double startAngle = Math.Atan2(Player.velocity.X, Player.velocity.Y) - spread / 2;
|
||||
double deltaAngle = spread / 8f;
|
||||
@@ -6481,7 +6486,7 @@ namespace CalamityMod.CalPlayer
|
||||
var source = Player.GetSource_Accessory(FindAccessory(ModContent.ItemType<HideofAstrumDeus>()));
|
||||
if (damage > 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 93);
|
||||
SoundEngine.PlaySound(SoundID.Item93, Player.position);
|
||||
float spread = 45f * 0.0174f;
|
||||
double startAngle = Math.Atan2(Player.velocity.X, Player.velocity.Y) - spread / 2;
|
||||
double deltaAngle = spread / 8f;
|
||||
@@ -6522,7 +6527,7 @@ namespace CalamityMod.CalPlayer
|
||||
rogueStealth += 0.5f;
|
||||
for (int i = 0; i < 5; i++)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Main.player[Main.myPlayer].position.X, (int)Main.player[Main.myPlayer].position.Y, 61);
|
||||
SoundEngine.PlaySound(SoundID.Item61, Player.position);
|
||||
int ink = Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, Main.rand.NextFloat(-3f, 3f), Main.rand.NextFloat(-0f, -4f), ModContent.ProjectileType<InkBombProjectile>(), 0, 0, Player.whoAmI);
|
||||
if (ink.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[ink].Calamity().forceClassless = true;
|
||||
@@ -6552,7 +6557,7 @@ namespace CalamityMod.CalPlayer
|
||||
var fuckYouBitch = Player.GetSource_Misc("21");
|
||||
if (damage > 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 74);
|
||||
SoundEngine.PlaySound(SoundID.Item74, Player.position);
|
||||
int eDamage = (int)Player.GetBestClassDamage().ApplyTo(100);
|
||||
if (Player.whoAmI == Main.myPlayer)
|
||||
Projectile.NewProjectile(fuckYouBitch, Player.Center, Vector2.Zero, ModContent.ProjectileType<ChaosBlaze>(), eDamage, 1f, Player.whoAmI, 0f, 0f);
|
||||
@@ -6563,7 +6568,7 @@ namespace CalamityMod.CalPlayer
|
||||
var source = Player.GetSource_Misc("22");
|
||||
if (damage > 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 27);
|
||||
SoundEngine.PlaySound(SoundID.Item27, Player.position);
|
||||
float spread = 45f * 0.0174f;
|
||||
double startAngle = Math.Atan2(Player.velocity.X, Player.velocity.Y) - spread / 2;
|
||||
double deltaAngle = spread / 8f;
|
||||
@@ -6601,7 +6606,7 @@ namespace CalamityMod.CalPlayer
|
||||
var source = Player.GetSource_Misc("24");
|
||||
if (damage > 80)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)Player.position.X, (int)Player.position.Y, 73);
|
||||
SoundEngine.PlaySound(SoundID.Item73, Player.position);
|
||||
float spread = 45f * 0.0174f;
|
||||
double startAngle = Math.Atan2(Player.velocity.X, Player.velocity.Y) - spread / 2;
|
||||
double deltaAngle = spread / 8f;
|
||||
@@ -6710,7 +6715,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.KillMeForGood();
|
||||
}
|
||||
}
|
||||
SoundEngine.PlaySound(SoundID.PlayerKilled, (int)Player.position.X, (int)Player.position.Y, 1, 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.PlayerKilled, Player.position);
|
||||
Player.headVelocity.Y = (float)Main.rand.Next(-40, -10) * 0.1f;
|
||||
Player.bodyVelocity.Y = (float)Main.rand.Next(-40, -10) * 0.1f;
|
||||
Player.legVelocity.Y = (float)Main.rand.Next(-40, -10) * 0.1f;
|
||||
@@ -6890,7 +6895,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (playRogueStealthSound && rogueStealth >= rogueStealthMax)
|
||||
{
|
||||
playRogueStealthSound = false;
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/RogueStealth"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(RogueStealthSound, Player.position);
|
||||
}
|
||||
|
||||
// If the player isn't at full stealth, reset the sound so it'll play again when they hit full stealth.
|
||||
@@ -7586,312 +7591,312 @@ namespace CalamityMod.CalPlayer
|
||||
#region MeleeLevelBoosts
|
||||
if (meleeLevel >= 12500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.06f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 3;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.06f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 3;
|
||||
}
|
||||
else if (meleeLevel >= 10500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.06f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 3;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.06f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 3;
|
||||
}
|
||||
else if (meleeLevel >= 9100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.06f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 3;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.06f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 3;
|
||||
}
|
||||
else if (meleeLevel >= 7800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 3;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 3;
|
||||
}
|
||||
else if (meleeLevel >= 6600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 3;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 3;
|
||||
}
|
||||
else if (meleeLevel >= 5500) //hm limit
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 2;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 2;
|
||||
}
|
||||
else if (meleeLevel >= 4500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 2;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 2;
|
||||
}
|
||||
else if (meleeLevel >= 3600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 2;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.04f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 2;
|
||||
}
|
||||
else if (meleeLevel >= 2800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 1;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.04f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 1;
|
||||
}
|
||||
else if (meleeLevel >= 2100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 1;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.04f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 1;
|
||||
}
|
||||
else if (meleeLevel >= 1500) //prehm limit
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.03f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 1;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.03f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 1;
|
||||
}
|
||||
else if (meleeLevel >= 1000)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.02f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 1;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.02f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 1;
|
||||
}
|
||||
else if (meleeLevel >= 600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.02f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.02f;
|
||||
}
|
||||
else if (meleeLevel >= 300)
|
||||
Player.GetDamage(DamageClass.Melee) += 0.02f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.02f;
|
||||
else if (meleeLevel >= 100)
|
||||
Player.GetDamage(DamageClass.Melee) += 0.01f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.01f;
|
||||
#endregion
|
||||
|
||||
#region RangedLevelBoosts
|
||||
if (rangedLevel >= 12500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.06f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.06f;
|
||||
Player.moveSpeed += 0.06f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
Player.GetCritChance<RangedDamageClass>() += 3;
|
||||
}
|
||||
else if (rangedLevel >= 10500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.05f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.05f;
|
||||
Player.moveSpeed += 0.06f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
Player.GetCritChance<RangedDamageClass>() += 3;
|
||||
}
|
||||
else if (rangedLevel >= 9100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.05f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.05f;
|
||||
Player.moveSpeed += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
Player.GetCritChance<RangedDamageClass>() += 3;
|
||||
}
|
||||
else if (rangedLevel >= 7800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.04f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.04f;
|
||||
Player.moveSpeed += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
Player.GetCritChance<RangedDamageClass>() += 3;
|
||||
}
|
||||
else if (rangedLevel >= 6600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.04f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.04f;
|
||||
Player.moveSpeed += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
Player.GetCritChance<RangedDamageClass>() += 3;
|
||||
}
|
||||
else if (rangedLevel >= 5500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.04f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.04f;
|
||||
Player.moveSpeed += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 2;
|
||||
Player.GetCritChance<RangedDamageClass>() += 2;
|
||||
}
|
||||
else if (rangedLevel >= 4500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.03f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.03f;
|
||||
Player.moveSpeed += 0.04f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 2;
|
||||
Player.GetCritChance<RangedDamageClass>() += 2;
|
||||
}
|
||||
else if (rangedLevel >= 3600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.03f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.03f;
|
||||
Player.moveSpeed += 0.03f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 2;
|
||||
Player.GetCritChance<RangedDamageClass>() += 2;
|
||||
}
|
||||
else if (rangedLevel >= 2800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
Player.moveSpeed += 0.03f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 2;
|
||||
Player.GetCritChance<RangedDamageClass>() += 2;
|
||||
}
|
||||
else if (rangedLevel >= 2100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
Player.moveSpeed += 0.03f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 1;
|
||||
Player.GetCritChance<RangedDamageClass>() += 1;
|
||||
}
|
||||
else if (rangedLevel >= 1500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
Player.moveSpeed += 0.02f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 1;
|
||||
Player.GetCritChance<RangedDamageClass>() += 1;
|
||||
}
|
||||
else if (rangedLevel >= 1000)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
Player.moveSpeed += 0.01f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 1;
|
||||
Player.GetCritChance<RangedDamageClass>() += 1;
|
||||
}
|
||||
else if (rangedLevel >= 600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetCritChance(DamageClass.Ranged) += 1;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
Player.GetCritChance<RangedDamageClass>() += 1;
|
||||
}
|
||||
else if (rangedLevel >= 300)
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.02f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.02f;
|
||||
else if (rangedLevel >= 100)
|
||||
Player.GetDamage(DamageClass.Ranged) += 0.01f;
|
||||
Player.GetDamage<RangedDamageClass>() += 0.01f;
|
||||
#endregion
|
||||
|
||||
#region MagicLevelBoosts
|
||||
if (magicLevel >= 12500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.06f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.06f;
|
||||
Player.manaCost *= 0.94f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 3;
|
||||
Player.GetCritChance<MagicDamageClass>() += 3;
|
||||
}
|
||||
else if (magicLevel >= 10500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
Player.manaCost *= 0.94f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 3;
|
||||
Player.GetCritChance<MagicDamageClass>() += 3;
|
||||
}
|
||||
else if (magicLevel >= 9100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
Player.manaCost *= 0.95f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 3;
|
||||
Player.GetCritChance<MagicDamageClass>() += 3;
|
||||
}
|
||||
else if (magicLevel >= 7800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.04f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.04f;
|
||||
Player.manaCost *= 0.95f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 3;
|
||||
Player.GetCritChance<MagicDamageClass>() += 3;
|
||||
}
|
||||
else if (magicLevel >= 6600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.04f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.04f;
|
||||
Player.manaCost *= 0.96f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 3;
|
||||
Player.GetCritChance<MagicDamageClass>() += 3;
|
||||
}
|
||||
else if (magicLevel >= 5500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.04f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.04f;
|
||||
Player.manaCost *= 0.96f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 2;
|
||||
Player.GetCritChance<MagicDamageClass>() += 2;
|
||||
}
|
||||
else if (magicLevel >= 4500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.04f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.04f;
|
||||
Player.manaCost *= 0.97f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 2;
|
||||
Player.GetCritChance<MagicDamageClass>() += 2;
|
||||
}
|
||||
else if (magicLevel >= 3600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.03f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.03f;
|
||||
Player.manaCost *= 0.97f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 2;
|
||||
Player.GetCritChance<MagicDamageClass>() += 2;
|
||||
}
|
||||
else if (magicLevel >= 2800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.03f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.03f;
|
||||
Player.manaCost *= 0.98f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 2;
|
||||
Player.GetCritChance<MagicDamageClass>() += 2;
|
||||
}
|
||||
else if (magicLevel >= 2100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.03f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.03f;
|
||||
Player.manaCost *= 0.98f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 1;
|
||||
Player.GetCritChance<MagicDamageClass>() += 1;
|
||||
}
|
||||
else if (magicLevel >= 1500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.02f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.02f;
|
||||
Player.manaCost *= 0.98f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 1;
|
||||
Player.GetCritChance<MagicDamageClass>() += 1;
|
||||
}
|
||||
else if (magicLevel >= 1000)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.02f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.02f;
|
||||
Player.manaCost *= 0.99f;
|
||||
Player.GetCritChance(DamageClass.Magic) += 1;
|
||||
Player.GetCritChance<MagicDamageClass>() += 1;
|
||||
}
|
||||
else if (magicLevel >= 600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.02f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.02f;
|
||||
Player.manaCost *= 0.99f;
|
||||
}
|
||||
else if (magicLevel >= 300)
|
||||
Player.GetDamage(DamageClass.Magic) += 0.02f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.02f;
|
||||
else if (magicLevel >= 100)
|
||||
Player.GetDamage(DamageClass.Magic) += 0.01f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.01f;
|
||||
#endregion
|
||||
|
||||
#region SummonLevelBoosts
|
||||
if (summonLevel >= 12500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.12f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 3.0f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.12f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 3.0f;
|
||||
}
|
||||
else if (summonLevel >= 10500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 3.0f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 3.0f;
|
||||
}
|
||||
else if (summonLevel >= 9100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.09f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 2.7f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.09f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 2.7f;
|
||||
}
|
||||
else if (summonLevel >= 7800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.08f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 2.4f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.08f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 2.4f;
|
||||
}
|
||||
else if (summonLevel >= 6600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.07f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 2.1f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.07f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 2.1f;
|
||||
}
|
||||
else if (summonLevel >= 5500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.07f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 1.8f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.07f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 1.8f;
|
||||
}
|
||||
else if (summonLevel >= 4500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.06f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 1.8f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.06f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 1.8f;
|
||||
}
|
||||
else if (summonLevel >= 3600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 1.5f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 1.5f;
|
||||
}
|
||||
else if (summonLevel >= 2800)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.04f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 1.2f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.04f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 1.2f;
|
||||
}
|
||||
else if (summonLevel >= 2100)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.04f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 0.9f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.04f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 0.9f;
|
||||
}
|
||||
else if (summonLevel >= 1500)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.03f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 0.6f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.03f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 0.6f;
|
||||
}
|
||||
else if (summonLevel >= 1000)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.03f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 0.3f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.03f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 0.3f;
|
||||
}
|
||||
else if (summonLevel >= 600)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.02f;
|
||||
Player.GetKnockback(DamageClass.Summon).Base += 0.3f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.02f;
|
||||
Player.GetKnockback(DamageClass.Summon) += 0.3f;
|
||||
}
|
||||
else if (summonLevel >= 300)
|
||||
Player.GetDamage(DamageClass.Summon) += 0.02f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.02f;
|
||||
else if (summonLevel >= 100)
|
||||
Player.GetDamage(DamageClass.Summon) += 0.01f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.01f;
|
||||
#endregion
|
||||
|
||||
#region RogueLevelBoosts
|
||||
@@ -8247,7 +8252,7 @@ namespace CalamityMod.CalPlayer
|
||||
// Play a sound from taking defense damage.
|
||||
if (hurtSoundTimer == 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/DefenseDamage"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(DefenseDamageSound, Player.position);
|
||||
hurtSoundTimer = 30;
|
||||
}
|
||||
|
||||
|
||||
@@ -169,8 +169,8 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
// player.rangedCrit already contains the crit stat of the held item, no need to grab it separately.
|
||||
// Don't store the base 4% because you're not removing it.
|
||||
spiritOriginConvertedCrit = (int)(Player.GetCritChance(DamageClass.Ranged) - 4);
|
||||
Player.GetCritChance(DamageClass.Ranged) = 4;
|
||||
spiritOriginConvertedCrit = (int)(Player.GetCritChance<RangedDamageClass>() - 4);
|
||||
Player.GetCritChance<RangedDamageClass>() = 4;
|
||||
}
|
||||
|
||||
if (Player.ActiveItem().type == ModContent.ItemType<GaelsGreatsword>())
|
||||
@@ -380,7 +380,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (playFullRageSound)
|
||||
{
|
||||
playFullRageSound = false;
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/FullRage"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(RageFilledSound, Player.position);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -426,7 +426,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (playFullAdrenalineSound)
|
||||
{
|
||||
playFullAdrenalineSound = false;
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/FullAdrenaline"), (int)Player.position.X, (int)Player.position.Y);
|
||||
SoundEngine.PlaySound(AdrenalineFilledSound, Player.position);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -935,7 +935,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (attack)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.1f +
|
||||
Player.GetDamage<SummonDamageClass>() += 0.1f +
|
||||
(defend ? 0.05f : 0f);
|
||||
}
|
||||
}
|
||||
@@ -1183,7 +1183,7 @@ namespace CalamityMod.CalPlayer
|
||||
silvaCountdown -= 1;
|
||||
if (silvaCountdown <= 0)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(Mod, "Sounds/Custom/AbilitySounds/SilvaDispel"), Player.Center);
|
||||
SoundEngine.PlaySound(SilvaHelmet.DispelSound, Player.Center);
|
||||
Player.AddCooldown(SilvaRevive.ID, CalamityUtils.SecondsToFrames(5 * 60));
|
||||
}
|
||||
|
||||
@@ -1285,8 +1285,8 @@ namespace CalamityMod.CalPlayer
|
||||
Player.AddCooldown(BloodflareFrenzy.ID, CalamityUtils.SecondsToFrames(30));
|
||||
}
|
||||
|
||||
Player.GetCritChance(DamageClass.Melee) += 25;
|
||||
Player.GetDamage(DamageClass.Melee) += 0.25f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 25;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.25f;
|
||||
|
||||
for (int j = 0; j < 2; j++)
|
||||
{
|
||||
@@ -1472,8 +1472,8 @@ namespace CalamityMod.CalPlayer
|
||||
// Vortex Armor nerf
|
||||
if (Player.vortexStealthActive)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Ranged) -= (1f - Player.stealth) * 0.4f; // Change 80 to 40
|
||||
Player.GetCritChance(DamageClass.Ranged) -= (int)((1f - Player.stealth) * 5f); // Change 20 to 15
|
||||
Player.GetDamage<RangedDamageClass>() -= (1f - Player.stealth) * 0.4f; // Change 80 to 40
|
||||
Player.GetCritChance<RangedDamageClass>() -= (int)((1f - Player.stealth) * 5f); // Change 20 to 15
|
||||
}
|
||||
|
||||
// Polaris fish stuff
|
||||
@@ -2346,7 +2346,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (armorCrumbling)
|
||||
{
|
||||
Player.GetCritChance<RogueDamageClass>() += 5;
|
||||
Player.GetCritChance(DamageClass.Melee) += 5;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 5;
|
||||
}
|
||||
|
||||
if (armorShattering)
|
||||
@@ -2354,9 +2354,9 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.FindBuffIndex(ModContent.BuffType<ArmorCrumbling>()) > -1)
|
||||
Player.ClearBuff(ModContent.BuffType<ArmorCrumbling>());
|
||||
Player.GetDamage<ThrowingDamageClass>() += 0.08f;
|
||||
Player.GetDamage(DamageClass.Melee) += 0.08f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.08f;
|
||||
Player.GetCritChance<RogueDamageClass>() += 8;
|
||||
Player.GetCritChance(DamageClass.Melee) += 8;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 8;
|
||||
}
|
||||
|
||||
if (holyWrath)
|
||||
@@ -2384,7 +2384,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.statDefense -= 10;
|
||||
Player.moveSpeed -= 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.05f;
|
||||
Player.GetKnockback<SummonDamageClass>().Base += 0.5f;
|
||||
Player.GetKnockback<SummonDamageClass>() += 0.5f;
|
||||
}
|
||||
|
||||
if (rRage)
|
||||
@@ -2403,13 +2403,13 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Player.statDefense += 30;
|
||||
Player.endurance += 0.1f;
|
||||
Player.GetDamage(DamageClass.Melee) += 0.2f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.2f;
|
||||
}
|
||||
|
||||
if (tFury)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.3f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 10;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.3f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 10;
|
||||
}
|
||||
|
||||
if (yPower)
|
||||
@@ -2419,7 +2419,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.pickSpeed -= 0.05f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
Player.GetCritChance<GenericDamageClass>() += YharimsStimulants.CritBoost;
|
||||
Player.GetKnockback<SummonDamageClass>().Base += 1f;
|
||||
Player.GetKnockback<SummonDamageClass>() += 1f;
|
||||
Player.moveSpeed += 0.06f;
|
||||
}
|
||||
|
||||
@@ -2441,7 +2441,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Player.maxMinions += 2;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.12f;
|
||||
Player.GetKnockback<SummonDamageClass>().Base += 1.2f;
|
||||
Player.GetKnockback<SummonDamageClass>() += 1.2f;
|
||||
Player.pickSpeed -= 0.15f;
|
||||
if (Main.eclipse || !Main.dayTime)
|
||||
Player.statDefense += 15;
|
||||
@@ -2451,8 +2451,8 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Player.kbGlove = true;
|
||||
Player.magmaStone = true;
|
||||
Player.GetDamage(DamageClass.Melee) += 0.15f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 5;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.15f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 5;
|
||||
Player.lavaMax += 240;
|
||||
}
|
||||
|
||||
@@ -2543,7 +2543,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (starBeamRye)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Magic) += 0.08f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.08f;
|
||||
Player.manaCost *= 0.9f;
|
||||
}
|
||||
|
||||
@@ -2554,13 +2554,13 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
if (whiteWine)
|
||||
Player.GetDamage(DamageClass.Magic) += 0.1f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.1f;
|
||||
|
||||
// Adjustment to the Tipsy debuff
|
||||
if (Player.tipsy)
|
||||
{
|
||||
Player.statDefense += 4;
|
||||
Player.GetCritChance(DamageClass.Melee) -= 2;
|
||||
Player.GetCritChance<MeleeDamageClass>() -= 2;
|
||||
}
|
||||
|
||||
if (giantPearl)
|
||||
@@ -2589,7 +2589,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.GetDamage<ThrowingDamageClass>() += 0.1f;
|
||||
|
||||
if (CalamityLists.javelinList.Contains(Player.ActiveItem().type) && Player.invis)
|
||||
Player.GetArmorPenetration(DamageClass.Generic) += 5;
|
||||
Player.GetArmorPenetration<GenericDamageClass>() += 5;
|
||||
|
||||
if (CalamityLists.flaskBombList.Contains(Player.ActiveItem().type) && Player.invis)
|
||||
rogueVelocity += 0.1f;
|
||||
@@ -2684,7 +2684,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.statDefense += integerTypeBoost;
|
||||
Player.GetDamage<GenericDamageClass>() += damageBoost;
|
||||
Player.GetCritChance<GenericDamageClass>() += critBoost;
|
||||
Player.GetKnockback<SummonDamageClass>().Base += floatTypeBoost;
|
||||
Player.GetKnockback<SummonDamageClass>() += floatTypeBoost;
|
||||
Player.moveSpeed += floatTypeBoost * 0.5f;
|
||||
flightTimeMult += floatTypeBoost;
|
||||
}
|
||||
@@ -2821,9 +2821,9 @@ namespace CalamityMod.CalPlayer
|
||||
Player.blind = true;
|
||||
Player.statDefense -= 3;
|
||||
Player.moveSpeed += 0.1f;
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetDamage(DamageClass.Ranged) -= 0.1f;
|
||||
Player.GetDamage(DamageClass.Magic) -= 0.1f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetDamage<RangedDamageClass>() -= 0.1f;
|
||||
Player.GetDamage<MagicDamageClass>() -= 0.1f;
|
||||
}
|
||||
|
||||
if (aCrunch && !laudanum)
|
||||
@@ -2887,7 +2887,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
if (warbannerOfTheSun)
|
||||
Player.GetDamage(DamageClass.Melee) += warBannerBonus;
|
||||
Player.GetDamage<MeleeDamageClass>() += warBannerBonus;
|
||||
|
||||
// The player's true max life value with Calamity adjustments
|
||||
actualMaxLife = Player.statLifeMax2;
|
||||
@@ -2899,7 +2899,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
if (manaOverloader)
|
||||
Player.GetDamage(DamageClass.Magic) += 0.06f;
|
||||
Player.GetDamage<MagicDamageClass>() += 0.06f;
|
||||
|
||||
if (rBrain)
|
||||
{
|
||||
@@ -2910,7 +2910,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
if (bloodyWormTooth)
|
||||
Player.GetDamage(DamageClass.Melee) += 0.07f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.07f;
|
||||
|
||||
if (dAmulet)
|
||||
Player.pStone = true;
|
||||
@@ -2954,7 +2954,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (bloodflareSummon)
|
||||
{
|
||||
if (Player.statLife >= (int)(Player.statLifeMax2 * 0.9))
|
||||
Player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
else if (Player.statLife <= (int)(Player.statLifeMax2 * 0.5))
|
||||
Player.statDefense += 20;
|
||||
|
||||
@@ -2982,7 +2982,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (yInsignia)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
Player.lavaMax += 240;
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.5))
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
@@ -3229,8 +3229,8 @@ namespace CalamityMod.CalPlayer
|
||||
bool offenseBuffs = (Main.dayTime && !Player.wet) || Player.lavaWet;
|
||||
if (offenseBuffs)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) += 0.15f;
|
||||
Player.GetKnockback<SummonDamageClass>().Base += 0.15f;
|
||||
Player.GetDamage<SummonDamageClass>() += 0.15f;
|
||||
Player.GetKnockback<SummonDamageClass>() += 0.15f;
|
||||
Player.moveSpeed += 0.1f;
|
||||
Player.statDefense -= 15;
|
||||
Player.ignoreWater = true;
|
||||
@@ -3522,8 +3522,8 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (badgeOfBravery)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
Player.GetCritChance(DamageClass.Melee) += 5;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
Player.GetCritChance<MeleeDamageClass>() += 5;
|
||||
}
|
||||
|
||||
if (CalamityConfig.Instance.Proficiency)
|
||||
@@ -3637,7 +3637,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.statDefense += (int)(Player.statDefense * 0.25);
|
||||
break;
|
||||
case BuffID.Weak:
|
||||
Player.GetDamage(DamageClass.Melee) += 0.151f;
|
||||
Player.GetDamage<MeleeDamageClass>() += 0.151f;
|
||||
Player.statDefense += 14;
|
||||
Player.moveSpeed += 0.3f;
|
||||
break;
|
||||
|
||||
@@ -25,6 +25,7 @@ using Terraria.ModLoader;
|
||||
using static Terraria.ModLoader.ModContent;
|
||||
using Terraria.Audio;
|
||||
using CalamityMod.EntitySources;
|
||||
using CalamityMod.Sounds;
|
||||
|
||||
namespace CalamityMod.CalPlayer
|
||||
{
|
||||
@@ -678,7 +679,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
double useTimeMultiplier = 0.85 + (item.useTime * item.useAnimation / 3600D); //28 * 28 = 784 is average so that equals 784 / 3600 = 0.217777 + 1 = 21.7% boost
|
||||
double wingTimeFraction = Player.wingTimeMax / 20D;
|
||||
double meleeStatMultiplier = (double)(Player.GetDamage(DamageClass.Melee).Base * (float)(Player.GetCritChance(DamageClass.Melee) / 10D));
|
||||
double meleeStatMultiplier = (double)(Player.GetDamage<MeleeDamageClass>().Additive * (float)(Player.GetCritChance<MeleeDamageClass>() / 10D));
|
||||
|
||||
if (Player.wingTime < Player.wingTimeMax)
|
||||
Player.wingTime += (int)(useTimeMultiplier * (wingTimeFraction + meleeStatMultiplier));
|
||||
@@ -774,7 +775,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
double useTimeMultiplier = 0.85 + (heldItem.useTime * heldItem.useAnimation / 3600D); //28 * 28 = 784 is average so that equals 784 / 3600 = 0.217777 + 1 = 21.7% boost
|
||||
double wingTimeFraction = Player.wingTimeMax / 20D;
|
||||
double meleeStatMultiplier = Player.GetDamage(DamageClass.Melee).Base * (float)(Player.GetCritChance(DamageClass.Melee) / 10D);
|
||||
double meleeStatMultiplier = Player.GetDamage<MeleeDamageClass>().Additive * (float)(Player.GetCritChance<MeleeDamageClass>() / 10D);
|
||||
|
||||
if (Player.wingTime < Player.wingTimeMax)
|
||||
Player.wingTime += (int)(useTimeMultiplier * (wingTimeFraction + meleeStatMultiplier));
|
||||
@@ -889,7 +890,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (silvaMage && silvaMageCooldown <= 0 && (proj.penetrate == 1 || proj.timeLeft <= 5))
|
||||
{
|
||||
silvaMageCooldown = 300;
|
||||
SoundEngine.PlaySound(SoundID.Zombie, (int)proj.position.X, (int)proj.position.Y, 103);
|
||||
SoundEngine.PlaySound(CommonCalamitySounds.GetZombieSound(103) , proj.position); //So scuffed, just because zombie sounds werent ported normally
|
||||
// Silva Mage Blasts: 800 + 60%, softcap on the whole combined thing starts at 1400
|
||||
int silvaBurstDamage = CalamityUtils.DamageSoftCap(800.0 + 0.6 * proj.damage, 1400);
|
||||
Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<SilvaBurst>(), silvaBurstDamage, 8f, Player.whoAmI);
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
public override void OnHitEffects(Player player, NPC npc, IEntitySource source, ref DashHitContext hitContext)
|
||||
{
|
||||
float kbFactor = 15f;
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance(DamageClass.Melee);
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance<MeleeDamageClass>();
|
||||
if (player.kbGlove)
|
||||
kbFactor *= 2f;
|
||||
if (player.kbBuff)
|
||||
|
||||
@@ -50,7 +50,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
public override void OnHitEffects(Player player, NPC npc, IEntitySource source, ref DashHitContext hitContext)
|
||||
{
|
||||
float kbFactor = 9f;
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance(DamageClass.Melee);
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance<MeleeDamageClass>();
|
||||
if (player.kbGlove)
|
||||
kbFactor *= 2f;
|
||||
if (player.kbBuff)
|
||||
|
||||
@@ -53,7 +53,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
public override void OnHitEffects(Player player, NPC npc, IEntitySource source, ref DashHitContext hitContext)
|
||||
{
|
||||
float kbFactor = 12f;
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance(DamageClass.Melee);
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance<MeleeDamageClass>();
|
||||
if (player.kbGlove)
|
||||
kbFactor *= 2f;
|
||||
if (player.kbBuff)
|
||||
|
||||
@@ -9,6 +9,7 @@ using Terraria.DataStructures;
|
||||
using Terraria.Graphics.Shaders;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using CalamityMod.NPCs.DevourerofGods;
|
||||
|
||||
namespace CalamityMod.CalPlayer.Dashes
|
||||
{
|
||||
@@ -22,7 +23,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
|
||||
public override void OnDashEffects(Player player)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(CalamityMod.Instance, "Sounds/Custom/DevourerAttack"), player.Center);
|
||||
SoundEngine.PlaySound(DevourerofGodsHead.AttackSound, player.Center);
|
||||
|
||||
for (int d = 0; d < 60; d++)
|
||||
{
|
||||
@@ -65,7 +66,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
|
||||
public override void OnHitEffects(Player player, NPC npc, IEntitySource source, ref DashHitContext hitContext)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Item, (int)player.position.X, (int)player.position.Y, 67);
|
||||
SoundEngine.PlaySound(SoundID.Item67, player.position);
|
||||
|
||||
for (int j = 0; j < 30; j++)
|
||||
{
|
||||
@@ -79,7 +80,7 @@ namespace CalamityMod.CalPlayer.Dashes
|
||||
}
|
||||
|
||||
float kbFactor = 15f;
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance(DamageClass.Melee);
|
||||
bool crit = Main.rand.Next(100) < player.GetCritChance<MeleeDamageClass>();
|
||||
if (player.kbGlove)
|
||||
kbFactor *= 2f;
|
||||
if (player.kbBuff)
|
||||
|
||||
@@ -15,6 +15,6 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color CooldownStartColor => new Color(216, 60, 90);
|
||||
public override Color CooldownEndColor => new Color(251, 106, 150);
|
||||
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/BloodflareRangerRecharge");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/BloodflareRangerRecharge");
|
||||
}
|
||||
}
|
||||
@@ -17,7 +17,7 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color CooldownStartColor => Color.Lerp(new Color(107, 6, 6), new Color(228, 78, 78), 1 - instance.Completion);
|
||||
public override Color CooldownEndColor => Color.Lerp(new Color(107, 6, 6), new Color(228, 78, 78), 1 - instance.Completion);
|
||||
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/BrimflameRecharge");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/BrimflameRecharge");
|
||||
|
||||
|
||||
//Add red eyes to the icon
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color OutlineColor => outlineColor;
|
||||
public override Color CooldownStartColor => Color.Lerp(cooldownColorStart, cooldownColorEnd, 1 - instance.Completion);
|
||||
public override Color CooldownEndColor => Color.Lerp(cooldownColorStart, cooldownColorEnd, 1 - instance.Completion);
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/ChaosStateOver");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/ChaosStateOver");
|
||||
|
||||
//It's the same cooldown with different skins each time, basically.
|
||||
public string skinTexture;
|
||||
|
||||
@@ -47,7 +47,7 @@ namespace CalamityMod.Cooldowns
|
||||
/// <summary>
|
||||
/// When the cooldown instance ends, this sound is played. Leave at <b>null</b> for no sound.
|
||||
/// </summary>
|
||||
public virtual LegacySoundStyle EndSound => null;
|
||||
public virtual SoundStyle EndSound => null;
|
||||
#endregion
|
||||
|
||||
#region Display & Rendering
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color OutlineColor => instance.timeLeft > 1500 ? new Color(231, 164, 1) : new Color(72, 135, 205);
|
||||
public override Color CooldownStartColor => instance.timeLeft > 1500 ? Color.Lerp(new Color(98, 110, 179), new Color(216, 176, 80), (instance.timeLeft - 1500) / 300f) : new Color(98, 110, 179);
|
||||
public override Color CooldownEndColor => instance.timeLeft > 1500 ? Color.Lerp(new Color(179, 132, 98), new Color(216, 176, 80), (instance.timeLeft - 1500) / 300f) : new Color(179, 132, 98);
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/OmegaBlueRecharge");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/OmegaBlueRecharge");
|
||||
|
||||
public override void OnCompleted()
|
||||
{
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color OutlineColor => new Color(174, 237, 122);
|
||||
public override Color CooldownStartColor => Color.DarkSlateGray;
|
||||
public override Color CooldownEndColor => Color.DarkSlateGray;
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/PlagueReaperRecharge");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/PlagueReaperRecharge");
|
||||
|
||||
public override void OnCompleted()
|
||||
{
|
||||
|
||||
@@ -14,6 +14,6 @@ namespace CalamityMod.Cooldowns
|
||||
public override Color OutlineColor => new Color(255, 142, 165);
|
||||
public override Color CooldownStartColor => Color.Lerp(new Color(208, 234, 255), new Color(231, 3, 54), instance.Completion);
|
||||
public override Color CooldownEndColor => Color.Lerp(new Color(208, 234, 255), new Color(231, 3, 54), instance.Completion);
|
||||
public override LegacySoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/PotionSicknessOver");
|
||||
public override SoundStyle EndSound => SoundLoader.GetLegacySoundSlot(GetInstance<CalamityMod>(), "Sounds/Custom/AbilitySounds/PotionSicknessOver");
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod
|
||||
{
|
||||
public class AverageDamageClass : DamageClass
|
||||
{
|
||||
internal static AverageDamageClass Instance;
|
||||
|
||||
internal static readonly StatInheritanceData TwentyPercentBoost = new (0.2f, 0.2f, 0.2f, 0.2f, 0.2f);
|
||||
|
||||
public override void Load() => Instance = this;
|
||||
public override void Unload() => Instance = null;
|
||||
|
||||
public override StatInheritanceData GetModifierInheritance(DamageClass damageClass)
|
||||
{
|
||||
if (damageClass == Melee || damageClass == Ranged || damageClass == Magic || damageClass == Summon || damageClass == RogueDamageClass.Instance)
|
||||
return TwentyPercentBoost;
|
||||
if (damageClass == Generic)
|
||||
return StatInheritanceData.Full;
|
||||
|
||||
return StatInheritanceData.None;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -300,27 +300,27 @@ namespace CalamityMod.DataStructures
|
||||
// The melee speed boost code is present in the Player Misc Effects file.
|
||||
if (IsYellowGemActive)
|
||||
{
|
||||
Owner.GetCritChance(DamageClass.Melee) += (int)(GemTechHeadgear.MeleeCritBoost * 100f);
|
||||
Owner.GetDamage(DamageClass.Melee) += GemTechHeadgear.MeleeDamageBoost;
|
||||
Owner.GetCritChance<MeleeDamageClass>() += (int)(GemTechHeadgear.MeleeCritBoost * 100f);
|
||||
Owner.GetDamage<MeleeDamageClass>() += GemTechHeadgear.MeleeDamageBoost;
|
||||
}
|
||||
|
||||
if (IsGreenGemActive)
|
||||
{
|
||||
Owner.GetCritChance(DamageClass.Ranged) += (int)(GemTechHeadgear.RangedCritBoost * 100f);
|
||||
Owner.GetDamage(DamageClass.Ranged) += GemTechHeadgear.RangedDamageBoost;
|
||||
Owner.GetCritChance<RangedDamageClass>() += (int)(GemTechHeadgear.RangedCritBoost * 100f);
|
||||
Owner.GetDamage<RangedDamageClass>() += GemTechHeadgear.RangedDamageBoost;
|
||||
}
|
||||
|
||||
if (IsBlueGemActive)
|
||||
{
|
||||
Owner.maxMinions += GemTechHeadgear.SummonMinionCountBoost;
|
||||
Owner.GetDamage(DamageClass.Summon) += GemTechHeadgear.SummonDamageBoost;
|
||||
Owner.GetDamage<SummonDamageClass>() += GemTechHeadgear.SummonDamageBoost;
|
||||
}
|
||||
|
||||
if (IsPurpleGemActive)
|
||||
{
|
||||
Owner.statManaMax2 += GemTechHeadgear.MagicManaBoost;
|
||||
Owner.GetCritChance(DamageClass.Magic) += (int)(GemTechHeadgear.MagicCritBoost * 100f);
|
||||
Owner.GetDamage(DamageClass.Magic) += GemTechHeadgear.MagicDamageBoost;
|
||||
Owner.GetCritChance<MagicDamageClass>() += (int)(GemTechHeadgear.MagicCritBoost * 100f);
|
||||
Owner.GetDamage<MagicDamageClass>() += GemTechHeadgear.MagicDamageBoost;
|
||||
}
|
||||
|
||||
if (IsPinkGemActive)
|
||||
|
||||
@@ -221,7 +221,7 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Player player = Main.player[ClosestPlayerToWorldCenter];
|
||||
|
||||
SoundEngine.PlaySound(SoundID.Roar, player.position, 2);
|
||||
SoundEngine.PlaySound(SoundID.ScaryScream, player.position);
|
||||
int ravager = NPC.NewNPC(Source, (int)(player.position.X + Main.rand.Next(-100, 101)), (int)(player.position.Y - 400f), type, 1);
|
||||
Main.npc[ravager].timeLeft *= 20;
|
||||
CalamityUtils.BossAwakenMessage(ravager);
|
||||
@@ -246,7 +246,7 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Player player = Main.player[ClosestPlayerToWorldCenter];
|
||||
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(CalamityMod.Instance, "Sounds/Custom/AstrumDeusSpawn"), player.Center);
|
||||
SoundEngine.PlaySound(AstrumDeusHeadSpectral.SpawnSound, player.Center);
|
||||
NPC.SpawnOnPlayer(ClosestPlayerToWorldCenter, type);
|
||||
}, usesSpecialSound: true, permittedNPCs: new int[] { ModContent.NPCType<AstrumDeusBodySpectral>(), ModContent.NPCType<AstrumDeusTailSpectral>() }),
|
||||
|
||||
@@ -275,7 +275,7 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Player player = Main.player[ClosestPlayerToWorldCenter];
|
||||
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(CalamityMod.Instance, "Sounds/Custom/ProvidenceSpawn"), player.Center);
|
||||
SoundEngine.PlaySound(Providence.SpawnSound, player.Center);
|
||||
int prov = NPC.NewNPC(Source, (int)(player.position.X + Main.rand.Next(-500, 501)), (int)(player.position.Y - 250f), type, 1);
|
||||
Main.npc[prov].timeLeft *= 20;
|
||||
CalamityUtils.BossAwakenMessage(prov);
|
||||
@@ -293,7 +293,7 @@ namespace CalamityMod.Events
|
||||
player.ClearBuff(ModContent.BuffType<ExtremeGravity>());
|
||||
}
|
||||
}
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(CalamityMod.Instance, "Sounds/Custom/SupremeCalamitasSpawn"), Main.player[ClosestPlayerToWorldCenter].Center);
|
||||
SoundEngine.PlaySound(SupremeCalamitas.SpawnSound, Main.player[ClosestPlayerToWorldCenter].Center);
|
||||
CalamityUtils.SpawnBossBetter(Main.player[ClosestPlayerToWorldCenter].Top - new Vector2(42f, 84f), type);
|
||||
}, dimnessFactor: 0.6f, permittedNPCs: new int[] { ModContent.NPCType<SCalWormArm>(), ModContent.NPCType<SCalWormHead>(), ModContent.NPCType<SCalWormBody>(), ModContent.NPCType<SCalWormBodyWeak>(), ModContent.NPCType<SCalWormTail>(),
|
||||
ModContent.NPCType<SoulSeekerSupreme>(), ModContent.NPCType<BrimstoneHeart>(), ModContent.NPCType<SupremeCataclysm>(), ModContent.NPCType<SupremeCatastrophe>() }),
|
||||
@@ -304,7 +304,7 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Player player = Main.player[ClosestPlayerToWorldCenter];
|
||||
|
||||
SoundEngine.PlaySound(SoundLoader.GetLegacySoundSlot(CalamityMod.Instance, "Sounds/Custom/DevourerSpawn"), player.Center);
|
||||
SoundEngine.PlaySound(DevourerofGodsHead.SpawnSound, player.Center);
|
||||
NPC.SpawnOnPlayer(ClosestPlayerToWorldCenter, type);
|
||||
}, usesSpecialSound: true, permittedNPCs: new int[] { ModContent.NPCType<DevourerofGodsBody>(), ModContent.NPCType<DevourerofGodsTail>() })
|
||||
};
|
||||
@@ -461,7 +461,7 @@ namespace CalamityMod.Events
|
||||
|
||||
// Play the typical boss roar sound.
|
||||
if (!Bosses[BossRushStage].UsesSpecialSound)
|
||||
SoundEngine.PlaySound(SoundID.Roar, Main.player[ClosestPlayerToWorldCenter].position, 0);
|
||||
SoundEngine.PlaySound(SoundID.Roar, Main.player[ClosestPlayerToWorldCenter].position);
|
||||
|
||||
// And spawn the boss.
|
||||
Bosses[BossRushStage].SpawnContext.Invoke(CurrentlyFoughtBoss);
|
||||
|
||||
@@ -130,7 +130,7 @@ namespace CalamityMod.Gores
|
||||
gore.frameCounter = 0;
|
||||
if (gore.type != 716 && gore.type != 717 && gore.type != 943)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Drip, (int)gore.position.X + 8, (int)gore.position.Y + 8, Main.rand.Next(2), 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.Drip, gore.position + Vector2.One * 8);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -142,7 +142,7 @@ namespace CalamityMod.Gores
|
||||
gore.frameCounter = 0;
|
||||
if (gore.type != 716 && gore.type != 717 && gore.type != 943)
|
||||
{
|
||||
SoundEngine.PlaySound(SoundID.Drip, (int)gore.position.X + 8, (int)gore.position.Y + 8, 2, 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.Drip, gore.position + Vector2.One * 8);
|
||||
}
|
||||
((WaterShaderData)Filters.Scene["WaterDistortion"].GetShader()).QueueRipple(gore.position + new Vector2(8f, 8f), 1f, RippleShape.Square, 0f);
|
||||
}
|
||||
|
||||
@@ -107,6 +107,7 @@ namespace CalamityMod.ILEditing
|
||||
|
||||
// Fix vanilla bugs exposed by Calamity mechanics
|
||||
IL.Terraria.NPC.NPCLoot += FixSplittingWormBannerDrops;
|
||||
On.Terraria.Item.Prefix += LetRogueItemsBeReforgeable;
|
||||
// IL.Terraria.Main.DoUpdate += FixProjectileUpdatePriorityProblems;
|
||||
}
|
||||
|
||||
@@ -192,6 +193,7 @@ namespace CalamityMod.ILEditing
|
||||
// Fix vanilla bugs exposed by Calamity mechanics
|
||||
// On.Terraria.Main.InitLifeBytes -= BossRushLifeBytes;
|
||||
IL.Terraria.NPC.NPCLoot -= FixSplittingWormBannerDrops;
|
||||
On.Terraria.Item.Prefix -= LetRogueItemsBeReforgeable;
|
||||
// IL.Terraria.Main.DoUpdate -= FixProjectileUpdatePriorityProblems;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ namespace CalamityMod.ILEditing
|
||||
WorldGen.TileFrame(doorX, y);
|
||||
|
||||
// Play the door closing sound (lab doors do not use the door opening sound)
|
||||
SoundEngine.PlaySound(SoundID.DoorClosed, doorX * 16, doorY * 16);
|
||||
SoundEngine.PlaySound(SoundID.DoorClosed, new Vector2(doorX * 16, doorY * 16));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@ using Terraria;
|
||||
using Terraria.GameContent;
|
||||
using Terraria.GameInput;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.ILEditing
|
||||
{
|
||||
@@ -134,6 +135,19 @@ namespace CalamityMod.ILEditing
|
||||
}
|
||||
#endregion Fixing Splitting Worm Banner Spam in Deathmode
|
||||
|
||||
#region Let Rogue Items Be Reforgeable
|
||||
private static bool LetRogueItemsBeReforgeable(On.Terraria.Item.orig_Prefix orig, Item self, int pre)
|
||||
{
|
||||
if (self.CountsAsClass<RogueDamageClass>() && self.maxStack == 1 && pre == -3)
|
||||
{
|
||||
PrefixLoader.Roll(self, ref pre, 40, WorldGen.gen ? WorldGen.genRand : Main.rand, PrefixCategory.AnyWeapon);
|
||||
return true;
|
||||
}
|
||||
|
||||
return orig(self, pre);
|
||||
}
|
||||
#endregion Let Rogue Items Be Reforgeable
|
||||
|
||||
#region Fix Projectile Update Priority Problems
|
||||
|
||||
// This IL edit is commented out because it seems to be causing issues, sometimes creating errors preventing Terraria from updating
|
||||
|
||||
@@ -296,7 +296,7 @@ namespace CalamityMod.ILEditing
|
||||
cursor.EmitDelegate<Func<Projectile, int>>(projectile =>
|
||||
{
|
||||
int damage = (int)(Main.player[projectile.owner].ActiveItem().damage * BalancingConstants.FirecrackerExplosionDamageMultiplier);
|
||||
damage = (int)Main.player[projectile.owner].GetDamage(DamageClass.Summon).ApplyTo(damage);
|
||||
damage = (int)Main.player[projectile.owner].GetDamage<SummonDamageClass>().ApplyTo(damage);
|
||||
return damage;
|
||||
});
|
||||
cursor.Emit(OpCodes.Stloc, 64);
|
||||
|
||||
@@ -6,12 +6,15 @@ using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using System.Linq;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
//Developer item, dedicatee: Nincity
|
||||
public class AngelicAlliance : ModItem
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/AngelicAllianceActivation");
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
SacrificeTotal = 1;
|
||||
@@ -53,7 +56,7 @@ namespace CalamityMod.Items.Accessories
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.angelicAlliance = true;
|
||||
player.GetDamage<GenericDamageClass>() += 0.08f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.07f; //7% + 8% = 15%
|
||||
player.GetDamage<SummonDamageClass>() += 0.07f; //7% + 8% = 15%
|
||||
player.maxMinions += 2;
|
||||
if (player.controlJump)
|
||||
player.lifeRegen += 4;
|
||||
|
||||
@@ -28,8 +28,8 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
player.Calamity().artemisEmblem = true;
|
||||
player.Calamity().rangedAmmoCost *= 0.8f;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetDamage<RangedDamageClass>() += 0.1f;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -29,8 +29,8 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.15f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetDamage<RangedDamageClass>() += 0.15f;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
player.magicQuiver = true;
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.artemisEmblem = true;
|
||||
|
||||
@@ -38,9 +38,9 @@ namespace CalamityMod.Items.Accessories
|
||||
player.manaFlower = true;
|
||||
|
||||
player.statManaMax2 += 150;
|
||||
player.GetDamage(DamageClass.Magic) += 0.15f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.15f;
|
||||
player.manaCost *= 0.9f;
|
||||
player.GetCritChance(DamageClass.Magic) += 5;
|
||||
player.GetCritChance<MagicDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
player.Calamity().voltaicJelly = true;
|
||||
player.Calamity().jellyChargedBattery = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.07f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.07f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace CalamityMod.Items.Accessories
|
||||
modPlayer.voltaicJelly = true; //electrified
|
||||
modPlayer.starTaintedGenerator = true; //astral infection and irradiated
|
||||
player.GetKnockback<SummonDamageClass>() += 3f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.15f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.15f;
|
||||
player.buffImmune[ModContent.BuffType<Shadowflame>()] = true;
|
||||
player.buffImmune[ModContent.BuffType<Irradiated>()] = true;
|
||||
}
|
||||
|
||||
@@ -31,8 +31,8 @@ namespace CalamityMod.Items.Accessories
|
||||
player.shroomiteStealth = true;
|
||||
player.GetDamage<ThrowingDamageClass>() += 0.05f;
|
||||
player.GetCritChance<ThrowingDamageClass>() += 5;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.05f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetDamage<RangedDamageClass>() += 0.05f;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -141,7 +141,7 @@ namespace CalamityMod.Items.Accessories
|
||||
fx.MaxUpdates = 2; // Make the animation play at double speed.
|
||||
|
||||
// Play a weird dimensional lightning sound simultaneously.
|
||||
var extraSound = SoundID.DD2_EtherianPortalDryadTouch.WithVolume(1.4f);
|
||||
var extraSound = SoundID.DD2_EtherianPortalDryadTouch with { Volume = SoundID.DD2_EtherianPortalDryadTouch.Volume * 1.4f };
|
||||
SoundEngine.PlaySound(extraSound, player.Center);
|
||||
|
||||
// Display a level up text notification.
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
player.manaMagnet = true;
|
||||
player.statManaMax2 += 100;
|
||||
player.GetDamage(DamageClass.Magic) += 0.15f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.15f;
|
||||
player.manaCost *= 0.9f;
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Items.Accessories
|
||||
player.Calamity().voltaicJelly = true;
|
||||
player.Calamity().starbusterCore = true;
|
||||
player.Calamity().starTaintedGenerator = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.07f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.07f;
|
||||
player.buffImmune[ModContent.BuffType<Irradiated>()] = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Items.Accessories
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.holyMinions = true;
|
||||
player.GetKnockback<SummonDamageClass>() += 2.5f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace CalamityMod.Items.Accessories
|
||||
modPlayer.shadowMinions = true;
|
||||
modPlayer.holyMinions = true;
|
||||
player.GetKnockback<SummonDamageClass>() += 2.75f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
player.buffImmune[ModContent.BuffType<Shadowflame>()] = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
else if (melee)
|
||||
{
|
||||
player.GetAttackSpeed(DamageClass.Melee) += 0.1f;
|
||||
player.GetAttackSpeed<MeleeDamageClass>() += 0.1f;
|
||||
player.AddBuff(BuffID.Sharpened, 60, true);
|
||||
}
|
||||
else if (ranged)
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.07f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.07f;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,12 +44,12 @@ namespace CalamityMod.Items.Armor
|
||||
modPlayer.aeroSet = true;
|
||||
player.noFallDmg = true;
|
||||
player.moveSpeed += 0.05f;
|
||||
player.GetCritChance(DamageClass.Magic) += 5;
|
||||
player.GetCritChance<MagicDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Magic) += 0.08f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.08f;
|
||||
player.statManaMax2 += 20;
|
||||
}
|
||||
|
||||
|
||||
@@ -45,13 +45,13 @@ namespace CalamityMod.Items.Armor
|
||||
modPlayer.aeroSet = true;
|
||||
player.noFallDmg = true;
|
||||
player.moveSpeed += 0.05f;
|
||||
player.GetCritChance(DamageClass.Melee) += 5;
|
||||
player.GetCritChance<MeleeDamageClass>() += 5;
|
||||
player.aggro += 300;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.08f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.08f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -62,14 +62,14 @@ namespace CalamityMod.Items.Armor
|
||||
Main.projectile[p].originalDamage = 20;
|
||||
}
|
||||
}
|
||||
player.GetDamage(DamageClass.Summon) += 0.11f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.11f;
|
||||
player.maxMinions++;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.moveSpeed += 0.05f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -44,12 +44,12 @@ namespace CalamityMod.Items.Armor
|
||||
modPlayer.aeroSet = true;
|
||||
player.noFallDmg = true;
|
||||
player.moveSpeed += 0.05f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.08f;
|
||||
player.GetDamage<RangedDamageClass>() += 0.08f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -46,14 +46,14 @@ namespace CalamityMod.Items.Armor
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.ataxiaBlaze = true;
|
||||
modPlayer.ataxiaBolt = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.05f;
|
||||
player.GetDamage<RangedDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.ammoCost75 = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.12f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 10;
|
||||
player.GetDamage<RangedDamageClass>() += 0.12f;
|
||||
player.GetCritChance<RangedDamageClass>() += 10;
|
||||
player.lavaMax += 240;
|
||||
player.buffImmune[BuffID.OnFire] = true;
|
||||
}
|
||||
|
||||
@@ -49,7 +49,7 @@ namespace CalamityMod.Items.Armor
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.ataxiaBlaze = true;
|
||||
modPlayer.ataxiaGeyser = true;
|
||||
player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
player.aggro += 700;
|
||||
}
|
||||
|
||||
@@ -57,9 +57,9 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.ataxiaFire = true;
|
||||
player.GetAttackSpeed(DamageClass.Melee) += 0.18f;
|
||||
player.GetDamage(DamageClass.Melee) += 0.12f;
|
||||
player.GetCritChance(DamageClass.Melee) += 10;
|
||||
player.GetAttackSpeed<MeleeDamageClass>() += 0.18f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.12f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 10;
|
||||
player.lavaMax += 240;
|
||||
player.buffImmune[BuffID.OnFire] = true;
|
||||
}
|
||||
|
||||
@@ -63,13 +63,13 @@ namespace CalamityMod.Items.Armor
|
||||
Main.projectile[p].originalDamage = 190;
|
||||
}
|
||||
}
|
||||
player.GetDamage(DamageClass.Summon) += 0.4f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.4f;
|
||||
player.maxMinions += 2;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
player.GetKnockback<SummonDamageClass>() += 1.5f;
|
||||
player.lavaMax += 240;
|
||||
player.buffImmune[BuffID.OnFire] = true;
|
||||
|
||||
@@ -46,15 +46,15 @@ namespace CalamityMod.Items.Armor
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.ataxiaBlaze = true;
|
||||
modPlayer.ataxiaMage = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
player.manaCost *= 0.85f;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.statManaMax2 += 100;
|
||||
player.GetDamage(DamageClass.Magic) += 0.12f;
|
||||
player.GetCritChance(DamageClass.Magic) += 10;
|
||||
player.GetDamage<MagicDamageClass>() += 0.12f;
|
||||
player.GetCritChance<MagicDamageClass>() += 10;
|
||||
player.lavaMax += 240;
|
||||
player.buffImmune[BuffID.OnFire] = true;
|
||||
}
|
||||
|
||||
@@ -65,8 +65,8 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.auricBoost = true;
|
||||
player.GetDamage(DamageClass.Melee) += 0.2f;
|
||||
player.GetCritChance(DamageClass.Melee) += 20;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.2f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 20;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -63,8 +63,8 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.auricBoost = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.3f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 30;
|
||||
player.GetDamage<RangedDamageClass>() += 0.3f;
|
||||
player.GetCritChance<RangedDamageClass>() += 30;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -58,7 +58,7 @@ namespace CalamityMod.Items.Armor
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
player.crimsonRegen = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.75f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.75f;
|
||||
player.maxMinions += 6;
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
@@ -81,7 +81,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.auricBoost = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.15f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.15f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -61,8 +61,8 @@ namespace CalamityMod.Items.Armor
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.auricBoost = true;
|
||||
player.manaCost *= 0.8f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.3f;
|
||||
player.GetCritChance(DamageClass.Magic) += 20;
|
||||
player.GetDamage<MagicDamageClass>() += 0.3f;
|
||||
player.GetCritChance<MagicDamageClass>() += 20;
|
||||
player.statManaMax2 += 100;
|
||||
}
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ namespace CalamityMod.Items.Armor
|
||||
"At 90% life and above you gain 10% increased minion damage\n" +
|
||||
"At 50% life and below you gain 20 defense and 2 life regen";
|
||||
player.crimsonRegen = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.5f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.5f;
|
||||
player.maxMinions += 3;
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -4,12 +4,15 @@ using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using System.Linq;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Armor
|
||||
{
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class BloodflareHornedHelm : ModItem
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/BloodflareRangerActivation");
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
SacrificeTotal = 1;
|
||||
@@ -57,8 +60,8 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 10;
|
||||
player.GetDamage<RangedDamageClass>() += 0.1f;
|
||||
player.GetCritChance<RangedDamageClass>() += 10;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -55,8 +55,8 @@ namespace CalamityMod.Items.Armor
|
||||
player.manaCost *= 0.83f;
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.2f;
|
||||
player.GetCritChance(DamageClass.Magic) += 10;
|
||||
player.GetDamage<MagicDamageClass>() += 0.2f;
|
||||
player.GetCritChance<MagicDamageClass>() += 10;
|
||||
player.statManaMax2 += 100;
|
||||
}
|
||||
|
||||
|
||||
@@ -58,8 +58,8 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Melee) += 10;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 10;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.moveSpeed += 0.05f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
player.fireWalk = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,8 +27,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetCritChance(DamageClass.Magic) += 5;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
player.GetCritChance<MagicDamageClass>() += 5;
|
||||
player.lavaRose = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -12,6 +12,8 @@ namespace CalamityMod.Items.Armor
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class BrimflameScowl : ModItem
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/AngelicAllianceActivation");
|
||||
|
||||
private bool frenzy = false;
|
||||
public static int CooldownLength = 1800;
|
||||
|
||||
@@ -53,8 +55,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetCritChance(DamageClass.Magic) += 5;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
player.GetCritChance<MagicDamageClass>() += 5;
|
||||
player.statManaMax2 += 70;
|
||||
player.manaCost *= 0.9f;
|
||||
player.buffImmune[ModContent.BuffType<BrimstoneFlames>()] = true;
|
||||
@@ -77,8 +79,8 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.brimflameSet = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.15f;
|
||||
player.GetCritChance(DamageClass.Magic) += 15;
|
||||
player.GetDamage<MagicDamageClass>() += 0.15f;
|
||||
player.GetCritChance<MagicDamageClass>() += 15;
|
||||
string hotkey = CalamityKeybinds.SetBonusHotKey.TooltipHotkeyString();
|
||||
player.setBonus = "Grants an additional 15% increased magic damage and crit\n" +
|
||||
"Press " + hotkey + " to trigger a brimflame frenzy effect\n" +
|
||||
|
||||
@@ -48,8 +48,8 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.Calamity().cirrusDress = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetCritChance(DamageClass.Magic) += 5;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
player.GetCritChance<MagicDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void SetMatch(bool male, ref int equipSlot, ref bool robes)
|
||||
|
||||
@@ -44,14 +44,14 @@ namespace CalamityMod.Items.Armor
|
||||
"If you absorb an attack you are healed for 1/2 of that attack's damage";
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.daedalusAbsorb = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.05f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.manaCost *= 0.9f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.13f;
|
||||
player.GetCritChance(DamageClass.Magic) += 7;
|
||||
player.GetDamage<MagicDamageClass>() += 0.13f;
|
||||
player.GetCritChance<MagicDamageClass>() += 7;
|
||||
player.statManaMax2 += 60;
|
||||
}
|
||||
|
||||
|
||||
@@ -59,13 +59,13 @@ namespace CalamityMod.Items.Armor
|
||||
p.originalDamage = 95;
|
||||
}
|
||||
}
|
||||
player.GetDamage(DamageClass.Summon) += 0.2f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.2f;
|
||||
player.maxMinions += 2;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -46,15 +46,15 @@ namespace CalamityMod.Items.Armor
|
||||
"This reflect has a 90 second cooldown which is shared with all other dodges and reflects";
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.daedalusReflect = true;
|
||||
player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
player.aggro += 500;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetAttackSpeed(DamageClass.Melee) += 0.15f;
|
||||
player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Melee) += 10;
|
||||
player.GetAttackSpeed<MeleeDamageClass>() += 0.15f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 10;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -43,14 +43,14 @@ namespace CalamityMod.Items.Armor
|
||||
"Getting hit causes you to emit a blast of crystal shards";
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.daedalusShard = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.05f;
|
||||
player.GetDamage<RangedDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.ammoCost80 = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.13f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 7;
|
||||
player.GetDamage<RangedDamageClass>() += 0.13f;
|
||||
player.GetCritChance<RangedDamageClass>() += 7;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -38,7 +38,7 @@ namespace CalamityMod.Items.Armor
|
||||
player.statManaMax2 += 200;
|
||||
player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
player.GetCritChance<GenericDamageClass>() += 15;
|
||||
player.GetAttackSpeed(DamageClass.Melee) += 0.2f;
|
||||
player.GetAttackSpeed<MeleeDamageClass>() += 0.2f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -8,12 +8,15 @@ using Terraria;
|
||||
using Terraria.ModLoader;
|
||||
using System.Linq;
|
||||
using Terraria.DataStructures;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Armor
|
||||
{
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class DemonshadeHelm : ModItem, IExtendedHat
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/DemonshadeEnrage");
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
SacrificeTotal = 1;
|
||||
@@ -71,7 +74,7 @@ namespace CalamityMod.Items.Armor
|
||||
devil.originalDamage = baseDamage;
|
||||
}
|
||||
}
|
||||
player.GetDamage(DamageClass.Summon) += 1f;
|
||||
player.GetDamage<SummonDamageClass>() += 1f;
|
||||
player.maxMinions += 10;
|
||||
}
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetCritChance(DamageClass.Ranged) += 4;
|
||||
player.GetCritChance<RangedDamageClass>() += 4;
|
||||
player.ammoCost80 = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.04f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.04f;
|
||||
if (Collision.DrownCollision(player.position, player.width, player.height, player.gravDir))
|
||||
{
|
||||
player.moveSpeed += 0.4f;
|
||||
|
||||
@@ -30,7 +30,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.06f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.06f;
|
||||
player.endurance += 0.06f;
|
||||
if (Collision.DrownCollision(player.position, player.width, player.height, player.gravDir))
|
||||
{
|
||||
|
||||
@@ -42,17 +42,17 @@ namespace CalamityMod.Items.Armor
|
||||
modPlayer.fathomSwarmer = true;
|
||||
player.spikedBoots = 2;
|
||||
player.maxMinions += 2;
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
if (Collision.DrownCollision(player.position, player.width, player.height, player.gravDir))
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.3f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.3f;
|
||||
}
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
if (player.breath <= player.breathMax + 2 && !modPlayer.ZoneAbyss)
|
||||
{
|
||||
player.breath = player.breathMax + 3;
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.statManaMax2 += 60;
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
player.manaCost *= 0.9f;
|
||||
}
|
||||
|
||||
@@ -61,7 +61,7 @@ namespace CalamityMod.Items.Armor
|
||||
// All-class armors count as rogue sets, but don't grant stealth bonuses
|
||||
player.Calamity().wearingRogueArmor = true;
|
||||
player.Calamity().WearingPostMLSummonerSet = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.2f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.2f;
|
||||
player.maxMinions += 2;
|
||||
|
||||
int[] immuneDebuffs = {
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
player.Calamity().rogueVelocity += 0.15f;
|
||||
}
|
||||
|
||||
|
||||
@@ -63,8 +63,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.14f;
|
||||
player.GetCritChance(DamageClass.Melee) += 14;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.14f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 14;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -58,8 +58,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.14f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 14;
|
||||
player.GetDamage<RangedDamageClass>() += 0.14f;
|
||||
player.GetCritChance<RangedDamageClass>() += 14;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -7,12 +7,16 @@ using Terraria.ModLoader;
|
||||
using CalamityMod.CalPlayer;
|
||||
using CalamityMod.Cooldowns;
|
||||
using System.Linq;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Armor
|
||||
{
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class OmegaBlueHelmet : ModItem
|
||||
{
|
||||
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/OmegaBlueAbility);
|
||||
|
||||
public override void Load()
|
||||
{
|
||||
if (Main.netMode != NetmodeID.Server)
|
||||
|
||||
@@ -6,12 +6,15 @@ using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using System.Linq;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Armor
|
||||
{
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class PlagueReaperMask : ModItem
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/PlagueReaperAbility");
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
SacrificeTotal = 1;
|
||||
@@ -57,8 +60,8 @@ namespace CalamityMod.Items.Armor
|
||||
player.blind = true;
|
||||
player.headcovered = true;
|
||||
player.blackout = true;
|
||||
player.GetDamage(DamageClass.Ranged) += 0.6f; //60% ranged dmg and 20% crit
|
||||
player.GetCritChance(DamageClass.Ranged) += 20;
|
||||
player.GetDamage<RangedDamageClass>() += 0.6f; //60% ranged dmg and 20% crit
|
||||
player.GetCritChance<RangedDamageClass>() += 20;
|
||||
}
|
||||
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
@@ -79,8 +82,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 8;
|
||||
player.GetDamage<RangedDamageClass>() += 0.1f;
|
||||
player.GetCritChance<RangedDamageClass>() += 8;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetCritChance(DamageClass.Ranged) += 3;
|
||||
player.GetCritChance<RangedDamageClass>() += 3;
|
||||
player.moveSpeed += 0.15f;
|
||||
}
|
||||
|
||||
|
||||
@@ -28,8 +28,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.15f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 5;
|
||||
player.GetDamage<RangedDamageClass>() += 0.15f;
|
||||
player.GetCritChance<RangedDamageClass>() += 5;
|
||||
player.buffImmune[ModContent.BuffType<Plague>()] = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.Calamity().plaguebringerCarapace = true;
|
||||
player.GetDamage(DamageClass.Summon) += 0.12f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.12f;
|
||||
player.buffImmune[ModContent.BuffType<Plague>()] = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.13f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.13f;
|
||||
player.moveSpeed += 0.15f;
|
||||
player.Calamity().plaguebringerPistons = true;
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Summon) += 0.15f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.15f;
|
||||
player.statLifeMax2 += 20;
|
||||
}
|
||||
|
||||
|
||||
@@ -32,11 +32,11 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.Calamity().prismaticGreaves = true;
|
||||
player.GetDamage(DamageClass.Magic) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Magic) += 12;
|
||||
player.GetDamage<MagicDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MagicDamageClass>() += 12;
|
||||
player.jumpSpeedBoost += 0.1f;
|
||||
player.GetDamage<GenericDamageClass>() -= 0.2f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.2f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.2f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -59,9 +59,9 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
player.Calamity().prismaticHelmet = true;
|
||||
player.GetDamage<GenericDamageClass>() -= 0.2f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.2f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.18f;
|
||||
player.GetCritChance(DamageClass.Magic) += 12;
|
||||
player.GetDamage<MagicDamageClass>() += 0.2f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.18f;
|
||||
player.GetCritChance<MagicDamageClass>() += 12;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -35,10 +35,10 @@ namespace CalamityMod.Items.Armor
|
||||
player.Calamity().prismaticRegalia = true;
|
||||
player.statLifeMax2 += 20;
|
||||
player.statManaMax2 += 40;
|
||||
player.GetDamage(DamageClass.Magic) += 0.12f;
|
||||
player.GetCritChance(DamageClass.Magic) += 15;
|
||||
player.GetDamage<MagicDamageClass>() += 0.12f;
|
||||
player.GetCritChance<MagicDamageClass>() += 15;
|
||||
player.GetDamage<GenericDamageClass>() -= 0.2f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.2f;
|
||||
player.GetDamage<MagicDamageClass>() += 0.2f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -7,12 +7,16 @@ using CalamityMod.Tiles.Furniture.CraftingStations;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using Terraria.Audio;
|
||||
|
||||
namespace CalamityMod.Items.Armor
|
||||
{
|
||||
[AutoloadEquip(EquipType.Head)]
|
||||
public class SilvaHelmet : ModItem
|
||||
{
|
||||
public static readonly SoundStyle ActivationSound = new("CalamityMod/Sounds/Custom/AbilitySounds/SilvaActivation");
|
||||
public static readonly SoundStyle DispelSound = new("CalamityMod/Sounds/Custom/AbilitySounds/SilvaDispel");
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
SacrificeTotal = 1;
|
||||
@@ -67,11 +71,11 @@ namespace CalamityMod.Items.Armor
|
||||
Main.projectile[p].originalDamage = 600;
|
||||
}
|
||||
}
|
||||
player.GetDamage(DamageClass.Summon) += 0.65f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.65f;
|
||||
player.maxMinions += 5;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player) => player.GetDamage(DamageClass.Summon) += 0.1f;
|
||||
public override void UpdateEquip(Player player) => player.GetDamage<SummonDamageClass>() += 0.1f;
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
|
||||
@@ -54,8 +54,8 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.manaCost *= 0.81f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.23f;
|
||||
player.GetCritChance(DamageClass.Magic) += 13;
|
||||
player.GetDamage<MagicDamageClass>() += 0.23f;
|
||||
player.GetCritChance<MagicDamageClass>() += 13;
|
||||
player.statManaMax2 += 100;
|
||||
}
|
||||
|
||||
|
||||
@@ -46,8 +46,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Magic) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Magic) += 7;
|
||||
player.GetDamage<MagicDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MagicDamageClass>() += 7;
|
||||
player.manaCost *= 0.9f;
|
||||
player.statManaMax2 += 30;
|
||||
}
|
||||
|
||||
@@ -46,8 +46,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 7;
|
||||
player.GetDamage<RangedDamageClass>() += 0.1f;
|
||||
player.GetCritChance<RangedDamageClass>() += 7;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -48,9 +48,9 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Melee) += 7;
|
||||
player.GetAttackSpeed(DamageClass.Melee) += 0.1f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 7;
|
||||
player.GetAttackSpeed<MeleeDamageClass>() += 0.1f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
@@ -3,6 +3,7 @@ using CalamityMod.CalPlayer;
|
||||
using CalamityMod.Items.Materials;
|
||||
using CalamityMod.Projectiles.Summon;
|
||||
using CalamityMod.Tiles.Furniture.CraftingStations;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
@@ -46,7 +47,7 @@ namespace CalamityMod.Items.Armor
|
||||
modPlayer.statigelJump = true;
|
||||
Player.jumpHeight += 5;
|
||||
player.jumpSpeedBoost += 0.6f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.18f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.18f;
|
||||
player.maxMinions++;
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
@@ -55,14 +56,17 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
player.AddBuff(ModContent.BuffType<StatigelSummonSetBuff>(), 3600, true);
|
||||
}
|
||||
|
||||
int minionID = -1;
|
||||
int baseDamage = 33;
|
||||
int minionDamage = (int)player.GetDamage<GenericDamageClass>().CombineWith(player.GetDamage<SummonDamageClass>()).ApplyTo(baseDamage);
|
||||
if (WorldGen.crimson && player.ownedProjectileCounts[ModContent.ProjectileType<CrimsonSlimeGodMinion>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(source, player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<CrimsonSlimeGodMinion>(), (int)(33f * (player.GetDamage<GenericDamageClass>().Base + player.GetDamage(DamageClass.Summon).Base - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
}
|
||||
minionID = Projectile.NewProjectile(source, player.Center, -Vector2.UnitY, ModContent.ProjectileType<CrimsonSlimeGodMinion>(), minionDamage, 0f, Main.myPlayer);
|
||||
else if (!WorldGen.crimson && player.ownedProjectileCounts[ModContent.ProjectileType<CorruptionSlimeGodMinion>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(source, player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<CorruptionSlimeGodMinion>(), (int)(33f * (player.GetDamage<GenericDamageClass>().Base + player.GetDamage(DamageClass.Summon).Base - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
}
|
||||
minionID = Projectile.NewProjectile(source, player.Center, -Vector2.UnitY, ModContent.ProjectileType<CorruptionSlimeGodMinion>(), minionDamage, 0f, Main.myPlayer);
|
||||
|
||||
if (Main.projectile.IndexInRange(minionID))
|
||||
Main.projectile[minionID].originalDamage = baseDamage;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -58,8 +58,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Melee) += 10;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
player.GetCritChance<MeleeDamageClass>() += 10;
|
||||
player.endurance += 0.05f;
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
|
||||
@@ -49,14 +49,14 @@ namespace CalamityMod.Items.Armor
|
||||
"Increased heart pickup range\n" +
|
||||
"Enemies have a chance to drop extra hearts on death\n" +
|
||||
"Summons a life aura around you that damages nearby enemies";
|
||||
player.GetDamage(DamageClass.Summon) += 0.5f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.5f;
|
||||
player.maxMinions += 3;
|
||||
}
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.endurance += 0.05f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.05f;
|
||||
player.GetDamage<SummonDamageClass>() += 0.05f;
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
}
|
||||
|
||||
@@ -55,8 +55,8 @@ namespace CalamityMod.Items.Armor
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.manaCost *= 0.85f;
|
||||
player.GetDamage(DamageClass.Magic) += 0.2f;
|
||||
player.GetCritChance(DamageClass.Magic) += 10;
|
||||
player.GetDamage<MagicDamageClass>() += 0.2f;
|
||||
player.GetCritChance<MagicDamageClass>() += 10;
|
||||
player.endurance += 0.05f;
|
||||
player.lavaMax += 240;
|
||||
player.statManaMax2 += 100;
|
||||
|
||||
@@ -52,8 +52,8 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Ranged) += 0.1f;
|
||||
player.GetCritChance(DamageClass.Ranged) += 10;
|
||||
player.GetDamage<RangedDamageClass>() += 0.1f;
|
||||
player.GetCritChance<RangedDamageClass>() += 10;
|
||||
player.endurance += 0.05f;
|
||||
player.lavaMax += 240;
|
||||
player.ignoreWater = true;
|
||||
|
||||
@@ -42,7 +42,7 @@ namespace CalamityMod.Items.Armor
|
||||
player.ignoreWater = true;
|
||||
if (Collision.DrownCollision(player.position, player.width, player.height, player.gravDir))
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.1f;
|
||||
player.lifeRegen += 3;
|
||||
}
|
||||
player.aggro += 200;
|
||||
@@ -50,7 +50,7 @@ namespace CalamityMod.Items.Armor
|
||||
|
||||
public override void UpdateEquip(Player player)
|
||||
{
|
||||
player.GetDamage(DamageClass.Melee) += 0.05f;
|
||||
player.GetDamage<MeleeDamageClass>() += 0.05f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
|
||||
Loaded 100 of 533 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user