diff --git a/CalPlayer/CalamityPlayer.cs b/CalPlayer/CalamityPlayer.cs index ee29b5aa6e..ed67881b01 100644 --- a/CalPlayer/CalamityPlayer.cs +++ b/CalPlayer/CalamityPlayer.cs @@ -1095,6 +1095,7 @@ namespace CalamityMod.CalPlayer public bool omegaBlueTransformationForce; public bool omegaBlueTransformationPower; public bool redBow; + public bool cocosFeather; #endregion #region Calamitas Enchant Effects @@ -2098,6 +2099,7 @@ namespace CalamityMod.CalPlayer omegaBlueTransformation = omegaBlueTransformationForce = omegaBlueTransformationPower = false; redBow = false; + cocosFeather = false; rageModeActive = false; adrenalineModeActive = false; @@ -4074,6 +4076,12 @@ namespace CalamityMod.CalPlayer Player.body = EquipLoader.GetEquipSlot(Mod, "RedBow", EquipType.Body); Player.head = EquipLoader.GetEquipSlot(Mod, "RedBow", EquipType.Head); } + if (cocosFeather) + { + Player.legs = EquipLoader.GetEquipSlot(Mod, "CocosFeather", EquipType.Legs); + Player.body = EquipLoader.GetEquipSlot(Mod, "CocosFeather", EquipType.Body); + Player.head = EquipLoader.GetEquipSlot(Mod, "CocosFeather", EquipType.Head); + } if (snowRuffianSet) { Player.wings = EquipLoader.GetEquipSlot(Mod, "SnowRuffianMask", EquipType.Wings); diff --git a/Items/Accessories/Vanity/Birds_Head.png b/Items/Accessories/Vanity/Birds_Head.png new file mode 100644 index 0000000000..69f37b43b8 Binary files /dev/null and b/Items/Accessories/Vanity/Birds_Head.png differ diff --git a/Items/Accessories/Vanity/Birds_Legs.png b/Items/Accessories/Vanity/Birds_Legs.png new file mode 100644 index 0000000000..87cee93548 Binary files /dev/null and b/Items/Accessories/Vanity/Birds_Legs.png differ diff --git a/Items/Accessories/Vanity/Birds_Torso.png b/Items/Accessories/Vanity/Birds_Torso.png new file mode 100644 index 0000000000..9a4ac6d766 Binary files /dev/null and b/Items/Accessories/Vanity/Birds_Torso.png differ diff --git a/Items/Accessories/Vanity/CocosFeather.cs b/Items/Accessories/Vanity/CocosFeather.cs new file mode 100644 index 0000000000..83fba17589 --- /dev/null +++ b/Items/Accessories/Vanity/CocosFeather.cs @@ -0,0 +1,64 @@ +using CalamityMod.CalPlayer; +using Terraria; +using Terraria.DataStructures; +using Terraria.ID; +using Terraria.ModLoader; +using Terraria.Audio; + +namespace CalamityMod.Items.Accessories.Vanity +{ + public class CocosFeather : ModItem, ILocalizedModType + { + public new string LocalizationCategory => "Items.Accessories"; + public override void Load() + { + if (Main.netMode != NetmodeID.Server) + { + EquipLoader.AddEquipTexture(Mod, "CalamityMod/Items/Accessories/Vanity/Birds_Head", EquipType.Head, this); + EquipLoader.AddEquipTexture(Mod, "CalamityMod/Items/Accessories/Vanity/Birds_Torso", EquipType.Body, this); + EquipLoader.AddEquipTexture(Mod, "CalamityMod/Items/Accessories/Vanity/Heart_Legs", EquipType.Legs, this); + } + } + + public override void SetStaticDefaults() + { + + if (Main.netMode == NetmodeID.Server) + return; + + int equipSlotHead = EquipLoader.GetEquipSlot(Mod, Name, EquipType.Head); + ArmorIDs.Head.Sets.DrawHead[equipSlotHead] = false; + + int equipSlotBody = EquipLoader.GetEquipSlot(Mod, Name, EquipType.Body); + ArmorIDs.Body.Sets.HidesTopSkin[equipSlotBody] = true; + ArmorIDs.Body.Sets.HidesArms[equipSlotBody] = true; + + int equipSlotLegs = EquipLoader.GetEquipSlot(Mod, Name, EquipType.Legs); + ArmorIDs.Legs.Sets.HidesBottomSkin[equipSlotLegs] = true; + } + + public override void SetDefaults() + { + Item.width = 42; + Item.height = 38; + Item.accessory = true; + Item.value = CalamityGlobalItem.Rarity1BuyPrice; + Item.rare = ItemRarityID.Green; + Item.vanity = true; + Item.Calamity().devItem = true; + } + + public override void UpdateVanity(Player player) + { + player.Calamity().cocosFeather = true; + } + + public override void UpdateAccessory(Player player, bool hideVisual) + { + if (!hideVisual) + { + player.Calamity().cocosFeather = true; + } + } + } +} diff --git a/Items/Accessories/Vanity/CocosFeather.png b/Items/Accessories/Vanity/CocosFeather.png new file mode 100644 index 0000000000..3b69e78dca Binary files /dev/null and b/Items/Accessories/Vanity/CocosFeather.png differ diff --git a/Items/TreasureBags/MiscGrabBags/StarterBag.cs b/Items/TreasureBags/MiscGrabBags/StarterBag.cs index abf1bf8068..f892d27066 100644 --- a/Items/TreasureBags/MiscGrabBags/StarterBag.cs +++ b/Items/TreasureBags/MiscGrabBags/StarterBag.cs @@ -109,7 +109,16 @@ namespace CalamityMod.Items.TreasureBags.MiscGrabBags } itemLoot.AddIf(getsOracleHeadphones, ModContent.ItemType()); - + + // Bird dev item + // Name specific: "bird" + static bool getsSakuraFeather(DropAttemptInfo info) + { + string playerName = info.player.name; + return playerName == "bird"; + } + + itemLoot.AddIf(getsSakuraFeather, ModContent.ItemType()); } } } diff --git a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson index 2ebc9c4b00..df77c18beb 100644 --- a/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson +++ b/Localization/en-US/Mods.CalamityMod.Items.Accessories.hjson @@ -2004,6 +2004,11 @@ AbandonedWulfrumHelmet: { ''' } +CocosFeather: { + DisplayName: Coco's Feather + Tooltip: "" +} + HapuFruit: { DisplayName: Ha-pu Fruit Tooltip: "'A fruit that calms your nerves (may have unintended side effects)'"