Changed Caustic Tear's method of obtainment

Added Fargo's support for caustic tear and acid rain
This commit is contained in:
Amber Sienna committed 2020-03-26 19:47:03 +00:00
1 parent a4e32191f8
commit 5aee5d0961
6 files changed
+97 -21

No files matched your search

+11 -1
View File
@@ -1,4 +1,5 @@
using CalamityMod.CalPlayer;
using CalamityMod.Events;
using CalamityMod.Items;
using CalamityMod.Projectiles;
using CalamityMod.World;
@@ -1651,7 +1652,16 @@ namespace CalamityMod
Item item = (Item)args[1];
int rarity = (int)args[2];
return SetCalamityRarity(item, rarity);
case "AbominationnClearEvents":
bool eventActive = CalamityWorld.rainingAcid;
bool canClear = Convert.ToBoolean(args[1]); //This is to indicate whether abomm is able to clear the event due to a cooldown
if (eventActive && canClear) //adjust based on other events when added.
{
CalamityWorld.acidRainPoints = 0;
CalamityWorld.triedToSummonOldDuke = false;
AcidRainEvent.UpdateInvasion(false);
}
return eventActive;
default:
return new ArgumentException("ERROR: Invalid method name.");
}
+10
View File
@@ -55,6 +55,7 @@ using CalamityMod.NPCs.SupremeCalamitas;
using CalamityMod.NPCs.TownNPCs;
using CalamityMod.NPCs.Yharon;
using CalamityMod.Projectiles.Summon;
using CalamityMod.World;
using Microsoft.Xna.Framework;
using System;
using System.Collections.Generic;
@@ -766,6 +767,13 @@ namespace CalamityMod
fargos.Call("AddSummon", order, "CalamityMod", summonItemName, downed, price);
}
void AddToAbomShop(float order, string summonItemName, Func<bool> downed, int price)
{
fargos.Call("AddEventSummon", order, "CalamityMod", summonItemName, downed, price); //Not currently in the live version of fargo's, it will however be in the next version.
}
fargos.Call("AbominationnClearEvents", "CalamityMod", CalamityWorld.rainingAcid, true);
AddToMutantShop("DesertScourge", "DriedSeafood", DownedDesertScourge, Item.buyPrice(gold: 2));
AddToMutantShop("Crabulon", "DecapoditaSprout", DownedCrabulon, Item.buyPrice(gold: 4));
AddToMutantShop("HiveMind", "Teratoma", DownedHiveMind, Item.buyPrice(gold: 10));
@@ -780,6 +788,8 @@ namespace CalamityMod
AddToMutantShop("ProfanedGuardians", "ProfanedShard", DownedGuardians, Item.buyPrice(platinum: 5));
AddToMutantShop("Bumblebirb", "BirbPheromones", DownedBirb, Item.buyPrice(platinum: 5));
AddToMutantShop("OldDuke", "BloodwormItem", DownedBoomerDuke, Item.buyPrice(platinum: 8));
AddToAbomShop(InvasionDifficulty["Acid Rain Initial"], "CausticTear", DownedAcidRainInitial, Item.buyPrice(gold: 3));
}
private static void CensusSupport()