diff --git a/Changes/BossKillListener.cs b/Changes/BossKillListener.cs index b3a580f..2f274e5 100644 --- a/Changes/BossKillListener.cs +++ b/Changes/BossKillListener.cs @@ -1,6 +1,9 @@ using System.Collections.Generic; using CalamityMod.NPCs.Crabulon; using CalamityMod.NPCs.DesertScourge; +using CalamityMod.NPCs.HiveMind; +using CalamityMod.NPCs.Perforator; +using CalamityMod.NPCs.SlimeGod; using Microsoft.Xna.Framework; using Terraria; using Terraria.Chat; @@ -29,9 +32,12 @@ public class BossKillListener : GlobalNPC { if (ModLoader.HasMod("CalamityMod")) { BossIds.Add(ModContent.NPCType(), "desert_scourge"); BossIds.Add(ModContent.NPCType(), "crabulon"); + BossIds.Add(ModContent.NPCType(), "perforators"); + BossIds.Add(ModContent.NPCType(), "hive_mind"); + BossIds.Add(ModContent.NPCType(), "slime_god"); } } - + public override void OnKill(NPC npc) { string id = BossIds.GetValueOrDefault(npc.type, null); switch (id) { diff --git a/Changes/SummonerOnHitEffects.cs b/Changes/SummonerOnHitEffects.cs index 442e000..892ac91 100644 --- a/Changes/SummonerOnHitEffects.cs +++ b/Changes/SummonerOnHitEffects.cs @@ -20,7 +20,7 @@ public class SummonerOnHitEffects : GlobalProjectile { && Main.rand.NextBool(10) ) { modPlayer.SummonerAmbitionDeerclopsCooldown = 5 * 60; - Vector2 direction = new Vector2(Main.rand.NextFloat(-1f, 1f), Main.rand.NextFloat(-1f, 1f)); + Vector2 direction = new(Main.rand.NextFloat(-1f, 1f), Main.rand.NextFloat(-1f, 1f)); direction.Normalize(); direction *= Main.rand.NextFloat(4f, 8f); Projectile.NewProjectile( @@ -41,7 +41,7 @@ public class SummonerOnHitEffects : GlobalProjectile { } // Whips - if (ProjectileID.Sets.IsAWhip[projectile.type]) { + if (modPlayer.SummonerAmbition && ProjectileID.Sets.IsAWhip[projectile.type]) { if (modPlayer.SummonerAmbitions.Contains("eye_of_cthulhu")) { projectile.damage = (int)(projectile.damage * 1.1); } diff --git a/Items/SummonersAmbition.cs b/Items/SummonersAmbition.cs index 1c397dd..d139b1f 100644 --- a/Items/SummonersAmbition.cs +++ b/Items/SummonersAmbition.cs @@ -36,10 +36,14 @@ public class SummonersAmbition : ModItem { player.GetSummonersAmbitionMinionBonus()))); if (player.SummonerAmbitions.Contains("king_slime")) { + int bonus = 20; + if (ModLoader.HasMod("CalamityMod")) { + bonus = 10; + } tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionKingSlime", - Language.GetTextValue("Mods.YHTMod.Items.SummonersAmbition.KingSlime"))); + Language.GetTextValue("Mods.YHTMod.Items.SummonersAmbition.KingSlime", bonus))); } - + if (ModLoader.HasMod("CalamityMod") && player.SummonerAmbitions.Contains("desert_scourge")) { int id = ModContent.ItemType(); tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionDesertScourge", @@ -50,7 +54,7 @@ public class SummonersAmbition : ModItem { tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionEyeOfCthulhu", Language.GetTextValue("Mods.YHTMod.Items.SummonersAmbition.EyeOfCthulhu"))); } - + if (ModLoader.HasMod("CalamityMod") && player.SummonerAmbitions.Contains("crabulon")) { int id = ModContent.ItemType(); tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionCrabulon", @@ -86,6 +90,12 @@ public class SummonersAmbition : ModItem { tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionWallOfFlesh", Language.GetTextValue("Mods.YHTMod.Items.SummonersAmbition.WallOfFlesh"))); } + + if (ModLoader.HasMod("CalamityMod") && player.SummonerAmbitions.Contains("slime_god")) { + int id = ModContent.ItemType(); + tooltips.Add(new TooltipLine(Mod, "SummonerAmbitionSlimeGod", + Language.GetTextValue("Mods.YHTMod.Items.SummonersAmbition.SlimeGod", "[i:" + id + "]"))); + } } public override void AddRecipes() { @@ -102,7 +112,8 @@ public class SummonersAmbition : ModItem { return modPlayer.SummonerAmbitions.Contains("king_slime") && modPlayer.SummonerAmbitions.Contains("eye_of_cthulhu") && modPlayer.SummonerAmbitions.Contains("deerclops") - && (modPlayer.SummonerAmbitions.Contains("eater_of_worlds") || modPlayer.SummonerAmbitions.Contains("brain_of_cthulhu")) + && (modPlayer.SummonerAmbitions.Contains("eater_of_worlds") || + modPlayer.SummonerAmbitions.Contains("brain_of_cthulhu")) && modPlayer.SummonerAmbitions.Contains("queen_bee") && modPlayer.SummonerAmbitions.Contains("skeletron") && modPlayer.SummonerAmbitions.Contains("wall_of_flesh"); diff --git a/Localization/en-US_Mods.YHTMod.hjson b/Localization/en-US_Mods.YHTMod.hjson index 4cff70c..555c0d5 100644 --- a/Localization/en-US_Mods.YHTMod.hjson +++ b/Localization/en-US_Mods.YHTMod.hjson @@ -21,11 +21,11 @@ Buffs: { ShroomGlowDebuff: { DisplayName: Shroom Glow - Description: - ''' - You are emitting a faint glow... - And smell like mushrooms. - ''' + Description: + ''' + You are emitting a faint glow... + And smell like mushrooms. + ''' } } @@ -82,7 +82,7 @@ Items: { "For those who seek to lead." {$CommonItemTooltip.IncreasesMaxMinionsBy@0} ''' - KingSlime: "[i:560] 20% increased whip size" + KingSlime: "[i:560] {0}% increased whip size" DesertScourge: "{0} Increases maximum life by 5" EyeOfCthulhu: "[i:43] Increases whip damage by 10%" Crabulon: "{0} Enemies struck by whips glow slightly" @@ -92,6 +92,7 @@ Items: { Deerclops: "[i:5120] Minion hits can spawn shadow hands" Skeletron: "[i:4801] Increases minion knockback" WallOfFlesh: "[i:267] Increases max number of minions by 1" + SlimeGod: "{0} 10% increased whip size" } } diff --git a/YhtPlayer.cs b/YhtPlayer.cs index fc4544d..6a3066d 100644 --- a/YhtPlayer.cs +++ b/YhtPlayer.cs @@ -30,7 +30,12 @@ public class YhtPlayer : ModPlayer { Player.maxMinions += GetSummonersAmbitionMinionBonus(); if (SummonerAmbitions.Contains("king_slime")) { - Player.whipRangeMultiplier += 0.2f; + if (ModLoader.HasMod("CalamityMod")) { + Player.whipRangeMultiplier += 0.1f; + } + else { + Player.whipRangeMultiplier += 0.2f; + } } if (ModLoader.HasMod("CalamityMod") && SummonerAmbitions.Contains("desert_scourge")) { @@ -48,6 +53,9 @@ public class YhtPlayer : ModPlayer { if (SummonerAmbitions.Contains("skeletron")) { Player.GetKnockback(DamageClass.Summon) += 0.1f; } + if (ModLoader.HasMod("CalamityMod") && SummonerAmbitions.Contains("slime_god")) { + Player.whipRangeMultiplier += 0.1f; + } } }