1 - Draedon's Heart is now the Exo Mech expert accessory, removed the the recipe and Rev+ accessory affects.
2 - Daedalus armor, Catastrophe Claymore, Crystal Blade, Consecrated Water and Fulguration Halberd require less crystal shards to craft. 3 - Revivify Potion blood orb recipe requirement increased. 4 - Exo Mech treasure bag. 5 - Reduced Fabstaff and Helium Flash recipe requirements. 6 - Weak Reference Support for exo mechs adjusted. 7 - Exo mech minimap icons. 8 - Exo mech loot drop code. 9 - Artemis targets the same player as Apollo if Apollo is alive.
No files matched your search
@@ -271,15 +271,6 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
float rageGen = 0f;
|
||||
|
||||
// Draedon's Heart provides constant rage generation that scales with missing health.
|
||||
if (modPlayer.draedonsHeart)
|
||||
{
|
||||
float percentMissingHealth = 1f - player.statLife / player.statLifeMax2;
|
||||
float rageGainLerp = MathHelper.Lerp(DraedonsHeart.MinRagePerSecond, DraedonsHeart.MaxRagePerSecond, percentMissingHealth);
|
||||
float dhRageGen = modPlayer.rageMax * rageGainLerp / 60f;
|
||||
if (rageGen < dhRageGen)
|
||||
rageGen = dhRageGen;
|
||||
}
|
||||
// Shattered Community provides constant rage generation (stronger than Heart of Darkness).
|
||||
if (modPlayer.shatteredCommunity)
|
||||
{
|
||||
@@ -3883,7 +3874,6 @@ namespace CalamityMod.CalPlayer
|
||||
// Draedon's Heart bonus
|
||||
if (modPlayer.draedonsHeart)
|
||||
{
|
||||
player.allDamage += 0.05f;
|
||||
if (player.StandingStill() && player.itemAnimation == 0)
|
||||
player.statDefense += (int)(player.statDefense * 0.75);
|
||||
}
|
||||
|
||||
@@ -1,30 +1,17 @@
|
||||
using CalamityMod.CalPlayer;
|
||||
using CalamityMod.Items.Materials;
|
||||
using CalamityMod.Tiles.Furniture.CraftingStations;
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
using Terraria.ID;
|
||||
using Terraria.DataStructures;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
public class DraedonsHeart : ModItem
|
||||
{
|
||||
// The percentage of a full Rage bar that is gained every second with Draedon's Heart equipped.
|
||||
public const float MinRagePerSecond = 0.015f;
|
||||
public const float MaxRagePerSecond = 0.045f; // 3x rage generation at 0% health, aka +200% rage generation
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Draedon's Heart");
|
||||
Tooltip.SetDefault("Boosts your damage by 5% and max movement speed and acceleration by 5%\n" +
|
||||
"You generate rage over time and rage does not fade away out of combat\n" +
|
||||
"Passive rage generation increases drastically as health decreases\n" +
|
||||
"Converts certain debuffs into buffs and extends their durations\n" +
|
||||
"Debuffs affected: Darkness, Blackout, Confused, Slow, Weak, Broken Armor,\n" +
|
||||
"Armor Crunch, War Cleave, Chilled, Ichor and Obstructed\n" +
|
||||
"Receiving a hit causes you to only lose half of your max adrenaline rather than all of it\n" +
|
||||
"Reduces the amount of defense stat damage you take by 50%\n" +
|
||||
Tooltip.SetDefault("Reduces the amount of defense damage you take by 50%\n" +
|
||||
"Standing still regenerates your life quickly, reduces your damage by 50% and boosts your defense by 75%\n" +
|
||||
"Nanomachines, son");
|
||||
Main.RegisterItemAnimation(item.type, new DrawAnimationVertical(5, 7));
|
||||
@@ -34,32 +21,17 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
item.width = 26;
|
||||
item.height = 26;
|
||||
item.value = CalamityGlobalItem.Rarity14BuyPrice;
|
||||
item.accessory = true;
|
||||
item.Calamity().customRarity = CalamityRarity.DarkBlue;
|
||||
}
|
||||
item.expert = true;
|
||||
item.rare = ItemRarityID.Red;
|
||||
item.value = CalamityGlobalItem.RarityVioletBuyPrice;
|
||||
item.Calamity().customRarity = CalamityRarity.Violet;
|
||||
}
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.laudanum = true;
|
||||
modPlayer.stressPills = true;
|
||||
modPlayer.heartOfDarkness = true;
|
||||
modPlayer.draedonsHeart = true;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<HeartofDarkness>());
|
||||
recipe.AddIngredient(ModContent.ItemType<StressPills>());
|
||||
recipe.AddIngredient(ModContent.ItemType<Laudanum>());
|
||||
recipe.AddIngredient(ModContent.ItemType<CosmiliteBar>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<AscendantSpiritEssence>());
|
||||
recipe.AddIngredient(ItemID.Nanites, 250);
|
||||
recipe.AddTile(ModContent.TileType<DraedonsForge>());
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,7 +33,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 15);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 12);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>(), 3);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -58,7 +58,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 3);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>());
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -67,7 +67,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 3);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>());
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 3);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>());
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -56,7 +56,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 3);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>());
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 10);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 4);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>(), 2);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -63,7 +63,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<VerstaltiteBar>(), 8);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 6);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 3);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>());
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -45,7 +45,7 @@ namespace CalamityMod.Items.Potions
|
||||
recipe.AddRecipe();
|
||||
recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.HolyWater, 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<BloodOrb>(), 50);
|
||||
recipe.AddIngredient(ModContent.ItemType<BloodOrb>(), 100);
|
||||
recipe.AddTile(TileID.AlchemyTable);
|
||||
recipe.SetResult(this, 5);
|
||||
recipe.AddRecipe();
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
using CalamityMod.Items.Accessories;
|
||||
using CalamityMod.Items.Armor.Vanity;
|
||||
using CalamityMod.Items.Weapons.Magic;
|
||||
using CalamityMod.Items.Weapons.Melee;
|
||||
using CalamityMod.Items.Weapons.Ranged;
|
||||
using CalamityMod.Items.Weapons.Rogue;
|
||||
using CalamityMod.Items.Weapons.Summon;
|
||||
using CalamityMod.NPCs.ExoMechs.Apollo;
|
||||
using CalamityMod.NPCs.ExoMechs.Ares;
|
||||
using CalamityMod.NPCs.ExoMechs.Artemis;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
using CalamityMod.World;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Items.TreasureBags
|
||||
{
|
||||
public class DraedonTreasureBag : ModItem
|
||||
{
|
||||
public override int BossBagNPC => ModContent.NPCType<AresBody>();
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Treasure Bag");
|
||||
Tooltip.SetDefault("{$CommonItemTooltip.RightClickToOpen}");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.maxStack = 999;
|
||||
item.consumable = true;
|
||||
item.width = 24;
|
||||
item.height = 24;
|
||||
item.rare = ItemRarityID.Cyan;
|
||||
item.expert = true;
|
||||
}
|
||||
|
||||
public override bool CanRightClick() => true;
|
||||
|
||||
public override void PostUpdate() => CalamityUtils.ForceItemIntoWorld(item);
|
||||
|
||||
public override void OpenBossBag(Player player)
|
||||
{
|
||||
player.TryGettingDevArmor();
|
||||
|
||||
// Weapons
|
||||
float w = DropHelper.BagWeaponDropRateFloat;
|
||||
DropHelper.DropEntireWeightedSet(player,
|
||||
DropHelper.WeightStack<SpineOfThanatos>(w),
|
||||
DropHelper.WeightStack<PhotonRipper>(w),
|
||||
DropHelper.WeightStack<SurgeDriver>(w),
|
||||
DropHelper.WeightStack<TheJailor>(w),
|
||||
DropHelper.WeightStack<RefractionRotor>(w),
|
||||
DropHelper.WeightStack<TheAtomSplitter>(w)
|
||||
);
|
||||
|
||||
// Equipment
|
||||
DropHelper.DropItem(player, ModContent.ItemType<DraedonsHeart>());
|
||||
|
||||
// Vanity
|
||||
// DropHelper.DropItemChance(player, ModContent.ItemType<ThanatosMask>(), 7);
|
||||
// DropHelper.DropItemChance(player, ModContent.ItemType<ArtemisMask>(), 7);
|
||||
// DropHelper.DropItemChance(player, ModContent.ItemType<ApolloMask>(), 7);
|
||||
// DropHelper.DropItemChance(player, ModContent.ItemType<AresMask>(), 7);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
After Width: | Height: | Size: 943 B |
@@ -48,8 +48,9 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
public override void AddRecipes()
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ModContent.ItemType<Phantoplasm>(), 100);
|
||||
recipe.AddIngredient(ModContent.ItemType<ShadowspecBar>(), 50);
|
||||
recipe.AddIngredient(ItemID.RainbowRod);
|
||||
recipe.AddIngredient(ModContent.ItemType<Phantoplasm>(), 20);
|
||||
recipe.AddIngredient(ModContent.ItemType<ShadowspecBar>(), 10);
|
||||
recipe.AddTile(ModContent.TileType<DraedonsForge>());
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
|
||||
@@ -99,8 +99,8 @@ namespace CalamityMod.Items.Weapons.Magic
|
||||
r.AddIngredient(ModContent.ItemType<CalamitasInferno>());
|
||||
r.AddIngredient(ModContent.ItemType<ForbiddenSun>());
|
||||
r.AddIngredient(ModContent.ItemType<AuricBar>(), 4);
|
||||
r.AddIngredient(ItemID.FragmentSolar, 80);
|
||||
r.AddIngredient(ItemID.FragmentNebula, 20);
|
||||
r.AddIngredient(ItemID.FragmentSolar, 20);
|
||||
r.AddIngredient(ItemID.FragmentNebula, 5);
|
||||
r.AddRecipe();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ namespace CalamityMod.Items.Weapons.Melee
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.HallowedBar, 10);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 15);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 7);
|
||||
recipe.AddIngredient(ItemID.SoulofNight, 5);
|
||||
recipe.AddRecipeGroup("CursedFlameIchor", 5);
|
||||
recipe.AddIngredient(ItemID.SoulofMight, 3);
|
||||
|
||||
@@ -35,14 +35,14 @@ namespace CalamityMod.Items.Weapons.Melee
|
||||
public override void AddRecipes()
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 15);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 10);
|
||||
recipe.AddIngredient(ItemID.CobaltSword);
|
||||
recipe.AddIngredient(ItemID.PixieDust, 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 15);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 10);
|
||||
recipe.AddIngredient(ItemID.PalladiumSword);
|
||||
recipe.AddIngredient(ItemID.PixieDust, 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
|
||||
@@ -79,13 +79,13 @@ namespace CalamityMod.Items.Weapons.Melee
|
||||
public override void AddRecipes()
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 20);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 10);
|
||||
recipe.AddIngredient(ItemID.AdamantiteBar, 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 20);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 10);
|
||||
recipe.AddIngredient(ItemID.TitaniumBar, 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -54,7 +54,7 @@ namespace CalamityMod.Items.Weapons.Rogue
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.HolyWater, 100);
|
||||
recipe.AddRecipeGroup("AnyAdamantiteBar", 5);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 20);
|
||||
recipe.AddIngredient(ItemID.CrystalShard, 10);
|
||||
recipe.AddIngredient(ItemID.SoulofLight, 7);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -578,20 +578,19 @@ namespace CalamityMod
|
||||
}
|
||||
|
||||
// Exo Mechs
|
||||
// Loot requires edits
|
||||
// Collection requires edits
|
||||
// Instructions require edits
|
||||
// Despawn requires edits
|
||||
/*{
|
||||
{
|
||||
BossDifficulty.TryGetValue("ExoMechs", out float order);
|
||||
List<int> bosses = new List<int>() { NPCType<Apollo>(), NPCType<AresBody>(), NPCType<Artemis>(), NPCType<ThanatosHead>() };
|
||||
List<int> loot = new List<int>() { ItemType<LeviathanBag>(), ItemType<Greentide>(), ItemType<Leviatitan>(), ItemType<SirensSong>(), ItemType<Atlantis>(), ItemType<GastricBelcherStaff>(), ItemType<BrackishFlask>(), ItemType<LeviathanTeeth>(), ItemType<LureofEnthrallment>(), ItemType<LeviathanAmbergris>(), ItemType<TheCommunity>(), ItemID.HotlineFishingHook, ItemID.BottomlessBucket, ItemID.SuperAbsorbantSponge, ItemID.FishingPotion, ItemID.SonarPotion, ItemID.CratePotion, ItemID.GreaterHealingPotion };
|
||||
List<int> collection = new List<int>() { ItemType<LeviathanTrophy>(), ItemType<LeviathanMask>(), ItemType<KnowledgeOcean>(), ItemType<KnowledgeLeviathanandSiren>() };
|
||||
string instructions = "By using a high-tech computer thing that somebody as stupid as you shouldn't be able to use, but whatever";
|
||||
List<int> loot = new List<int>() { ItemType<DraedonTreasureBag>(), ItemType<SpineOfThanatos>(), ItemType<PhotonRipper>(), ItemType<SurgeDriver>(), ItemType<TheJailor>(), ItemType<RefractionRotor>(), ItemType<TheAtomSplitter>(), ItemType<DraedonsHeart>() };
|
||||
//List<int> collection = new List<int>() { ItemType<AresTrophy>(), ItemType<ThanatosTrophy>(), ItemType<ArtemisTrophy>(), ItemType<ApolloTrophy>(), ItemType<AresMask>(), ItemType<ThanatosMask>(), ItemType<ArtemisMask>(), ItemType<ApolloMask>(), ItemType<KnowledgeExoMechs>() };
|
||||
string instructions = "By using a high-tech computer thing";
|
||||
string despawn = CalamityUtils.ColorMessage("An imperfection after all...what a shame.", new Color(0x7F, 0xFF, 0xD4));
|
||||
string bossLogTex = "CalamityMod/NPCs/ExoMechs/ExoMechs_BossChecklist";
|
||||
AddBoss(bossChecklist, calamity, "ExoMechs", order, bosses, DownedExoMechs, null, loot, collection, instructions, despawn, bossLogTex);
|
||||
}*/
|
||||
//string bossLogTex = "CalamityMod/NPCs/ExoMechs/ExoMechs_BossChecklist";
|
||||
//AddBoss(bossChecklist, calamity, "ExoMechs", order, bosses, DownedExoMechs, null, loot, collection, instructions, despawn, bossLogTex);
|
||||
}
|
||||
|
||||
// Supreme Calamitas
|
||||
{
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.Items.TreasureBags;
|
||||
using CalamityMod.NPCs.ExoMechs.Artemis;
|
||||
using CalamityMod.NPCs.ExoMechs.Ares;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
@@ -15,9 +16,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Apollo
|
||||
{
|
||||
//[AutoloadBossHead]
|
||||
public class Apollo : ModNPC
|
||||
{
|
||||
public static int phase1IconIndex;
|
||||
public static int phase2IconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string phase1IconPath = "CalamityMod/NPCs/ExoMechs/Apollo/ApolloHead";
|
||||
string phase2IconPath = "CalamityMod/NPCs/ExoMechs/Apollo/ApolloPhase2Head";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(phase1IconPath, -1);
|
||||
phase1IconIndex = ModContent.GetModBossHeadSlot(phase1IconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(phase2IconPath, -1);
|
||||
phase2IconIndex = ModContent.GetModBossHeadSlot(phase2IconPath);
|
||||
}
|
||||
|
||||
public enum Phase
|
||||
{
|
||||
Normal = 0,
|
||||
@@ -95,7 +110,7 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
|
||||
aiType = -1;
|
||||
npc.Opacity = 0f;
|
||||
npc.knockBackResist = 0f;
|
||||
npc.value = Item.buyPrice(10, 0, 0, 0);
|
||||
npc.value = Item.buyPrice(3, 33, 0, 0);
|
||||
npc.noGravity = true;
|
||||
npc.noTileCollide = true;
|
||||
npc.HitSound = SoundID.NPCHit4;
|
||||
@@ -103,9 +118,18 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
|
||||
npc.netAlways = true;
|
||||
npc.boss = true;
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
bossBag = ModContent.ItemType<DraedonTreasureBag>();
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (npc.life / (float)npc.lifeMax < 0.6f)
|
||||
index = phase2IconIndex;
|
||||
else
|
||||
index = phase1IconIndex;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
writer.Write(npc.dontTakeDamage);
|
||||
@@ -688,23 +712,25 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
|
||||
return false;
|
||||
}
|
||||
|
||||
public override bool SpecialNPCLoot()
|
||||
{
|
||||
int closestSegmentID = DropHelper.FindClosestWormSegment(npc,
|
||||
ModContent.NPCType<Artemis.Artemis>(),
|
||||
ModContent.NPCType<Apollo>());
|
||||
npc.position = Main.npc[closestSegmentID].position;
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void BossLoot(ref string name, ref int potionType)
|
||||
{
|
||||
potionType = ModContent.ItemType<OmegaHealingPotion>();
|
||||
}
|
||||
|
||||
// Needs edits
|
||||
public override void NPCLoot()
|
||||
{
|
||||
/*DropHelper.DropItem(npc, ModContent.ItemType<Voidstone>(), 80, 100);
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<EidolicWail>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<SoulEdge>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<HalibutCannon>());
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ArtemisTrophy>(), 10);
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ApolloTrophy>(), 10);
|
||||
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas, 1, 50, 108);
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas && Main.expertMode, 2, 15, 27);
|
||||
DropHelper.DropItemCondition(npc, ItemID.Ectoplasm, NPC.downedPlantBoss, 1, 21, 32);
|
||||
|
||||
// Check if the other exo mechs are alive
|
||||
bool otherExoMechsAlive = false;
|
||||
if (CalamityGlobalNPC.draedonExoMechWorm != -1)
|
||||
@@ -718,12 +744,8 @@ namespace CalamityMod.NPCs.ExoMechs.Apollo
|
||||
otherExoMechsAlive = true;
|
||||
}
|
||||
|
||||
// Mark Exo Mechs as dead
|
||||
if (!otherExoMechsAlive)
|
||||
{
|
||||
CalamityWorld.downedExoMechs = true;
|
||||
CalamityNetcode.SyncWorld();
|
||||
}*/
|
||||
AresBody.DropExoMechLoot(npc);
|
||||
}
|
||||
|
||||
// Needs edits
|
||||
|
||||
|
After Width: | Height: | Size: 477 B |
|
After Width: | Height: | Size: 476 B |
@@ -1,5 +1,9 @@
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.Items.TreasureBags;
|
||||
using CalamityMod.Items.Weapons.Melee;
|
||||
using CalamityMod.Items.Weapons.Ranged;
|
||||
using CalamityMod.Items.Weapons.Rogue;
|
||||
using CalamityMod.NPCs.ExoMechs.Apollo;
|
||||
using CalamityMod.NPCs.ExoMechs.Artemis;
|
||||
using CalamityMod.NPCs.ExoMechs.Thanatos;
|
||||
@@ -15,7 +19,7 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
{
|
||||
//[AutoloadBossHead]
|
||||
[AutoloadBossHead]
|
||||
public class AresBody : ModNPC
|
||||
{
|
||||
public enum Phase
|
||||
@@ -89,7 +93,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
aiType = -1;
|
||||
npc.Opacity = 0f;
|
||||
npc.knockBackResist = 0f;
|
||||
npc.value = Item.buyPrice(10, 0, 0, 0);
|
||||
npc.value = Item.buyPrice(3, 33, 0, 0);
|
||||
npc.noGravity = true;
|
||||
npc.noTileCollide = true;
|
||||
npc.HitSound = SoundID.NPCHit4;
|
||||
@@ -97,6 +101,7 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
npc.netAlways = true;
|
||||
npc.boss = true;
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
bossBag = ModContent.ItemType<DraedonTreasureBag>();
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
@@ -689,18 +694,10 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
potionType = ModContent.ItemType<OmegaHealingPotion>();
|
||||
}
|
||||
|
||||
// Needs edits
|
||||
public override void NPCLoot()
|
||||
{
|
||||
/*DropHelper.DropItem(npc, ModContent.ItemType<Voidstone>(), 80, 100);
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<EidolicWail>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<SoulEdge>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<HalibutCannon>());
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<AresTrophy>(), 10);
|
||||
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas, 1, 50, 108);
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas && Main.expertMode, 2, 15, 27);
|
||||
DropHelper.DropItemCondition(npc, ItemID.Ectoplasm, NPC.downedPlantBoss, 1, 21, 32);
|
||||
|
||||
// Check if the other exo mechs are alive
|
||||
bool otherExoMechsAlive = false;
|
||||
if (CalamityGlobalNPC.draedonExoMechWorm != -1)
|
||||
@@ -716,10 +713,38 @@ namespace CalamityMod.NPCs.ExoMechs.Ares
|
||||
|
||||
// Mark Exo Mechs as dead
|
||||
if (!otherExoMechsAlive)
|
||||
DropExoMechLoot(npc);
|
||||
}
|
||||
|
||||
public static void DropExoMechLoot(NPC npc)
|
||||
{
|
||||
DropHelper.DropBags(npc);
|
||||
|
||||
// DropHelper.DropItemCondition(npc, ModContent.ItemType<KnowledgeExoMechs>(), true, !CalamityWorld.downedExoMechs);
|
||||
|
||||
// All other drops are contained in the bag, so they only drop directly on Normal
|
||||
if (!Main.expertMode)
|
||||
{
|
||||
CalamityWorld.downedExoMechs = true;
|
||||
CalamityNetcode.SyncWorld();
|
||||
}*/
|
||||
// Weapons
|
||||
float w = DropHelper.NormalWeaponDropRateFloat;
|
||||
DropHelper.DropEntireWeightedSet(npc,
|
||||
DropHelper.WeightStack<SpineOfThanatos>(w),
|
||||
DropHelper.WeightStack<PhotonRipper>(w),
|
||||
DropHelper.WeightStack<SurgeDriver>(w),
|
||||
DropHelper.WeightStack<TheJailor>(w),
|
||||
DropHelper.WeightStack<RefractionRotor>(w),
|
||||
DropHelper.WeightStack<TheAtomSplitter>(w)
|
||||
);
|
||||
|
||||
// Vanity
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ThanatosMask>(), 7);
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ArtemisMask>(), 7);
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ApolloMask>(), 7);
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<AresMask>(), 7);
|
||||
}
|
||||
|
||||
CalamityWorld.downedExoMechs = true;
|
||||
CalamityNetcode.SyncWorld();
|
||||
}
|
||||
|
||||
public override void HitEffect(int hitDirection, double damage)
|
||||
|
||||
|
After Width: | Height: | Size: 482 B |
@@ -15,9 +15,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
{
|
||||
//[AutoloadBossHead]
|
||||
public class Artemis : ModNPC
|
||||
{
|
||||
public static int phase1IconIndex;
|
||||
public static int phase2IconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string phase1IconPath = "CalamityMod/NPCs/ExoMechs/Artemis/ArtemisHead";
|
||||
string phase2IconPath = "CalamityMod/NPCs/ExoMechs/Artemis/ArtemisPhase2Head";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(phase1IconPath, -1);
|
||||
phase1IconIndex = ModContent.GetModBossHeadSlot(phase1IconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(phase2IconPath, -1);
|
||||
phase2IconIndex = ModContent.GetModBossHeadSlot(phase2IconPath);
|
||||
}
|
||||
|
||||
public enum Phase
|
||||
{
|
||||
Normal = 0,
|
||||
@@ -120,7 +134,6 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
aiType = -1;
|
||||
npc.Opacity = 0f;
|
||||
npc.knockBackResist = 0f;
|
||||
npc.value = Item.buyPrice(10, 0, 0, 0);
|
||||
npc.noGravity = true;
|
||||
npc.noTileCollide = true;
|
||||
npc.HitSound = SoundID.NPCHit4;
|
||||
@@ -130,7 +143,15 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (npc.life / (float)npc.lifeMax < 0.6f)
|
||||
index = phase2IconIndex;
|
||||
else
|
||||
index = phase1IconIndex;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
writer.Write(npc.dontTakeDamage);
|
||||
@@ -166,6 +187,17 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
bool revenge = CalamityWorld.revenge || malice;
|
||||
bool expertMode = Main.expertMode || malice;
|
||||
|
||||
// Get a target
|
||||
if (npc.target < 0 || npc.target == Main.maxPlayers || Main.player[npc.target].dead || !Main.player[npc.target].active)
|
||||
npc.TargetClosest();
|
||||
|
||||
// Despawn safety, make sure to target another player if the current player target is too far away
|
||||
if (Vector2.Distance(Main.player[npc.target].Center, npc.Center) > CalamityGlobalNPC.CatchUpDistance200Tiles)
|
||||
npc.TargetClosest();
|
||||
|
||||
// Target variable
|
||||
Player player = Main.player[npc.target];
|
||||
|
||||
// Check if the other exo mechs are alive
|
||||
int otherExoMechsAlive = 0;
|
||||
bool exoWormAlive = false;
|
||||
@@ -182,6 +214,9 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
{
|
||||
if (Main.npc[CalamityGlobalNPC.draedonExoMechTwinGreen].active)
|
||||
{
|
||||
// Set target to Apollo's target if Apollo is alive
|
||||
player = Main.player[Main.npc[CalamityGlobalNPC.draedonExoMechTwinGreen].target];
|
||||
|
||||
// Link the HP of both twins
|
||||
if (npc.life > Main.npc[CalamityGlobalNPC.draedonExoMechTwinGreen].life)
|
||||
npc.life = Main.npc[CalamityGlobalNPC.draedonExoMechTwinGreen].life;
|
||||
@@ -226,17 +261,6 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
// If Artemis and Apollo don't go berserk
|
||||
bool otherMechIsBerserk = exoWormLifeRatio < 0.4f || exoPrimeLifeRatio < 0.4f;
|
||||
|
||||
// Get a target
|
||||
if (npc.target < 0 || npc.target == Main.maxPlayers || Main.player[npc.target].dead || !Main.player[npc.target].active)
|
||||
npc.TargetClosest();
|
||||
|
||||
// Despawn safety, make sure to target another player if the current player target is too far away
|
||||
if (Vector2.Distance(Main.player[npc.target].Center, npc.Center) > CalamityGlobalNPC.CatchUpDistance200Tiles)
|
||||
npc.TargetClosest();
|
||||
|
||||
// Target variable
|
||||
Player player = Main.player[npc.target];
|
||||
|
||||
// Spawn Apollo if it doesn't exist after the first 10 frames have passed
|
||||
if (npc.ai[0] < 10f)
|
||||
{
|
||||
@@ -1003,43 +1027,7 @@ namespace CalamityMod.NPCs.ExoMechs.Artemis
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void BossLoot(ref string name, ref int potionType)
|
||||
{
|
||||
potionType = ModContent.ItemType<OmegaHealingPotion>();
|
||||
}
|
||||
|
||||
// Needs edits
|
||||
public override void NPCLoot()
|
||||
{
|
||||
/*DropHelper.DropItem(npc, ModContent.ItemType<Voidstone>(), 80, 100);
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<EidolicWail>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<SoulEdge>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<HalibutCannon>());
|
||||
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas, 1, 50, 108);
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas && Main.expertMode, 2, 15, 27);
|
||||
DropHelper.DropItemCondition(npc, ItemID.Ectoplasm, NPC.downedPlantBoss, 1, 21, 32);
|
||||
|
||||
// Check if the other exo mechs are alive
|
||||
bool otherExoMechsAlive = false;
|
||||
if (CalamityGlobalNPC.draedonExoMechWorm != -1)
|
||||
{
|
||||
if (Main.npc[CalamityGlobalNPC.draedonExoMechWorm].active)
|
||||
otherExoMechsAlive = true;
|
||||
}
|
||||
if (CalamityGlobalNPC.draedonExoMechPrime != -1)
|
||||
{
|
||||
if (Main.npc[CalamityGlobalNPC.draedonExoMechPrime].active)
|
||||
otherExoMechsAlive = true;
|
||||
}
|
||||
|
||||
// Mark Exo Mechs as dead
|
||||
if (!otherExoMechsAlive)
|
||||
{
|
||||
CalamityWorld.downedExoMechs = true;
|
||||
CalamityNetcode.SyncWorld();
|
||||
}*/
|
||||
}
|
||||
public override bool PreNPCLoot() => false;
|
||||
|
||||
// Needs edits
|
||||
public override void HitEffect(int hitDirection, double damage)
|
||||
|
||||
|
After Width: | Height: | Size: 474 B |
|
After Width: | Height: | Size: 478 B |
@@ -14,8 +14,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
public class ThanatosBody1 : ModNPC
|
||||
public class ThanatosBody1 : ModNPC
|
||||
{
|
||||
public static int normalIconIndex;
|
||||
public static int vulnerableIconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string normalIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosNormalBody";
|
||||
string vulnerableIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosVulnerableBody";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(normalIconPath, -1);
|
||||
normalIconIndex = ModContent.GetModBossHeadSlot(normalIconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(vulnerableIconPath, -1);
|
||||
vulnerableIconIndex = ModContent.GetModBossHeadSlot(vulnerableIconPath);
|
||||
}
|
||||
|
||||
// Whether the body is venting heat or not, it is vulnerable to damage during venting
|
||||
private bool vulnerable = false;
|
||||
public ThanatosSmokeParticleSet SmokeDrawer = new ThanatosSmokeParticleSet(-1, 3, 0f, 16f, 1.5f);
|
||||
@@ -55,6 +70,19 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
}
|
||||
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (vulnerable)
|
||||
index = vulnerableIconIndex;
|
||||
else
|
||||
index = normalIconIndex;
|
||||
}
|
||||
|
||||
public override void BossHeadRotation(ref float rotation)
|
||||
{
|
||||
rotation = npc.rotation;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
@@ -401,9 +429,11 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
SmokeDrawer.Update();
|
||||
|
||||
Player player = Main.player[Main.npc[CalamityGlobalNPC.draedonExoMechWorm].target];
|
||||
|
||||
Vector2 vector18 = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
|
||||
float num191 = Main.player[npc.target].position.X + (Main.player[npc.target].width / 2);
|
||||
float num192 = Main.player[npc.target].position.Y + (Main.player[npc.target].height / 2);
|
||||
float num191 = player.position.X + (player.width / 2);
|
||||
float num192 = player.position.Y + (player.height / 2);
|
||||
num191 = (int)(num191 / 16f) * 16;
|
||||
num192 = (int)(num192 / 16f) * 16;
|
||||
vector18.X = (int)(vector18.X / 16f) * 16;
|
||||
|
||||
@@ -14,8 +14,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
public class ThanatosBody2 : ModNPC
|
||||
public class ThanatosBody2 : ModNPC
|
||||
{
|
||||
public static int normalIconIndex;
|
||||
public static int vulnerableIconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string normalIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosNormalBody";
|
||||
string vulnerableIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosVulnerableBody";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(normalIconPath, -1);
|
||||
normalIconIndex = ModContent.GetModBossHeadSlot(normalIconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(vulnerableIconPath, -1);
|
||||
vulnerableIconIndex = ModContent.GetModBossHeadSlot(vulnerableIconPath);
|
||||
}
|
||||
|
||||
// Whether the body is venting heat or not, it is vulnerable to damage during venting
|
||||
private bool vulnerable = false;
|
||||
public ThanatosSmokeParticleSet SmokeDrawer = new ThanatosSmokeParticleSet(-1, 3, 0f, 16f, 1.5f);
|
||||
@@ -55,6 +70,19 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
}
|
||||
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (vulnerable)
|
||||
index = vulnerableIconIndex;
|
||||
else
|
||||
index = normalIconIndex;
|
||||
}
|
||||
|
||||
public override void BossHeadRotation(ref float rotation)
|
||||
{
|
||||
rotation = npc.rotation;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
@@ -401,9 +429,11 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
SmokeDrawer.Update();
|
||||
|
||||
Player player = Main.player[Main.npc[CalamityGlobalNPC.draedonExoMechWorm].target];
|
||||
|
||||
Vector2 vector18 = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
|
||||
float num191 = Main.player[npc.target].position.X + (Main.player[npc.target].width / 2);
|
||||
float num192 = Main.player[npc.target].position.Y + (Main.player[npc.target].height / 2);
|
||||
float num191 = player.position.X + (player.width / 2);
|
||||
float num192 = player.position.Y + (player.height / 2);
|
||||
num191 = (int)(num191 / 16f) * 16;
|
||||
num192 = (int)(num192 / 16f) * 16;
|
||||
vector18.X = (int)(vector18.X / 16f) * 16;
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using CalamityMod.Events;
|
||||
using CalamityMod.Items.Potions;
|
||||
using CalamityMod.Items.TreasureBags;
|
||||
using CalamityMod.NPCs.ExoMechs.Apollo;
|
||||
using CalamityMod.NPCs.ExoMechs.Artemis;
|
||||
using CalamityMod.NPCs.ExoMechs.Ares;
|
||||
@@ -16,9 +17,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
//[AutoloadBossHead]
|
||||
public class ThanatosHead : ModNPC
|
||||
{
|
||||
public static int normalIconIndex;
|
||||
public static int vulnerableIconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string normalIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosNormalHead";
|
||||
string vulnerableIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosVulnerableHead";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(normalIconPath, -1);
|
||||
normalIconIndex = ModContent.GetModBossHeadSlot(normalIconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(vulnerableIconPath, -1);
|
||||
vulnerableIconIndex = ModContent.GetModBossHeadSlot(vulnerableIconPath);
|
||||
}
|
||||
|
||||
public enum Phase
|
||||
{
|
||||
Charge = 0,
|
||||
@@ -110,7 +125,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
aiType = -1;
|
||||
npc.Opacity = 0f;
|
||||
npc.knockBackResist = 0f;
|
||||
npc.value = Item.buyPrice(10, 0, 0, 0);
|
||||
npc.value = Item.buyPrice(3, 33, 0, 0);
|
||||
npc.behindTiles = true;
|
||||
npc.noGravity = true;
|
||||
npc.noTileCollide = true;
|
||||
@@ -120,9 +135,23 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.boss = true;
|
||||
npc.chaseable = false;
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
bossBag = ModContent.ItemType<DraedonTreasureBag>();
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (vulnerable)
|
||||
index = vulnerableIconIndex;
|
||||
else
|
||||
index = normalIconIndex;
|
||||
}
|
||||
|
||||
public override void BossHeadRotation(ref float rotation)
|
||||
{
|
||||
rotation = npc.rotation;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
writer.Write(npc.dontTakeDamage);
|
||||
@@ -150,7 +179,7 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
npc.Calamity().newAI[i] = reader.ReadSingle();
|
||||
}
|
||||
|
||||
public override void AI()
|
||||
public override void AI()
|
||||
{
|
||||
CalamityGlobalNPC calamityGlobalNPC = npc.Calamity();
|
||||
|
||||
@@ -895,17 +924,21 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
potionType = ModContent.ItemType<OmegaHealingPotion>();
|
||||
}
|
||||
|
||||
public override bool SpecialNPCLoot()
|
||||
{
|
||||
int closestSegmentID = DropHelper.FindClosestWormSegment(npc,
|
||||
ModContent.NPCType<ThanatosHead>(),
|
||||
ModContent.NPCType<ThanatosBody1>(),
|
||||
ModContent.NPCType<ThanatosBody2>(),
|
||||
ModContent.NPCType<ThanatosTail>());
|
||||
npc.position = Main.npc[closestSegmentID].position;
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void NPCLoot()
|
||||
{
|
||||
/*DropHelper.DropItem(npc, ModContent.ItemType<Voidstone>(), 80, 100);
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<EidolicWail>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<SoulEdge>());
|
||||
DropHelper.DropItem(npc, ModContent.ItemType<HalibutCannon>());
|
||||
// DropHelper.DropItemChance(npc, ModContent.ItemType<ThanatosTrophy>(), 10);
|
||||
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas, 1, 50, 108);
|
||||
DropHelper.DropItemCondition(npc, ModContent.ItemType<Lumenite>(), CalamityWorld.downedCalamitas && Main.expertMode, 2, 15, 27);
|
||||
DropHelper.DropItemCondition(npc, ItemID.Ectoplasm, NPC.downedPlantBoss, 1, 21, 32);
|
||||
|
||||
// Check if the other exo mechs are alive
|
||||
bool otherExoMechsAlive = false;
|
||||
if (CalamityGlobalNPC.draedonExoMechTwinGreen != -1)
|
||||
@@ -919,12 +952,8 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
otherExoMechsAlive = true;
|
||||
}
|
||||
|
||||
// Mark Exo Mechs as dead
|
||||
if (!otherExoMechsAlive)
|
||||
{
|
||||
CalamityWorld.downedExoMechs = true;
|
||||
CalamityNetcode.SyncWorld();
|
||||
}*/
|
||||
AresBody.DropExoMechLoot(npc);
|
||||
}
|
||||
|
||||
public override void HitEffect(int hitDirection, double damage)
|
||||
|
||||
|
After Width: | Height: | Size: 414 B |
|
After Width: | Height: | Size: 435 B |
|
After Width: | Height: | Size: 411 B |
@@ -13,8 +13,23 @@ using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
{
|
||||
public class ThanatosTail : ModNPC
|
||||
public class ThanatosTail : ModNPC
|
||||
{
|
||||
public static int normalIconIndex;
|
||||
public static int vulnerableIconIndex;
|
||||
|
||||
internal static void LoadHeadIcons()
|
||||
{
|
||||
string normalIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosNormalTail";
|
||||
string vulnerableIconPath = "CalamityMod/NPCs/ExoMechs/Thanatos/ThanatosVulnerableTail";
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(normalIconPath, -1);
|
||||
normalIconIndex = ModContent.GetModBossHeadSlot(normalIconPath);
|
||||
|
||||
CalamityMod.Instance.AddBossHeadTexture(vulnerableIconPath, -1);
|
||||
vulnerableIconIndex = ModContent.GetModBossHeadSlot(vulnerableIconPath);
|
||||
}
|
||||
|
||||
// Whether the tail is venting heat or not, it is vulnerable to damage during venting
|
||||
private bool vulnerable = false;
|
||||
public ThanatosSmokeParticleSet SmokeDrawer = new ThanatosSmokeParticleSet(-1, 3, 0f, 16f, 1.5f);
|
||||
@@ -54,6 +69,19 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
music = /*CalamityMod.Instance.GetMusicFromMusicMod("AdultEidolonWyrm") ??*/ MusicID.Boss3;
|
||||
}
|
||||
|
||||
public override void BossHeadSlot(ref int index)
|
||||
{
|
||||
if (vulnerable)
|
||||
index = vulnerableIconIndex;
|
||||
else
|
||||
index = normalIconIndex;
|
||||
}
|
||||
|
||||
public override void BossHeadRotation(ref float rotation)
|
||||
{
|
||||
rotation = npc.rotation;
|
||||
}
|
||||
|
||||
public override void SendExtraAI(BinaryWriter writer)
|
||||
{
|
||||
writer.Write(npc.chaseable);
|
||||
@@ -400,9 +428,11 @@ namespace CalamityMod.NPCs.ExoMechs.Thanatos
|
||||
|
||||
SmokeDrawer.Update();
|
||||
|
||||
Player player = Main.player[Main.npc[CalamityGlobalNPC.draedonExoMechWorm].target];
|
||||
|
||||
Vector2 vector18 = new Vector2(npc.position.X + npc.width * 0.5f, npc.position.Y + npc.height * 0.5f);
|
||||
float num191 = Main.player[npc.target].position.X + (Main.player[npc.target].width / 2);
|
||||
float num192 = Main.player[npc.target].position.Y + (Main.player[npc.target].height / 2);
|
||||
float num191 = player.position.X + (player.width / 2);
|
||||
float num192 = player.position.Y + (player.height / 2);
|
||||
num191 = (int)(num191 / 16f) * 16;
|
||||
num192 = (int)(num192 / 16f) * 16;
|
||||
vector18.X = (int)(vector18.X / 16f) * 16;
|
||||
|
||||
|
After Width: | Height: | Size: 391 B |
|
After Width: | Height: | Size: 406 B |
|
After Width: | Height: | Size: 390 B |