DP goes away when summoning SCirrus
This commit is contained in:
1 parent
f0eb0b2252
commit
e2ca695a5e
2 files changed
+12
No files matched your search
@@ -2,6 +2,7 @@
|
||||
using CalamityMod.Items.Mounts;
|
||||
using CalamityMod.Items.Placeables.Furniture;
|
||||
using CalamityMod.Items.Potions.Alcohol;
|
||||
using CalamityMod.NPCs.SupremeCalamitas;
|
||||
using CalamityMod.Projectiles.Magic;
|
||||
using CalamityMod.Projectiles.Summon;
|
||||
using CalamityMod.World;
|
||||
@@ -85,6 +86,9 @@ namespace CalamityMod.NPCs.TownNPCs
|
||||
|
||||
public override bool CanTownNPCSpawn(int numTownNPCs)
|
||||
{
|
||||
if (NPC.AnyNPCs(ModContent.NPCType<SupremeCalamitas.SupremeCalamitas>()) && Main.zenithWorld)
|
||||
return false;
|
||||
|
||||
if (CalamityWorld.spawnedCirrus)
|
||||
return true;
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ using CalamityMod.Items.Placeables.Furniture.CraftingStations;
|
||||
using CalamityMod.Items.Potions.Alcohol;
|
||||
using CalamityMod.Items.SummonItems;
|
||||
using CalamityMod.NPCs.SupremeCalamitas;
|
||||
using CalamityMod.NPCs.TownNPCs;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -115,6 +116,13 @@ namespace CalamityMod.Tiles.Furniture.CraftingStations
|
||||
if (vodka)
|
||||
{
|
||||
Main.LocalPlayer.ConsumeItem(ModContent.ItemType<FabsolsVodka>(), true);
|
||||
for (int f = 0; f < Main.maxNPCs; f++)
|
||||
{
|
||||
if (Main.npc[f].type == ModContent.NPCType<FAP>() && Main.npc[f].active)
|
||||
{
|
||||
Main.npc[f].active = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!usingSpecialItem)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user