diff --git a/Cooldowns/LunicCorpsShieldCooldowns.cs b/Cooldowns/LunicCorpsShieldCooldowns.cs index dbee30e4a1..f76d74cd33 100644 --- a/Cooldowns/LunicCorpsShieldCooldowns.cs +++ b/Cooldowns/LunicCorpsShieldCooldowns.cs @@ -92,11 +92,19 @@ namespace CalamityMod.Cooldowns public override SoundStyle? EndSound => LunicCorpsHelmet.ActivationSound; public override bool ShouldPlayEndSound => instance.player.Calamity().lunicCorpsSet; - public override void Tick() => instance.player.Calamity().playedLunicCorpsShieldSound = false; - // When the recharge period completes, grant 1 point of shielding immediately so the rest my refill normally. + public override void Tick() + { + if (instance.player.whoAmI == Main.myPlayer) + instance.player.Calamity().playedLunicCorpsShieldSound = false; + } + + // When the recharge period completes, grant 1 point of shielding immediately so the rest may refill normally. // The shield durability cooldown is added elsewhere, in Misc Effects. public override void OnCompleted() { + if (instance.player.whoAmI != Main.myPlayer) + return; + CalamityPlayer modPlayer = instance.player.Calamity(); if (modPlayer.LunicCorpsShieldDurability <= 0) modPlayer.LunicCorpsShieldDurability = 1; diff --git a/Cooldowns/ProfanedSoulShield.cs b/Cooldowns/ProfanedSoulShield.cs index c209dc63ad..c073f45bce 100644 --- a/Cooldowns/ProfanedSoulShield.cs +++ b/Cooldowns/ProfanedSoulShield.cs @@ -109,16 +109,23 @@ namespace CalamityMod.Cooldowns public override Color CooldownStartColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override Color CooldownEndColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); - public override void Tick() => instance.player.Calamity().playedProfanedSoulShieldSound = false; + public override void Tick() + { + if (instance.player.whoAmI == Main.myPlayer) + instance.player.Calamity().playedProfanedSoulShieldSound = false; + } public override SoundStyle? EndSound => Providence.BurnStartSound; public override bool ShouldPlayEndSound => instance.player.Calamity().pSoulArtifact; - // When the recharge period completes, grant 1 point of shielding immediately so the rest my refill normally. + // When the recharge period completes, grant 1 point of shielding immediately so the rest may refill normally. // The shield durability cooldown is added elsewhere, in Misc Effects. public override void OnCompleted() { + if (instance.player.whoAmI != Main.myPlayer) + return; + CalamityPlayer modPlayer = instance.player.Calamity(); if (modPlayer.pSoulShieldDurability <= 0) modPlayer.pSoulShieldDurability = 1; diff --git a/Cooldowns/SpongeCooldowns.cs b/Cooldowns/SpongeCooldowns.cs index b9429b1bac..f2820fdaae 100644 --- a/Cooldowns/SpongeCooldowns.cs +++ b/Cooldowns/SpongeCooldowns.cs @@ -92,11 +92,19 @@ namespace CalamityMod.Cooldowns public override SoundStyle? EndSound => TheSponge.ActivationSound; public override bool ShouldPlayEndSound => instance.player.Calamity().sponge; - public override void Tick() => instance.player.Calamity().playedSpongeShieldSound = false; - // When the recharge period completes, grant 1 point of shielding immediately so the rest my refill normally. + public override void Tick() + { + if (instance.player.whoAmI == Main.myPlayer) + instance.player.Calamity().playedSpongeShieldSound = false; + } + + // When the recharge period completes, grant 1 point of shielding immediately so the rest may refill normally. // The shield durability cooldown is added elsewhere, in Misc Effects. public override void OnCompleted() { + if (instance.player.whoAmI != Main.myPlayer) + return; + CalamityPlayer modPlayer = instance.player.Calamity(); if (modPlayer.SpongeShieldDurability <= 0) modPlayer.SpongeShieldDurability = 1; diff --git a/Cooldowns/WulfrumRoverDriveCooldowns.cs b/Cooldowns/WulfrumRoverDriveCooldowns.cs index 9df995f04a..c34f48f527 100644 --- a/Cooldowns/WulfrumRoverDriveCooldowns.cs +++ b/Cooldowns/WulfrumRoverDriveCooldowns.cs @@ -91,11 +91,18 @@ namespace CalamityMod.Cooldowns public override Color CooldownStartColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); public override Color CooldownEndColor => Color.Lerp(ringColorLerpStart, ringColorLerpEnd, instance.Completion); - public override void Tick() => instance.player.Calamity().playedRoverDriveShieldSound = false; + public override void Tick() + { + if (instance.player.whoAmI == Main.myPlayer) + instance.player.Calamity().playedRoverDriveShieldSound = false; + } // Rover Drive shields are recharged as a side effect of the cooldown completing client side public override void OnCompleted() { + if (instance.player.whoAmI != Main.myPlayer) + return; + CalamityPlayer modPlayer = instance.player.Calamity(); if (modPlayer.RoverDriveShieldDurability <= 0) modPlayer.RoverDriveShieldDurability = 1;