Merge branch '1.4' of https://github.com/CalamityTeam/CalamityMod into 1.4
This commit is contained in:
commit
b5791c56bd
1013 files changed
+5247
-4711
No files matched your search
@@ -52,6 +52,10 @@ using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using ProvidenceBoss = CalamityMod.NPCs.Providence.Providence;
|
||||
using Terraria.Audio;
|
||||
using Terraria.DataStructures;
|
||||
using CalamityMod.EntitySources;
|
||||
using ReLogic.Content;
|
||||
using Terraria.GameContent;
|
||||
|
||||
namespace CalamityMod.CalPlayer
|
||||
{
|
||||
@@ -72,7 +76,11 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
// Reduce the expert debuff time multiplier to the normal mode multiplier
|
||||
if (CalamityConfig.Instance.NerfExpertDebuffs)
|
||||
Main.expertDebuffTime = 1f;
|
||||
{
|
||||
var copy = Main.RegisteredGameModes[GameModeID.Expert];
|
||||
copy.DebuffTimeMultiplier = 1f;
|
||||
Main.RegisteredGameModes[GameModeID.Expert] = copy;
|
||||
}
|
||||
|
||||
// Bool for any existing bosses, true if any boss NPC is active
|
||||
areThereAnyDamnBosses = CalamityUtils.AnyBossNPCS();
|
||||
@@ -461,7 +469,8 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
// Create a direct strike to hit this specific NPC.
|
||||
Projectile.NewProjectileDirect(target.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), sigilDamage, 0f, Player.whoAmI, i);
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<Calamity>()));
|
||||
Projectile.NewProjectileDirect(source, target.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), sigilDamage, 0f, Player.whoAmI, i);
|
||||
|
||||
// Incinerate the target with Vulnerability Hex.
|
||||
target.AddBuff(ModContent.BuffType<VulnerabilityHex>(), VulnerabilityHex.CalamityDuration);
|
||||
@@ -602,8 +611,9 @@ namespace CalamityMod.CalPlayer
|
||||
if (!Main.npc[i].active || Main.npc[i].friendly || Main.npc[i].lifeMax < 5 || alreadyTargetedNPCs.Contains(i) || Main.npc[i].realLife >= 0 || Main.npc[i].dontTakeDamage || Main.npc[i].immortal)
|
||||
continue;
|
||||
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<DaawnlightSpiritOrigin>()));
|
||||
if (Main.myPlayer == Player.whoAmI && Main.npc[i].WithinRange(Player.Center, 2000f))
|
||||
Projectile.NewProjectile(Main.npc[i].Center, Vector2.Zero, bullseyeType, 0, 0f, Player.whoAmI, i);
|
||||
Projectile.NewProjectile(source, Main.npc[i].Center, Vector2.Zero, bullseyeType, 0, 0f, Player.whoAmI, i);
|
||||
if (spiritOriginBullseyeShootCountdown <= 0)
|
||||
spiritOriginBullseyeShootCountdown = 45;
|
||||
}
|
||||
@@ -668,8 +678,9 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
// Update the Providence Burn effect drawer if applicable.
|
||||
float providenceBurnIntensity = 0f;
|
||||
if (Main.npc.IndexInRange(CalamityGlobalNPC.holyBoss) && Main.npc[CalamityGlobalNPC.holyBoss].active)
|
||||
providenceBurnIntensity = (Main.npc[CalamityGlobalNPC.holyBoss].modNPC as ProvidenceBoss).CalculateBurnIntensity();
|
||||
int provID = ModContent.NPCType<ProvidenceBoss>();
|
||||
if (Main.npc.IndexInRange(CalamityGlobalNPC.holyBoss) && Main.npc[CalamityGlobalNPC.holyBoss].active && Main.npc[CalamityGlobalNPC.holyBoss].type == provID)
|
||||
providenceBurnIntensity = (Main.npc[CalamityGlobalNPC.holyBoss].ModNPC as ProvidenceBoss).CalculateBurnIntensity();
|
||||
ProvidenceBurnEffectDrawer.ParticleSpawnRate = int.MaxValue;
|
||||
|
||||
// If the burn intensity is great enough, cause the player to ignite into flames.
|
||||
@@ -756,10 +767,10 @@ namespace CalamityMod.CalPlayer
|
||||
Vector2 spawnPoint = new Vector2(Player.Center.X + Main.rand.Next(-1000, 1001), Player.Center.Y - Main.rand.Next(700, 801));
|
||||
|
||||
if (Player.miscCounter % slimeRainRate == 0f)
|
||||
{
|
||||
{
|
||||
if (DownedBossSystem.downedAquaticScourge && !DownedBossSystem.downedPolterghast && Main.rand.NextBool(12))
|
||||
{
|
||||
NPC.NewNPC((int)spawnPoint.X, (int)spawnPoint.Y, ModContent.NPCType<IrradiatedSlime>());
|
||||
NPC.NewNPC(new EntitySource_SpawnNPC(), (int)spawnPoint.X, (int)spawnPoint.Y, ModContent.NPCType<IrradiatedSlime>());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -772,7 +783,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (Math.Abs(Player.velocity.X) > 0.1f || Math.Abs(Player.velocity.Y) > 0.1f)
|
||||
{
|
||||
Projectile.NewProjectile(Player.Center, Vector2.Zero, ModContent.ProjectileType<HydrothermalSmoke>(), 0, 0f, Player.whoAmI);
|
||||
Projectile.NewProjectile(new ProjectileSource_HydrothermalSmoke(Player), Player.Center, Vector2.Zero, ModContent.ProjectileType<HydrothermalSmoke>(), 0, 0f, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
// Trying to find a workaround because apparently putting the bool in ResetEffects prevents it from working
|
||||
@@ -858,8 +869,9 @@ namespace CalamityMod.CalPlayer
|
||||
if (!tentaclesPresent[i])
|
||||
{
|
||||
int damage = (int)(390 * Player.AverageDamage());
|
||||
var source = new ProjectileSource_OmegaBlueTentacles(Player);
|
||||
Vector2 vel = new Vector2(Main.rand.Next(-13, 14), Main.rand.Next(-13, 14)) * 0.25f;
|
||||
Projectile.NewProjectile(Player.Center, vel, ModContent.ProjectileType<OmegaBlueTentacle>(), damage, 8f, Main.myPlayer, Main.rand.Next(120), i);
|
||||
Projectile.NewProjectile(source, Player.Center, vel, ModContent.ProjectileType<OmegaBlueTentacle>(), damage, 8f, Main.myPlayer, Main.rand.Next(120), i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -871,7 +883,7 @@ namespace CalamityMod.CalPlayer
|
||||
damageUp *= 2f;
|
||||
critUp *= 2;
|
||||
}
|
||||
Player.allDamage += damageUp;
|
||||
Player.GetDamage<GenericDamageClass>() += damageUp;
|
||||
AllCritBoost(critUp);
|
||||
}
|
||||
|
||||
@@ -1294,10 +1306,10 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
if (kamiBoost)
|
||||
Player.allDamage += 0.15f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
|
||||
if (avertorBonus)
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
|
||||
if (roverDriveTimer < 616)
|
||||
{
|
||||
@@ -1335,7 +1347,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Player.endurance += 0.07f;
|
||||
Player.statDefense += 13;
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
}
|
||||
|
||||
// Ambrosial Ampoule bonus and other light-granting bonuses
|
||||
@@ -1481,7 +1493,7 @@ namespace CalamityMod.CalPlayer
|
||||
for (int j = 0; j < Main.maxItems; j++)
|
||||
{
|
||||
Item item = Main.item[j];
|
||||
if (item.active && item.noGrabDelay == 0 && item.owner == Player.whoAmI)
|
||||
if (item.active && item.noGrabDelay == 0 && item.playerIndexTheItemIsReservedFor == Player.whoAmI)
|
||||
{
|
||||
item.beingGrabbed = true;
|
||||
if (Player.Center.X > item.Center.X)
|
||||
@@ -1543,12 +1555,13 @@ namespace CalamityMod.CalPlayer
|
||||
if (blunderBooster)
|
||||
{
|
||||
int lightningCount = Main.rand.Next(2, 7);
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<BlunderBooster>()));
|
||||
for (int i = 0; i < lightningCount; i++)
|
||||
{
|
||||
Vector2 lightningVel = new Vector2(Main.rand.NextFloat(-1, 1), Main.rand.NextFloat(-1, 1));
|
||||
lightningVel.Normalize();
|
||||
lightningVel *= Main.rand.NextFloat(1f, 2f);
|
||||
int projectile = Projectile.NewProjectile(Player.Center, lightningVel, ModContent.ProjectileType<BlunderBoosterLightning>(), (int)(30 * Player.RogueDamage()), 0, Player.whoAmI, Main.rand.Next(2), 0f);
|
||||
int projectile = Projectile.NewProjectile(source, Player.Center, lightningVel, ModContent.ProjectileType<BlunderBoosterLightning>(), (int)(30 * Player.RogueDamage()), 0, Player.whoAmI, Main.rand.Next(2), 0f);
|
||||
Main.projectile[projectile].timeLeft = Main.rand.Next(180, 240);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
@@ -1565,12 +1578,13 @@ namespace CalamityMod.CalPlayer
|
||||
else if (plaguedFuelPack)
|
||||
{
|
||||
int numClouds = Main.rand.Next(2, 10);
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<PlaguedFuelPack>()));
|
||||
for (int i = 0; i < numClouds; i++)
|
||||
{
|
||||
Vector2 cloudVelocity = new Vector2(Main.rand.NextFloat(-1, 1), Main.rand.NextFloat(-1, 1));
|
||||
cloudVelocity.Normalize();
|
||||
cloudVelocity *= Main.rand.NextFloat(0f, 1f);
|
||||
int projectile = Projectile.NewProjectile(Player.Center, cloudVelocity, ModContent.ProjectileType<PlaguedFuelPackCloud>(), (int)(20 * Player.RogueDamage()), 0, Player.whoAmI, 0, 0);
|
||||
int projectile = Projectile.NewProjectile(source, Player.Center, cloudVelocity, ModContent.ProjectileType<PlaguedFuelPackCloud>(), (int)(20 * Player.RogueDamage()), 0, Player.whoAmI, 0, 0);
|
||||
Main.projectile[projectile].timeLeft = Main.rand.Next(180, 240);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
@@ -1589,6 +1603,7 @@ namespace CalamityMod.CalPlayer
|
||||
// Gravistar Sabaton effects
|
||||
if (gSabaton && Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<GravistarSabaton>()));
|
||||
if (gSabatonCooldown <= 0 && !Player.mount.Active)
|
||||
{
|
||||
if (Player.controlDown && Player.releaseDown && Player.position.Y != Player.oldPosition.Y)
|
||||
@@ -1596,7 +1611,7 @@ namespace CalamityMod.CalPlayer
|
||||
gSabatonFall = 300;
|
||||
gSabatonCooldown = 480; //8 second cooldown
|
||||
Player.gravity *= 2f;
|
||||
Projectile.NewProjectile(Player.Center.X, Player.Center.Y + (Player.height / 5f), Player.velocity.X, Player.velocity.Y, ModContent.ProjectileType<SabatonSlam>(), 0, 0, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y + (Player.height / 5f), Player.velocity.X, Player.velocity.Y, ModContent.ProjectileType<SabatonSlam>(), 0, 0, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
if (gSabatonCooldown == 1) //dust when ready to use again
|
||||
@@ -1932,14 +1947,14 @@ namespace CalamityMod.CalPlayer
|
||||
// New textures
|
||||
if (Main.netMode != NetmodeID.Server && Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
Texture2D rain3 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Rain3").Value;
|
||||
Texture2D rainOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/RainOriginal").Value;
|
||||
Texture2D mana2 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana2").Value;
|
||||
Texture2D mana3 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana3").Value;
|
||||
Texture2D mana4 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana4").Value;
|
||||
Texture2D manaOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/ManaOriginal").Value;
|
||||
Texture2D carpetAuric = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/AuricCarpet").Value;
|
||||
Texture2D carpetOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Carpet").Value;
|
||||
Asset<Texture2D> rain3 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Rain3");
|
||||
Asset<Texture2D> rainOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/RainOriginal");
|
||||
Asset<Texture2D> mana2 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana2");
|
||||
Asset<Texture2D> mana3 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana3");
|
||||
Asset<Texture2D> mana4 = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Mana4");
|
||||
Asset<Texture2D> manaOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/ManaOriginal");
|
||||
Asset<Texture2D> carpetAuric = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/AuricCarpet");
|
||||
Asset<Texture2D> carpetOriginal = ModContent.Request<Texture2D>("CalamityMod/ExtraTextures/Carpet");
|
||||
|
||||
int totalManaBoost =
|
||||
(pHeart ? 1 : 0) +
|
||||
@@ -1948,30 +1963,30 @@ namespace CalamityMod.CalPlayer
|
||||
switch (totalManaBoost)
|
||||
{
|
||||
default:
|
||||
Main.manaTexture = manaOriginal;
|
||||
TextureAssets.Mana = manaOriginal;
|
||||
break;
|
||||
case 3:
|
||||
Main.manaTexture = mana4;
|
||||
TextureAssets.Mana = mana4;
|
||||
break;
|
||||
case 2:
|
||||
Main.manaTexture = mana3;
|
||||
TextureAssets.Mana = mana3;
|
||||
break;
|
||||
case 1:
|
||||
Main.manaTexture = mana2;
|
||||
TextureAssets.Mana = mana2;
|
||||
break;
|
||||
}
|
||||
|
||||
if (Main.bloodMoon)
|
||||
Main.rainTexture = rainOriginal;
|
||||
TextureAssets.Rain = rainOriginal;
|
||||
else if (Main.raining && ZoneSulphur)
|
||||
Main.rainTexture = rain3;
|
||||
TextureAssets.Rain = rain3;
|
||||
else
|
||||
Main.rainTexture = rainOriginal;
|
||||
TextureAssets.Rain = rainOriginal;
|
||||
|
||||
if (auricSet)
|
||||
Main.flyingCarpetTexture = carpetAuric;
|
||||
TextureAssets.FlyingCarpet = carpetAuric;
|
||||
else
|
||||
Main.flyingCarpetTexture = carpetOriginal;
|
||||
TextureAssets.FlyingCarpet = carpetOriginal;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
@@ -1987,7 +2002,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (trinketOfChiBuff)
|
||||
{
|
||||
Player.allDamage += 0.5f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.5f;
|
||||
if (Player.itemAnimation > 0)
|
||||
chiBuffTimer = 0;
|
||||
}
|
||||
@@ -2067,7 +2082,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
|
||||
float damageBoost = (1f - modStealth) * 0.2f;
|
||||
Player.allDamage += damageBoost;
|
||||
Player.GetDamage<GenericDamageClass>() += damageBoost;
|
||||
|
||||
int critBoost = (int)((1f - modStealth) * 10f);
|
||||
AllCritBoost(critBoost);
|
||||
@@ -2122,11 +2137,11 @@ namespace CalamityMod.CalPlayer
|
||||
bool usingScope = false;
|
||||
if (!Main.gameMenu && Main.netMode != NetmodeID.Server)
|
||||
{
|
||||
if (Player.noThrow <= 0 && !Player.lastMouseInterface || (Main.zoomX != 0f || Main.zoomY != 0f))
|
||||
if (Player.noThrow <= 0 && !Player.lastMouseInterface || !(Main.CurrentPan == Vector2.Zero))
|
||||
{
|
||||
if (PlayerInput.UsingGamepad)
|
||||
{
|
||||
if (PlayerInput.GamepadThumbstickRight.Length() != 0f || !Main.SmartCursorEnabled)
|
||||
if (PlayerInput.GamepadThumbstickRight.Length() != 0f || !Main.SmartCursorIsUsed)
|
||||
{
|
||||
usingScope = true;
|
||||
}
|
||||
@@ -2214,7 +2229,7 @@ namespace CalamityMod.CalPlayer
|
||||
NetMessage.SendData(MessageID.PlayerStealth, -1, -1, null, Player.whoAmI, 0f, 0f, 0f, 0, 0, 0);
|
||||
|
||||
float damageBoost = (5f - shieldInvinc) * 0.03f;
|
||||
Player.allDamage += damageBoost;
|
||||
Player.GetDamage<GenericDamageClass>() += damageBoost;
|
||||
|
||||
int critBoost = (int)((5f - shieldInvinc) * 2f);
|
||||
AllCritBoost(critBoost);
|
||||
@@ -2339,7 +2354,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (Player.FindBuffIndex(BuffID.Wrath) > -1)
|
||||
Player.ClearBuff(BuffID.Wrath);
|
||||
Player.allDamage += 0.12f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.12f;
|
||||
}
|
||||
|
||||
if (profanedRage)
|
||||
@@ -2359,13 +2374,13 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Player.statDefense -= 10;
|
||||
Player.moveSpeed -= 0.1f;
|
||||
Player.allDamage += 0.05f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.05f;
|
||||
Player.minionKB += 0.5f;
|
||||
}
|
||||
|
||||
if (rRage)
|
||||
{
|
||||
Player.allDamage += 0.3f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.3f;
|
||||
Player.statDefense += 5;
|
||||
}
|
||||
|
||||
@@ -2393,7 +2408,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.endurance += 0.06f;
|
||||
Player.statDefense += 8;
|
||||
Player.pickSpeed -= 0.05f;
|
||||
Player.allDamage += 0.06f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
AllCritBoost(2);
|
||||
Player.minionKB += 1f;
|
||||
Player.moveSpeed += 0.06f;
|
||||
@@ -2416,7 +2431,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (darkSunRing)
|
||||
{
|
||||
Player.maxMinions += 2;
|
||||
Player.allDamage += 0.12f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.12f;
|
||||
Player.minionKB += 1.2f;
|
||||
Player.pickSpeed -= 0.15f;
|
||||
if (Main.eclipse || !Main.dayTime)
|
||||
@@ -2434,7 +2449,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (bloodPactBoost)
|
||||
{
|
||||
Player.allDamage += 0.05f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.05f;
|
||||
Player.statDefense += 20;
|
||||
Player.endurance += 0.1f;
|
||||
Player.longInvince = true;
|
||||
@@ -2445,11 +2460,11 @@ namespace CalamityMod.CalPlayer
|
||||
Player.moveSpeed -= 0.2f;
|
||||
|
||||
if (fabsolVodka)
|
||||
Player.allDamage += 0.08f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.08f;
|
||||
|
||||
if (vodka)
|
||||
{
|
||||
Player.allDamage += 0.06f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
AllCritBoost(2);
|
||||
}
|
||||
|
||||
@@ -2467,18 +2482,18 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (whiskey)
|
||||
{
|
||||
Player.allDamage += 0.04f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.04f;
|
||||
AllCritBoost(2);
|
||||
}
|
||||
|
||||
if (everclear)
|
||||
Player.allDamage += 0.25f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.25f;
|
||||
|
||||
if (bloodyMary)
|
||||
{
|
||||
if (Main.bloodMoon)
|
||||
{
|
||||
Player.allDamage += 0.15f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
AllCritBoost(7);
|
||||
Player.moveSpeed += 0.1f;
|
||||
}
|
||||
@@ -2489,7 +2504,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Main.dayTime)
|
||||
{
|
||||
Player.statDefense += 5;
|
||||
Player.allDamage += 0.03f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.03f;
|
||||
AllCritBoost(2);
|
||||
Player.endurance += 0.03f;
|
||||
}
|
||||
@@ -2500,7 +2515,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Main.dayTime)
|
||||
{
|
||||
Player.statDefense += 10;
|
||||
Player.allDamage += 0.07f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.07f;
|
||||
AllCritBoost(3);
|
||||
Player.endurance += 0.07f;
|
||||
}
|
||||
@@ -2523,7 +2538,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (moscowMule)
|
||||
{
|
||||
Player.allDamage += 0.09f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.09f;
|
||||
AllCritBoost(3);
|
||||
}
|
||||
|
||||
@@ -2651,7 +2666,7 @@ namespace CalamityMod.CalPlayer
|
||||
float damageBoost = floatTypeBoost * 0.5f;
|
||||
Player.endurance += floatTypeBoost * 0.25f;
|
||||
Player.statDefense += integerTypeBoost;
|
||||
Player.allDamage += damageBoost;
|
||||
Player.GetDamage<GenericDamageClass>() += damageBoost;
|
||||
AllCritBoost(critBoost);
|
||||
Player.minionKB += floatTypeBoost;
|
||||
Player.moveSpeed += floatTypeBoost * 0.5f;
|
||||
@@ -2759,7 +2774,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (wDeath)
|
||||
{
|
||||
Player.allDamage -= 0.2f;
|
||||
Player.GetDamage<GenericDamageClass>() -= 0.2f;
|
||||
Player.moveSpeed -= 0.1f;
|
||||
}
|
||||
|
||||
@@ -2774,14 +2789,14 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (astralInfection)
|
||||
{
|
||||
Player.allDamage -= 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() -= 0.1f;
|
||||
Player.moveSpeed -= 0.15f;
|
||||
}
|
||||
|
||||
if (pFlames)
|
||||
{
|
||||
Player.blind = !reducedPlagueDmg;
|
||||
Player.allDamage -= 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() -= 0.1f;
|
||||
Player.moveSpeed -= 0.15f;
|
||||
}
|
||||
|
||||
@@ -2851,7 +2866,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (crimEffigy)
|
||||
{
|
||||
Player.allDamage += 0.15f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
Player.statDefense += 10;
|
||||
}
|
||||
|
||||
@@ -2873,7 +2888,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (rBrain)
|
||||
{
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.75))
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.5))
|
||||
Player.moveSpeed -= 0.05f;
|
||||
}
|
||||
@@ -2927,7 +2942,7 @@ namespace CalamityMod.CalPlayer
|
||||
Player.buffImmune[BuffID.Frozen] = true;
|
||||
|
||||
if (Player.statLife > (int)(Player.statLifeMax2 * 0.75))
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
if (Player.statLife < (int)(Player.statLifeMax2 * 0.25))
|
||||
Player.statDefense += 20;
|
||||
}
|
||||
@@ -2935,7 +2950,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (vexation)
|
||||
{
|
||||
if (Player.statLife < (int)(Player.statLifeMax2 * 0.5))
|
||||
Player.allDamage += 0.2f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.2f;
|
||||
}
|
||||
|
||||
if (ataxiaBlaze)
|
||||
@@ -2968,10 +2983,11 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.whoAmI == Main.myPlayer && bloodflareSummonTimer <= 0)
|
||||
{
|
||||
bloodflareSummonTimer = 900;
|
||||
var source = new ProjectileSource_BloodflareSummonSet(Player);
|
||||
for (int I = 0; I < 3; I++)
|
||||
{
|
||||
float ai1 = I * 120;
|
||||
int projectile = Projectile.NewProjectile(Player.Center.X + (float)(Math.Sin(I * 120) * 550), Player.Center.Y + (float)(Math.Cos(I * 120) * 550), 0f, 0f,
|
||||
int projectile = Projectile.NewProjectile(source, Player.Center.X + (float)(Math.Sin(I * 120) * 550), Player.Center.Y + (float)(Math.Cos(I * 120) * 550), 0f, 0f,
|
||||
ModContent.ProjectileType<GhostlyMine>(), (int)(3750 * Player.MinionDamage()), 1f, Player.whoAmI, ai1, 0f);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
@@ -2984,12 +3000,12 @@ namespace CalamityMod.CalPlayer
|
||||
Player.GetDamage(DamageClass.Melee) += 0.1f;
|
||||
Player.lavaMax += 240;
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.5))
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
}
|
||||
|
||||
if (deepDiver && Player.IsUnderwater())
|
||||
{
|
||||
Player.allDamage += 0.15f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
Player.statDefense += 15;
|
||||
Player.moveSpeed += 0.15f;
|
||||
}
|
||||
@@ -3009,7 +3025,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (coreOfTheBloodGod)
|
||||
{
|
||||
Player.endurance += 0.08f;
|
||||
Player.allDamage += 0.08f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.08f;
|
||||
}
|
||||
|
||||
if (godSlayerThrowing)
|
||||
@@ -3036,6 +3052,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
const int BaseDamage = 120;
|
||||
int damage = (int)(BaseDamage * Player.MinionDamage());
|
||||
var source = new ProjectileSource_TarragonSummonAura(Player);
|
||||
float range = 300f;
|
||||
|
||||
for (int i = 0; i < Main.maxNPCs; ++i)
|
||||
@@ -3045,7 +3062,7 @@ namespace CalamityMod.CalPlayer
|
||||
continue;
|
||||
|
||||
if (Vector2.Distance(Player.Center, npc.Center) <= range)
|
||||
Projectile.NewProjectileDirect(npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
Projectile.NewProjectileDirect(source, npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3063,6 +3080,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
const int BaseDamage = 10;
|
||||
int damage = (int)(BaseDamage * Player.AverageDamage());
|
||||
var source = Player.GetProjectileSource_Item(Player.ActiveItem());
|
||||
float range = 200f;
|
||||
|
||||
for (int i = 0; i < Main.maxNPCs; ++i)
|
||||
@@ -3072,13 +3090,13 @@ namespace CalamityMod.CalPlayer
|
||||
continue;
|
||||
|
||||
if (Vector2.Distance(Player.Center, npc.Center) <= range)
|
||||
Projectile.NewProjectileDirect(npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
Projectile.NewProjectileDirect(source, npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
|
||||
// Occasionally spawn cute sparks so it looks like an electrical aura
|
||||
if (Main.rand.NextBool(10))
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(50f, 30f, 60f);
|
||||
int spark = Projectile.NewProjectile(npc.Center, velocity, ModContent.ProjectileType<EutrophicSpark>(), damage / 2, 0f, Player.whoAmI);
|
||||
int spark = Projectile.NewProjectile(source, npc.Center, velocity, ModContent.ProjectileType<EutrophicSpark>(), damage / 2, 0f, Player.whoAmI);
|
||||
if (spark.WithinBounds(Main.maxProjectiles))
|
||||
{
|
||||
Main.projectile[spark].Calamity().forceTypeless = true;
|
||||
@@ -3104,6 +3122,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
const int BaseDamage = 50;
|
||||
int damage = (int)(BaseDamage * Player.AverageDamage());
|
||||
var source = new ProjectileSource_InfernoPotionBoost(Player);
|
||||
float range = 300f;
|
||||
|
||||
for (int i = 0; i < Main.maxNPCs; ++i)
|
||||
@@ -3116,7 +3135,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
npc.AddBuff(ModContent.BuffType<BrimstoneFlames>(), 120);
|
||||
if (brimLoreInfernoTimer == 0)
|
||||
Projectile.NewProjectileDirect(npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
Projectile.NewProjectileDirect(source, npc.Center, Vector2.Zero, ModContent.ProjectileType<DirectStrike>(), damage, 0f, Player.whoAmI, i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3145,31 +3164,31 @@ namespace CalamityMod.CalPlayer
|
||||
Player.buffImmune[BuffID.Venom] = true;
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.75))
|
||||
{
|
||||
Player.allDamage += 0.06f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
AllCritBoost(3);
|
||||
}
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.5))
|
||||
{
|
||||
Player.allDamage += 0.06f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
AllCritBoost(3);
|
||||
}
|
||||
if (Player.statLife <= (int)(Player.statLifeMax2 * 0.25))
|
||||
{
|
||||
Player.allDamage += 0.06f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
AllCritBoost(3);
|
||||
}
|
||||
if (Player.lifeRegen < 0)
|
||||
{
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
AllCritBoost(5);
|
||||
}
|
||||
}
|
||||
|
||||
if (dArtifact)
|
||||
Player.allDamage += 0.25f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.25f;
|
||||
|
||||
if (trippy)
|
||||
Player.allDamage += 0.5f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.5f;
|
||||
|
||||
if (eArtifact)
|
||||
{
|
||||
@@ -3185,6 +3204,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<Items.Accessories.ProfanedSoulArtifact>()));
|
||||
if (Player.FindBuffIndex(ModContent.BuffType<ProfanedBabs>()) == -1 && !profanedCrystalBuffs)
|
||||
Player.AddBuff(ModContent.BuffType<ProfanedBabs>(), 3600, true);
|
||||
|
||||
@@ -3193,14 +3213,14 @@ namespace CalamityMod.CalPlayer
|
||||
int guardianAmt = 1;
|
||||
|
||||
if (Player.ownedProjectileCounts[ModContent.ProjectileType<MiniGuardianHealer>()] < guardianAmt)
|
||||
Projectile.NewProjectile(Player.Center.X, Player.Center.Y, 0f, -6f, ModContent.ProjectileType<MiniGuardianHealer>(), 0, 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, 0f, -6f, ModContent.ProjectileType<MiniGuardianHealer>(), 0, 0f, Main.myPlayer, 0f, 0f);
|
||||
|
||||
if (crystal || minionSlotStat >= 10)
|
||||
{
|
||||
gDefense = true;
|
||||
|
||||
if (Player.ownedProjectileCounts[ModContent.ProjectileType<MiniGuardianDefense>()] < guardianAmt)
|
||||
Projectile.NewProjectile(Player.Center.X, Player.Center.Y, 0f, -3f, ModContent.ProjectileType<MiniGuardianDefense>(), 1, 1f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, 0f, -3f, ModContent.ProjectileType<MiniGuardianDefense>(), 1, 1f, Main.myPlayer, 0f, 0f);
|
||||
}
|
||||
|
||||
if (crystal || summonSet)
|
||||
@@ -3208,7 +3228,7 @@ namespace CalamityMod.CalPlayer
|
||||
gOffense = true;
|
||||
|
||||
if (Player.ownedProjectileCounts[ModContent.ProjectileType<MiniGuardianAttack>()] < guardianAmt)
|
||||
Projectile.NewProjectile(Player.Center.X, Player.Center.Y, 0f, -1f, ModContent.ProjectileType<MiniGuardianAttack>(), 1, 1f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, 0f, -1f, ModContent.ProjectileType<MiniGuardianAttack>(), 1, 1f, Main.myPlayer, 0f, 0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3276,9 +3296,10 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.strongBees && Main.rand.NextBool(3))
|
||||
++beeCount;
|
||||
int damage = (int)(30 * Player.MinionDamage());
|
||||
var source = new ProjectileSource_PlaguebringerSetBoost(Player);
|
||||
for (int index = 0; index < beeCount; ++index)
|
||||
{
|
||||
int bee = Projectile.NewProjectile(Player.Center.X, Player.Center.Y, Main.rand.NextFloat(-35f, 35f) * 0.02f, Main.rand.NextFloat(-35f, 35f) * 0.02f, (Main.rand.NextBool(4) ? ModContent.ProjectileType<PlagueBeeSmall>() : Player.beeType()), damage, Player.beeKB(0f), Player.whoAmI, 0f, 0f);
|
||||
int bee = Projectile.NewProjectile(source, Player.Center.X, Player.Center.Y, Main.rand.NextFloat(-35f, 35f) * 0.02f, Main.rand.NextFloat(-35f, 35f) * 0.02f, (Main.rand.NextBool(4) ? ModContent.ProjectileType<PlagueBeeSmall>() : Player.beeType()), damage, Player.beeKB(0f), Player.whoAmI, 0f, 0f);
|
||||
Main.projectile[bee].usesLocalNPCImmunity = true;
|
||||
Main.projectile[bee].localNPCHitCooldown = 10;
|
||||
Main.projectile[bee].penetrate = 2;
|
||||
@@ -3327,8 +3348,9 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<BlunderBooster>()));
|
||||
if (Player.ownedProjectileCounts[ModContent.ProjectileType<BlunderBoosterAura>()] < 1)
|
||||
Projectile.NewProjectile(Player.Center, Vector2.Zero, ModContent.ProjectileType<BlunderBoosterAura>(), (int)(30 * Player.RogueDamage()), 0f, Player.whoAmI, 0f, 0f);
|
||||
Projectile.NewProjectile(source, Player.Center, Vector2.Zero, ModContent.ProjectileType<BlunderBoosterAura>(), (int)(30 * Player.RogueDamage()), 0f, Player.whoAmI, 0f, 0f);
|
||||
}
|
||||
}
|
||||
else if (Player.ownedProjectileCounts[ModContent.ProjectileType<BlunderBoosterAura>()] != 0)
|
||||
@@ -3359,9 +3381,11 @@ namespace CalamityMod.CalPlayer
|
||||
Player.buffTime[l]--;
|
||||
}
|
||||
}
|
||||
|
||||
//Summon the aura
|
||||
var source = new ProjectileSource_TeslaPotion(Player);
|
||||
if (Player.ownedProjectileCounts[ModContent.ProjectileType<TeslaAura>()] < 1)
|
||||
Projectile.NewProjectile(Player.Center, Vector2.Zero, ModContent.ProjectileType<TeslaAura>(), (int)(10 * Player.AverageDamage()), 0f, Player.whoAmI, 0f, 0f);
|
||||
Projectile.NewProjectile(source, Player.Center, Vector2.Zero, ModContent.ProjectileType<TeslaAura>(), (int)(10 * Player.AverageDamage()), 0f, Player.whoAmI, 0f, 0f);
|
||||
}
|
||||
}
|
||||
else if (Player.ownedProjectileCounts[ModContent.ProjectileType<TeslaAura>()] != 0)
|
||||
@@ -3382,8 +3406,9 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (CryoStone)
|
||||
{
|
||||
var source = Player.GetProjectileSource_Accessory(FindAccessory(ModContent.ItemType<CryoStone>()));
|
||||
if (Player.whoAmI == Main.myPlayer && Player.ownedProjectileCounts[ModContent.ProjectileType<CryonicShield>()] == 0)
|
||||
Projectile.NewProjectile(Player.Center, Vector2.Zero, ModContent.ProjectileType<CryonicShield>(), (int)(Player.AverageDamage() * 70), 0f, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, Player.Center, Vector2.Zero, ModContent.ProjectileType<CryonicShield>(), (int)(Player.AverageDamage() * 70), 0f, Player.whoAmI);
|
||||
}
|
||||
else if (Player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
@@ -3420,6 +3445,7 @@ namespace CalamityMod.CalPlayer
|
||||
travelDist = shootSpeed / travelDist;
|
||||
}
|
||||
|
||||
var source = new ProjectileSource_PrismaticArmorLasers(Player);
|
||||
int laserAmt = Main.rand.Next(2);
|
||||
for (int index = 0; index < laserAmt; index++)
|
||||
{
|
||||
@@ -3442,7 +3468,7 @@ namespace CalamityMod.CalPlayer
|
||||
velocity.Y *= travelDist;
|
||||
velocity.X += Main.rand.Next(-50, 51) * 0.02f;
|
||||
velocity.Y += Main.rand.Next(-50, 51) * 0.02f;
|
||||
int laser = Projectile.NewProjectile(startPos, velocity, ModContent.ProjectileType<DeathhailBeam>(), dmg, 4f, Player.whoAmI, 0f, 0f);
|
||||
int laser = Projectile.NewProjectile(source, startPos, velocity, ModContent.ProjectileType<DeathhailBeam>(), dmg, 4f, Player.whoAmI, 0f, 0f);
|
||||
Main.projectile[laser].localNPCHitCooldown = 5;
|
||||
if (laser.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[laser].Calamity().forceTypeless = true;
|
||||
@@ -3508,7 +3534,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.statLife >= Player.statLifeMax2)
|
||||
{
|
||||
float beeBoost = Player.endurance / 2f;
|
||||
Player.allDamage += beeBoost;
|
||||
Player.GetDamage<GenericDamageClass>() += beeBoost;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3614,7 +3640,7 @@ namespace CalamityMod.CalPlayer
|
||||
case BuffID.Obstructed:
|
||||
Player.headcovered = false;
|
||||
Player.statDefense += 50;
|
||||
Player.allDamage += 0.5f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.5f;
|
||||
AllCritBoost(25);
|
||||
break;
|
||||
case BuffID.Ichor:
|
||||
@@ -3640,19 +3666,19 @@ namespace CalamityMod.CalPlayer
|
||||
case BuffID.Confused:
|
||||
Player.confused = false;
|
||||
Player.statDefense += 30;
|
||||
Player.allDamage += 0.25f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.25f;
|
||||
AllCritBoost(10);
|
||||
break;
|
||||
case BuffID.Blackout:
|
||||
Player.blackout = false;
|
||||
Player.statDefense += 30;
|
||||
Player.allDamage += 0.25f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.25f;
|
||||
AllCritBoost(10);
|
||||
break;
|
||||
case BuffID.Darkness:
|
||||
Player.blind = false;
|
||||
Player.statDefense += 15;
|
||||
Player.allDamage += 0.1f;
|
||||
Player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
AllCritBoost(5);
|
||||
break;
|
||||
}
|
||||
@@ -3884,7 +3910,7 @@ namespace CalamityMod.CalPlayer
|
||||
float minionDmg = Player.GetDamage(DamageClass.Summon);
|
||||
if (minionDmg < rogueDmg)
|
||||
{
|
||||
Player.GetDamage(DamageClass.Summon) = rogueDmg;
|
||||
Player.GetDamage(DamageClass.Summon) += rogueDmg - Player.GetDamage(DamageClass.Summon);
|
||||
}
|
||||
if (rogueDmg < minionDmg)
|
||||
{
|
||||
@@ -3922,7 +3948,7 @@ namespace CalamityMod.CalPlayer
|
||||
#region Stat Meter
|
||||
private void UpdateStatMeter()
|
||||
{
|
||||
float allDamageStat = Player.allDamage - 1f;
|
||||
float allDamageStat = Player.GetDamage<GenericDamageClass>() - 1f;
|
||||
damageStats[0] = (int)((Player.GetDamage(DamageClass.Melee) + allDamageStat - 1f) * 100f);
|
||||
damageStats[1] = (int)((Player.GetDamage(DamageClass.Ranged) + allDamageStat - 1f) * 100f);
|
||||
damageStats[2] = (int)((Player.GetDamage(DamageClass.Magic) + allDamageStat - 1f) * 100f);
|
||||
@@ -4068,7 +4094,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (PlayerInput.Triggers.JustPressed.QuickBuff)
|
||||
{
|
||||
for (int i = 0; i < Main.maxInventory; ++i)
|
||||
for (int i = 0; i < Main.InventorySlotsTotal; ++i)
|
||||
{
|
||||
Item item = Player.inventory[i];
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using static Terraria.ModLoader.ModContent;
|
||||
using Terraria.Audio;
|
||||
using CalamityMod.EntitySources;
|
||||
|
||||
namespace CalamityMod.CalPlayer
|
||||
{
|
||||
@@ -163,7 +164,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
ItemLifesteal(target, item, damage);
|
||||
ItemOnHit(item, damage, target.Center, crit, (target.damage > 5 || target.boss) && !target.SpawnedFromStatue);
|
||||
NPCDebuffs(target, item.melee, item.ranged, item.magic, item.summon, item.Calamity().rogue, false);
|
||||
NPCDebuffs(target, item.CountsAsClass<MeleeDamageClass>(), item.CountsAsClass<RangedDamageClass>(), item.CountsAsClass<MagicDamageClass>(), item.CountsAsClass<SummonDamageClass>(), item.Calamity().rogue, false);
|
||||
|
||||
// Shattered Community tracks all damage dealt with Rage Mode (ignoring dummies).
|
||||
if (target.type == NPCID.TargetDummy || target.type == NPCType<SuperDummyNPC>())
|
||||
@@ -181,7 +182,7 @@ namespace CalamityMod.CalPlayer
|
||||
CalamityGlobalNPC cgn = target.Calamity();
|
||||
|
||||
// Handle on-hit melee effects for the gem tech armor set.
|
||||
if (proj.melee)
|
||||
if (proj.CountsAsClass(DamageClass.Melee))
|
||||
GemTechState.MeleeOnHitEffects(target);
|
||||
|
||||
// Handle on-hit projectiles effects for the mythril armor set.
|
||||
@@ -362,7 +363,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
ProjLifesteal(target, proj, damage, crit);
|
||||
ProjOnHit(proj, target.Center, crit, (target.damage > 5 || target.boss) && !target.SpawnedFromStatue);
|
||||
NPCDebuffs(target, proj.melee, proj.ranged, proj.magic, proj.IsSummon(), cgp.rogue, true);
|
||||
NPCDebuffs(target, proj.CountsAsClass(DamageClass.Melee), proj.CountsAsClass(DamageClass.Ranged), proj.CountsAsClass(DamageClass.Magic), proj.IsSummon(), cgp.rogue, true);
|
||||
|
||||
// Shattered Community tracks all damage dealt with Rage Mode (ignoring dummies).
|
||||
if (target.type == NPCID.TargetDummy || target.type == NPCType<SuperDummyNPC>())
|
||||
@@ -449,7 +450,7 @@ namespace CalamityMod.CalPlayer
|
||||
break;
|
||||
}
|
||||
ItemOnHit(item, damage, target.Center, crit, true);
|
||||
PvpDebuffs(target, item.melee, item.ranged, item.magic, item.summon, item.Calamity().rogue, false);
|
||||
PvpDebuffs(target, item.CountsAsClass<MeleeDamageClass>(), item.CountsAsClass<RangedDamageClass>(), item.CountsAsClass<MagicDamageClass>(), item.CountsAsClass<SummonDamageClass>(), item.Calamity().rogue, false);
|
||||
}
|
||||
|
||||
public override void OnHitPvpWithProj(Projectile proj, Player target, int damage, bool crit)
|
||||
@@ -584,7 +585,7 @@ namespace CalamityMod.CalPlayer
|
||||
target.AddBuff(BuffType<Plague>(), 300);
|
||||
}
|
||||
ProjOnHit(proj, target.Center, crit, true);
|
||||
PvpDebuffs(target, proj.melee, proj.ranged, proj.magic, proj.IsSummon(), proj.Calamity().rogue, true);
|
||||
PvpDebuffs(target, proj.CountsAsClass(DamageClass.Melee), proj.CountsAsClass(DamageClass.Ranged), proj.CountsAsClass(DamageClass.Magic), proj.IsSummon(), proj.Calamity().rogue, true);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
@@ -592,24 +593,25 @@ namespace CalamityMod.CalPlayer
|
||||
#region Item
|
||||
public void ItemOnHit(Item item, int damage, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
if (!item.melee && Player.meleeEnchant == 7)
|
||||
Projectile.NewProjectile(position, Player.velocity, ProjectileID.ConfettiMelee, 0, 0f, Player.whoAmI);
|
||||
var source = Player.GetProjectileSource_Item(item);
|
||||
if (!item.CountsAsClass<MeleeDamageClass>() && Player.meleeEnchant == 7)
|
||||
Projectile.NewProjectile(source, position, Player.velocity, ProjectileID.ConfettiMelee, 0, 0f, Player.whoAmI);
|
||||
|
||||
if (reaverDefense)
|
||||
Player.lifeRegenTime += 1;
|
||||
|
||||
if (Player.whoAmI == Main.myPlayer && desertProwler && crit && item.ranged)
|
||||
if (Player.whoAmI == Main.myPlayer && desertProwler && crit && item.CountsAsClass<RangedDamageClass>())
|
||||
{
|
||||
bool noTornado = Player.ownedProjectileCounts[ProjectileType<DesertMark>()] < 1 && Player.ownedProjectileCounts[ProjectileType<DesertTornado>()] < 1;
|
||||
if (noTornado && Main.rand.NextBool(15))
|
||||
{
|
||||
Projectile.NewProjectile(position, Vector2.Zero, ProjectileType<DesertMark>(), damage, item.knockBack, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, position, Vector2.Zero, ProjectileType<DesertMark>(), damage, item.knockBack, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
|
||||
if (npcCheck)
|
||||
{
|
||||
if (item.melee && aBulwarkRare && aBulwarkRareTimer == 0)
|
||||
if (item.CountsAsClass<MeleeDamageClass>() && aBulwarkRare && aBulwarkRareTimer == 0)
|
||||
{
|
||||
aBulwarkRareTimer = 10;
|
||||
for (int n = 0; n < 3; n++)
|
||||
@@ -620,7 +622,7 @@ namespace CalamityMod.CalPlayer
|
||||
for (int s = 0; s < 3; s++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(50f, 30f, 60f);
|
||||
Projectile.NewProjectile(position, velocity, ProjectileType<UnstableSpark>(), (int)(15 * Player.AverageDamage()), 0f, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, position, velocity, ProjectileType<UnstableSpark>(), (int)(15 * Player.AverageDamage()), 0f, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
if (astralStarRain && crit && astralStarRainCooldown <= 0)
|
||||
@@ -641,7 +643,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
}
|
||||
|
||||
if (item.melee)
|
||||
if (item.CountsAsClass<MeleeDamageClass>())
|
||||
{
|
||||
titanBoost = 600;
|
||||
if (npcCheck)
|
||||
@@ -650,7 +652,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
// Ataxia True Melee Geysers: 15%, softcap starts at 300 base damage
|
||||
int geyserDamage = CalamityUtils.DamageSoftCap(damage * 0.15, 45);
|
||||
Projectile.NewProjectile(position, Vector2.Zero, ProjectileType<ChaosGeyser>(), geyserDamage, 2f, Player.whoAmI, 0f, 0f);
|
||||
Projectile.NewProjectile(source, position, Vector2.Zero, ProjectileType<ChaosGeyser>(), geyserDamage, 2f, Player.whoAmI, 0f, 0f);
|
||||
}
|
||||
if (soaring)
|
||||
{
|
||||
@@ -664,7 +666,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.wingTime > Player.wingTimeMax)
|
||||
Player.wingTime = Player.wingTimeMax;
|
||||
}
|
||||
if (bloodflareMelee && item.melee && bloodflareMeleeHits < 15 && !bloodflareFrenzy && !Player.HasCooldown(BloodflareFrenzy.ID))
|
||||
if (bloodflareMelee && item.CountsAsClass<MeleeDamageClass>() && bloodflareMeleeHits < 15 && !bloodflareFrenzy && !Player.HasCooldown(BloodflareFrenzy.ID))
|
||||
bloodflareMeleeHits++;
|
||||
}
|
||||
}
|
||||
@@ -675,11 +677,12 @@ namespace CalamityMod.CalPlayer
|
||||
public void ProjOnHit(Projectile proj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
CalamityGlobalProjectile modProj = proj.Calamity();
|
||||
bool hasClass = proj.melee || proj.ranged || proj.magic || proj.IsSummon() || modProj.rogue;
|
||||
var source = proj.GetProjectileSource_FromThis();
|
||||
bool hasClass = proj.CountsAsClass(DamageClass.Melee) || proj.CountsAsClass(DamageClass.Ranged) || proj.CountsAsClass(DamageClass.Magic) || proj.IsSummon() || modProj.rogue;
|
||||
|
||||
//flask of party affects all types of weapons, !proj.melee is to prevent double flask effects
|
||||
if (!proj.melee && Player.meleeEnchant == 7)
|
||||
Projectile.NewProjectile(position, proj.velocity, ProjectileID.ConfettiMelee, 0, 0f, proj.owner);
|
||||
//flask of party affects all types of weapons, !proj.CountsAsClass(DamageClass.Melee) is to prevent double flask effects
|
||||
if (!proj.CountsAsClass(DamageClass.Melee) && Player.meleeEnchant == 7)
|
||||
Projectile.NewProjectile(source, position, proj.velocity, ProjectileID.ConfettiMelee, 0, 0f, proj.owner);
|
||||
|
||||
if (alchFlask && Player.ownedProjectileCounts[ProjectileType<PlagueSeeker>()] < 3 && hasClass)
|
||||
{
|
||||
@@ -701,7 +704,7 @@ namespace CalamityMod.CalPlayer
|
||||
for (int s = 0; s < 3; s++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(50f, 30f, 60f);
|
||||
Projectile.NewProjectile(position, velocity, ProjectileType<UnstableSpark>(), (int)(15 * Player.AverageDamage()), 0f, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, position, velocity, ProjectileType<UnstableSpark>(), (int)(15 * Player.AverageDamage()), 0f, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -723,11 +726,11 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
}
|
||||
|
||||
if (proj.melee)
|
||||
if (proj.CountsAsClass(DamageClass.Melee))
|
||||
MeleeOnHit(proj, modProj, position, crit, npcCheck);
|
||||
if (proj.ranged)
|
||||
if (proj.CountsAsClass(DamageClass.Ranged))
|
||||
RangedOnHit(proj, modProj, position, crit, npcCheck);
|
||||
if (proj.magic)
|
||||
if (proj.CountsAsClass(DamageClass.Magic))
|
||||
MagicOnHit(proj, modProj, position, crit, npcCheck);
|
||||
if (proj.IsSummon())
|
||||
SummonOnHit(proj, modProj, position, crit, npcCheck);
|
||||
@@ -738,6 +741,7 @@ namespace CalamityMod.CalPlayer
|
||||
#region Melee
|
||||
private void MeleeOnHit(Projectile proj, CalamityGlobalProjectile modProj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
var source = proj.GetProjectileSource_FromThis();
|
||||
Item heldItem = Player.ActiveItem();
|
||||
|
||||
if (modProj.trueMelee)
|
||||
@@ -769,7 +773,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
// Ataxia Melee Geysers: 15%, softcap starts at 240 base damage
|
||||
int geyserDamage = CalamityUtils.DamageSoftCap(proj.damage * 0.15, 36);
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<ChaosGeyser>(), geyserDamage, 0f, Player.whoAmI, 0f, 0f);
|
||||
Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<ChaosGeyser>(), geyserDamage, 0f, Player.whoAmI, 0f, 0f);
|
||||
}
|
||||
if (bloodflareMelee && modProj.trueMelee && bloodflareMeleeHits < 15 && !bloodflareFrenzy && !Player.HasCooldown(BloodflareFrenzy.ID))
|
||||
bloodflareMeleeHits++;
|
||||
@@ -780,25 +784,26 @@ namespace CalamityMod.CalPlayer
|
||||
#region Ranged
|
||||
private void RangedOnHit(Projectile proj, CalamityGlobalProjectile modProj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
var source = proj.GetProjectileSource_FromThis();
|
||||
if (Player.whoAmI == Main.myPlayer && desertProwler && crit)
|
||||
{
|
||||
bool noTornado = Player.ownedProjectileCounts[ProjectileType<DesertMark>()] < 1 && Player.ownedProjectileCounts[ProjectileType<DesertTornado>()] < 1;
|
||||
if (noTornado && Main.rand.NextBool(15))
|
||||
{
|
||||
Projectile.NewProjectile(position, Vector2.Zero, ProjectileType<DesertMark>(), proj.damage, proj.knockBack, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, position, Vector2.Zero, ProjectileType<DesertMark>(), proj.damage, proj.knockBack, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
|
||||
if (npcCheck)
|
||||
{
|
||||
if (tarraRanged && proj.ranged && tarraRangedCooldown <= 0)
|
||||
if (tarraRanged && proj.CountsAsClass(DamageClass.Ranged) && tarraRangedCooldown <= 0)
|
||||
{
|
||||
tarraRangedCooldown = 60;
|
||||
for (int l = 0; l < 2; l++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
int leafDamage = (int)(0.25 * proj.damage);
|
||||
int leaf = Projectile.NewProjectile(position, velocity, ProjectileID.Leaf, leafDamage, 0f, Player.whoAmI);
|
||||
int leaf = Projectile.NewProjectile(source, position, velocity, ProjectileID.Leaf, leafDamage, 0f, Player.whoAmI);
|
||||
if (leaf.WithinBounds(Main.maxProjectiles))
|
||||
{
|
||||
Main.projectile[leaf].Calamity().forceTypeless = true;
|
||||
@@ -811,7 +816,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
int energyDamage = (int)(0.33 * proj.damage);
|
||||
Projectile.NewProjectile(proj.Center, velocity, ProjectileType<TarraEnergy>(), energyDamage, 0f, proj.owner);
|
||||
Projectile.NewProjectile(source, proj.Center, velocity, ProjectileType<TarraEnergy>(), energyDamage, 0f, proj.owner);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -826,6 +831,7 @@ namespace CalamityMod.CalPlayer
|
||||
#region Magic
|
||||
private void MagicOnHit(Projectile proj, CalamityGlobalProjectile modProj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
var source = proj.GetProjectileSource_FromThis();
|
||||
if (ataxiaMage && ataxiaDmg <= 0)
|
||||
{
|
||||
int orbDamage = (int)(proj.damage * 0.6);
|
||||
@@ -847,7 +853,7 @@ namespace CalamityMod.CalPlayer
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(100f, 70f, 100f);
|
||||
// Bloodflare Mage Fireballs: 3 x 50%, softcap starts at 500 base damage to not overly punish slow weapons
|
||||
int bloodflareFireballDamage = CalamityUtils.DamageSoftCap(proj.damage * 0.5, 250);
|
||||
int fire = Projectile.NewProjectile(position, velocity, ProjectileID.BallofFire, bloodflareFireballDamage, 0f, Player.whoAmI);
|
||||
int fire = Projectile.NewProjectile(source, position, velocity, ProjectileID.BallofFire, bloodflareFireballDamage, 0f, Player.whoAmI);
|
||||
if (fire.WithinBounds(Main.maxProjectiles))
|
||||
{
|
||||
Main.projectile[fire].Calamity().forceTypeless = true;
|
||||
@@ -862,7 +868,7 @@ namespace CalamityMod.CalPlayer
|
||||
SoundEngine.PlaySound(SoundID.Zombie, (int)proj.position.X, (int)proj.position.Y, 103);
|
||||
// Silva Mage Blasts: 800 + 60%, softcap on the whole combined thing starts at 1400
|
||||
int silvaBurstDamage = CalamityUtils.DamageSoftCap(800.0 + 0.6 * proj.damage, 1400);
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<SilvaBurst>(), silvaBurstDamage, 8f, Player.whoAmI);
|
||||
Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<SilvaBurst>(), silvaBurstDamage, 8f, Player.whoAmI);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
@@ -870,6 +876,7 @@ namespace CalamityMod.CalPlayer
|
||||
#region Summon
|
||||
private void SummonOnHit(Projectile proj, CalamityGlobalProjectile modProj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
var source = proj.GetProjectileSource_FromThis();
|
||||
if (npcCheck)
|
||||
{
|
||||
if (phantomicArtifact)
|
||||
@@ -891,7 +898,7 @@ namespace CalamityMod.CalPlayer
|
||||
Vector2 target = proj.Center;
|
||||
target.Y += Main.rand.Next(-50, 50);
|
||||
target.X += Main.rand.Next(-50, 50);
|
||||
Projectile.NewProjectile(target, Vector2.Zero, ProjectileType<PhantomicHeart>(), 0, 0f, Player.whoAmI, 0f);
|
||||
Projectile.NewProjectile(source, target, Vector2.Zero, ProjectileType<PhantomicHeart>(), 0, 0f, Player.whoAmI, 0f);
|
||||
}
|
||||
}
|
||||
else if (buffType == empowerBuff)
|
||||
@@ -899,7 +906,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (Player.ownedProjectileCounts[ProjectileType<PhantomicDagger>()] < 3 && Main.rand.NextBool(10))
|
||||
{
|
||||
int damage = (int)(75 * Player.MinionDamage());
|
||||
int dagger = Projectile.NewProjectile(proj.position, proj.velocity, ProjectileType<PhantomicDagger>(), damage, 1f, Player.whoAmI, 0f);
|
||||
int dagger = Projectile.NewProjectile(source, proj.position, proj.velocity, ProjectileType<PhantomicDagger>(), damage, 1f, Player.whoAmI, 0f);
|
||||
if (dagger.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[dagger].Calamity().forceTypeless = true;
|
||||
}
|
||||
@@ -907,7 +914,7 @@ namespace CalamityMod.CalPlayer
|
||||
else
|
||||
{
|
||||
if (Player.ownedProjectileCounts[ProjectileType<PhantomicShield>()] == 0 && phantomicBulwarkCooldown == 0)
|
||||
Projectile.NewProjectile(Player.position, Vector2.Zero, ProjectileType<PhantomicShield>(), 0, 0f, Player.whoAmI, 0f);
|
||||
Projectile.NewProjectile(source, Player.position, Vector2.Zero, ProjectileType<PhantomicShield>(), 0, 0f, Player.whoAmI, 0f);
|
||||
}
|
||||
}
|
||||
else if (hallowedRune)
|
||||
@@ -956,21 +963,21 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (nucleogenesis)
|
||||
{
|
||||
int projectile = Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<ApparatusExplosion>(), (int)(60 * Player.MinionDamage()), 4f, proj.owner);
|
||||
int projectile = Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<ApparatusExplosion>(), (int)(60 * Player.MinionDamage()), 4f, proj.owner);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
jellyDmg = 100f;
|
||||
}
|
||||
else if (starbusterCore)
|
||||
{
|
||||
int projectile = Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<SummonAstralExplosion>(), (int)(40 * Player.MinionDamage()), 3.5f, proj.owner);
|
||||
int projectile = Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<SummonAstralExplosion>(), (int)(40 * Player.MinionDamage()), 3.5f, proj.owner);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
jellyDmg = 60f;
|
||||
}
|
||||
else if (nuclearRod)
|
||||
{
|
||||
int projectile = Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<IrradiatedAura>(), (int)(20 * Player.MinionDamage()), 0f, proj.owner);
|
||||
int projectile = Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<IrradiatedAura>(), (int)(20 * Player.MinionDamage()), 0f, proj.owner);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
jellyDmg = 60f;
|
||||
@@ -989,7 +996,7 @@ namespace CalamityMod.CalPlayer
|
||||
hallowedRuneCooldown = 180;
|
||||
Vector2 spawnPosition = position - new Vector2(0f, 920f).RotatedByRandom(0.3f);
|
||||
float speed = Main.rand.NextFloat(17f, 23f);
|
||||
int projectile = Projectile.NewProjectile(spawnPosition, Vector2.Normalize(position - spawnPosition) * speed, ProjectileType<HallowedStarSummon>(), (int)(30 * Player.MinionDamage()), 3f, proj.owner);
|
||||
int projectile = Projectile.NewProjectile(source, spawnPosition, Vector2.Normalize(position - spawnPosition) * speed, ProjectileType<HallowedStarSummon>(), (int)(30 * Player.MinionDamage()), 3f, proj.owner);
|
||||
if (projectile.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[projectile].Calamity().forceTypeless = true;
|
||||
}
|
||||
@@ -1001,6 +1008,7 @@ namespace CalamityMod.CalPlayer
|
||||
#region Rogue
|
||||
private void RogueOnHit(Projectile proj, CalamityGlobalProjectile modProj, Vector2 position, bool crit, bool npcCheck)
|
||||
{
|
||||
var spawnSource = proj.GetProjectileSource_FromThis();
|
||||
if (modProj.stealthStrike && dragonScales && CalamityUtils.CountProjectiles(ProjectileType<InfernadoFriendly>()) < 1)
|
||||
{
|
||||
int projTileX = (int)(proj.Center.X / 16f);
|
||||
@@ -1031,7 +1039,7 @@ namespace CalamityMod.CalPlayer
|
||||
break;
|
||||
}
|
||||
}
|
||||
int projectileIndex = Projectile.NewProjectile(projTileX * 16 + 8, projTileY * 16 - 24, 0f, 0f, ProjectileType<InfernadoFriendly>(), (int)(550 * Player.RogueDamage()), 15f, Main.myPlayer, 16f, 16f);
|
||||
int projectileIndex = Projectile.NewProjectile(spawnSource, projTileX * 16 + 8, projTileY * 16 - 24, 0f, 0f, ProjectileType<InfernadoFriendly>(), (int)(550 * Player.RogueDamage()), 15f, Main.myPlayer, 16f, 16f);
|
||||
if (projectileIndex.WithinBounds(Main.maxProjectiles))
|
||||
{
|
||||
Main.projectile[projectileIndex].Calamity().forceTypeless = true;
|
||||
@@ -1064,13 +1072,13 @@ namespace CalamityMod.CalPlayer
|
||||
case 2:
|
||||
// Exodus Rogue Fire: 15%
|
||||
int fireDamage = (int)(proj.damage * 0.15);
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<XerocFire>(), fireDamage, 0f, proj.owner, 0f, 0f);
|
||||
Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<XerocFire>(), fireDamage, 0f, proj.owner, 0f, 0f);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
// Exodus Rogue Blast: 20%
|
||||
int blastDamage = (int)(proj.damage * 0.2);
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<XerocBlast>(), blastDamage, 0f, proj.owner, 0f, 0f);
|
||||
Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<XerocBlast>(), blastDamage, 0f, proj.owner, 0f, 0f);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
@@ -1094,7 +1102,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Vector2 source = new Vector2(position.X + Main.rand.Next(-201, 201), Main.screenPosition.Y - 600f - Main.rand.Next(50));
|
||||
Vector2 velocity = (position - source) / 40f;
|
||||
Projectile.NewProjectile(source, velocity, ProjectileType<NanoFlare>(), (int)(120 * Player.RogueDamage()), 3f, proj.owner);
|
||||
Projectile.NewProjectile(spawnSource, source, velocity, ProjectileType<NanoFlare>(), (int)(120 * Player.RogueDamage()), 3f, proj.owner);
|
||||
}
|
||||
}
|
||||
else if (moonCrown)
|
||||
@@ -1105,7 +1113,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
Vector2 source = new Vector2(position.X + Main.rand.Next(-201, 201), Main.screenPosition.Y - 600f - Main.rand.Next(50));
|
||||
Vector2 velocity = (position - source) / 10f;
|
||||
int flare = Projectile.NewProjectile(source, velocity, ProjectileID.LunarFlare, lunarFlareDamage, lunarFlareKB, proj.owner);
|
||||
int flare = Projectile.NewProjectile(spawnSource, source, velocity, ProjectileID.LunarFlare, lunarFlareDamage, lunarFlareKB, proj.owner);
|
||||
if (flare.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[flare].Calamity().forceTypeless = true;
|
||||
}
|
||||
@@ -1119,7 +1127,7 @@ namespace CalamityMod.CalPlayer
|
||||
float speedY = (position.Y - source.Y) * 8;
|
||||
Vector2 velocity = new Vector2(speedX, speedY);
|
||||
int featherDamage = (int)(15 * Player.RogueDamage());
|
||||
int feather = Projectile.NewProjectile(source, velocity, ProjectileType<StickyFeather>(), featherDamage, 3f, proj.owner);
|
||||
int feather = Projectile.NewProjectile(spawnSource, source, velocity, ProjectileType<StickyFeather>(), featherDamage, 3f, proj.owner);
|
||||
if (feather.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[feather].Calamity().forceTypeless = true;
|
||||
}
|
||||
@@ -1136,7 +1144,7 @@ namespace CalamityMod.CalPlayer
|
||||
float yVector = Main.rand.Next(-35, 36) * 0.02f;
|
||||
xVector *= 10f;
|
||||
yVector *= 10f;
|
||||
int eater = Projectile.NewProjectile(proj.Center.X, proj.Center.Y, xVector, yVector, ProjectileType<ForbiddenCircletEater>(), (int)(40 * Player.RogueDamage()), proj.knockBack, proj.owner);
|
||||
int eater = Projectile.NewProjectile(spawnSource, proj.Center.X, proj.Center.Y, xVector, yVector, ProjectileType<ForbiddenCircletEater>(), (int)(40 * Player.RogueDamage()), proj.knockBack, proj.owner);
|
||||
if (eater.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[eater].Calamity().forceTypeless = true;
|
||||
forbiddenCooldown = 15;
|
||||
@@ -1145,7 +1153,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if (titanHeartSet && modProj.stealthStrike && titanCooldown <= 0 && modProj.stealthStrikeHitCount < 5)
|
||||
{
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<SabatonBoom>(), (int)(50 * Player.RogueDamage()), proj.knockBack, proj.owner, 1f, 0f);
|
||||
Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<SabatonBoom>(), (int)(50 * Player.RogueDamage()), proj.knockBack, proj.owner, 1f, 0f);
|
||||
SoundEngine.PlaySound(SoundID.Item14, proj.Center);
|
||||
for (int dustexplode = 0; dustexplode < 360; dustexplode++)
|
||||
{
|
||||
@@ -1181,7 +1189,7 @@ namespace CalamityMod.CalPlayer
|
||||
if (type != -1)
|
||||
{
|
||||
float speed = Main.rand.NextFloat(5f, 11f);
|
||||
int cloud = Projectile.NewProjectile(position, Vector2.One.RotatedByRandom(MathHelper.TwoPi) * speed, type, (int)(30 * Player.RogueDamage()), proj.knockBack, Player.whoAmI);
|
||||
int cloud = Projectile.NewProjectile(spawnSource, position, Vector2.One.RotatedByRandom(MathHelper.TwoPi) * speed, type, (int)(30 * Player.RogueDamage()), proj.knockBack, Player.whoAmI);
|
||||
if (cloud.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[cloud].Calamity().forceTypeless = true;
|
||||
}
|
||||
@@ -1195,14 +1203,14 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
int randrot = Main.rand.Next(-30, 391);
|
||||
Vector2 SoulSpeed = new Vector2(13f, 13f).RotatedBy(MathHelper.ToRadians(randrot));
|
||||
int soul = Projectile.NewProjectile(proj.Center, SoulSpeed, ProjectileType<PenumbraSoul>(), (int)(proj.damage * 0.1), 3f, proj.owner, 0f, 0f);
|
||||
int soul = Projectile.NewProjectile(spawnSource, proj.Center, SoulSpeed, ProjectileType<PenumbraSoul>(), (int)(proj.damage * 0.1), 3f, proj.owner, 0f, 0f);
|
||||
if (soul.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[soul].Calamity().forceTypeless = true;
|
||||
shadowPotCooldown = 30;
|
||||
}
|
||||
if (CalamityLists.spikyBallProjList.Contains(proj.type))
|
||||
{
|
||||
int scythe = Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<CosmicScythe>(), (int)(proj.damage * 0.05), 3f, proj.owner, 1f, 0f);
|
||||
int scythe = Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<CosmicScythe>(), (int)(proj.damage * 0.05), 3f, proj.owner, 1f, 0f);
|
||||
if (scythe.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[scythe].Calamity().forceTypeless = true;
|
||||
Main.projectile[scythe].usesLocalNPCImmunity = true;
|
||||
@@ -1215,7 +1223,7 @@ namespace CalamityMod.CalPlayer
|
||||
Vector2 shardVelocity = new Vector2(Main.rand.NextFloat(-1f, 1f), Main.rand.NextFloat(-1f, 1f));
|
||||
shardVelocity.Normalize();
|
||||
shardVelocity *= 5f;
|
||||
int shard = Projectile.NewProjectile(proj.Center, shardVelocity, ProjectileType<EquanimityDarkShard>(), (int)(proj.damage * 0.15), 0f, proj.owner);
|
||||
int shard = Projectile.NewProjectile(spawnSource, proj.Center, shardVelocity, ProjectileType<EquanimityDarkShard>(), (int)(proj.damage * 0.15), 0f, proj.owner);
|
||||
if (shard.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[shard].Calamity().forceTypeless = true;
|
||||
Main.projectile[shard].timeLeft = 150;
|
||||
@@ -1234,7 +1242,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
if (CalamityLists.flaskBombProjList.Contains(proj.type))
|
||||
{
|
||||
int blackhole = Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<ShadowBlackhole>(), (int)(proj.damage * 0.05), 3f, proj.owner, 0f, 0f);
|
||||
int blackhole = Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<ShadowBlackhole>(), (int)(proj.damage * 0.05), 3f, proj.owner, 0f, 0f);
|
||||
if (blackhole.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[blackhole].Calamity().forceTypeless = true;
|
||||
Main.projectile[blackhole].Center = proj.Center;
|
||||
@@ -1249,7 +1257,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
// Umbraphile Rogue Blasts: 25%, softcap starts at 200 base damage
|
||||
int umbraBlastDamage = CalamityUtils.DamageSoftCap(proj.damage * 0.25, 50);
|
||||
Projectile.NewProjectile(proj.Center, Vector2.Zero, ProjectileType<UmbraphileBoom>(), umbraBlastDamage, 0f, Player.whoAmI);
|
||||
Projectile.NewProjectile(spawnSource, proj.Center, Vector2.Zero, ProjectileType<UmbraphileBoom>(), umbraBlastDamage, 0f, Player.whoAmI);
|
||||
}
|
||||
|
||||
if (raiderTalisman && raiderStack < 150 && crit && raiderCooldown <= 0)
|
||||
@@ -1262,7 +1270,7 @@ namespace CalamityMod.CalPlayer
|
||||
for (int s = 0; s < 3; s++)
|
||||
{
|
||||
Vector2 velocity = CalamityUtils.RandomVelocity(50f, 30f, 60f);
|
||||
int spark = Projectile.NewProjectile(position, velocity, ProjectileType<Spark>(), (int)(20 * Player.RogueDamage()), 0f, Player.whoAmI);
|
||||
int spark = Projectile.NewProjectile(spawnSource, position, velocity, ProjectileType<Spark>(), (int)(20 * Player.RogueDamage()), 0f, Player.whoAmI);
|
||||
if (spark.WithinBounds(Main.maxProjectiles))
|
||||
{
|
||||
Main.projectile[spark].Calamity().forceTypeless = true;
|
||||
@@ -1571,7 +1579,7 @@ namespace CalamityMod.CalPlayer
|
||||
{
|
||||
if (Player.ghostHurt)
|
||||
{
|
||||
proj.ghostHurt(damage, target.Center);
|
||||
proj.ghostHurt(damage, target.Center, target);
|
||||
}
|
||||
|
||||
if (Player.setNebula && Player.nebulaCD == 0 && Main.rand.NextBool(3))
|
||||
@@ -1583,7 +1591,8 @@ namespace CalamityMod.CalPlayer
|
||||
ItemID.NebulaPickup2,
|
||||
ItemID.NebulaPickup3
|
||||
});
|
||||
int nebulaBooster = Item.NewItem(target.Center, target.Size, boosterType, 1, false, 0, false, false);
|
||||
var source = Player.GetItemSource_Misc(ItemSourceID.SetBonus_Nebula);
|
||||
int nebulaBooster = Item.NewItem(source, target.Center, target.Size, boosterType, 1, false, 0, false, false);
|
||||
Main.item[nebulaBooster].velocity.Y = Main.rand.Next(-20, 1) * 0.2f;
|
||||
Main.item[nebulaBooster].velocity.X = Main.rand.Next(10, 31) * 0.2f * proj.direction;
|
||||
if (Main.netMode == NetmodeID.MultiplayerClient)
|
||||
@@ -1670,7 +1679,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
bool otherHealTypes = auricSet || silvaSet || tarraMage || ataxiaMage;
|
||||
|
||||
if (proj.magic && Player.ActiveItem().magic)
|
||||
if (proj.CountsAsClass(DamageClass.Magic) && Player.ActiveItem().CountsAsClass<MagicDamageClass>())
|
||||
{
|
||||
if (manaOverloader && otherHealTypes)
|
||||
{
|
||||
@@ -1719,7 +1728,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
CalamityGlobalProjectile.SpawnLifeStealProjectile(proj, Player, heal, ProjectileType<SilvaOrb>(), 1200f, 3f);
|
||||
}
|
||||
else if (proj.magic && Player.ActiveItem().magic)
|
||||
else if (proj.CountsAsClass(DamageClass.Magic) && Player.ActiveItem().CountsAsClass<MagicDamageClass>())
|
||||
{
|
||||
if (manaOverloader)
|
||||
{
|
||||
@@ -1828,7 +1837,7 @@ namespace CalamityMod.CalPlayer
|
||||
|
||||
if ((target.damage > 5 || target.boss) && !target.SpawnedFromStatue && target.canGhostHeal && !Player.moonLeech)
|
||||
{
|
||||
if (bloodflareMelee && item.melee)
|
||||
if (bloodflareMelee && item.CountsAsClass<MeleeDamageClass>())
|
||||
{
|
||||
int healAmount = Main.rand.Next(2) + 1;
|
||||
Player.statLife += healAmount;
|
||||
@@ -1868,7 +1877,8 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
}
|
||||
|
||||
Projectile.NewProjectile(target.Center, Vector2.Zero, ProjectileType<ReaverHealOrb>(), 0, 0f, Player.whoAmI, healTarget, heal);
|
||||
var source = new ProjectileSource_ReaverHeal(Player);
|
||||
Projectile.NewProjectile(source, target.Center, Vector2.Zero, ProjectileType<ReaverHealOrb>(), 0, 0f, Player.whoAmI, healTarget, heal);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1905,7 +1915,9 @@ namespace CalamityMod.CalPlayer
|
||||
Vector2 spawnPos = new Vector2(x, y);
|
||||
Vector2 velocity = Main.npc[targetIdx].DirectionFrom(spawnPos);
|
||||
velocity *= speed;
|
||||
int projectile = Projectile.NewProjectile(spawnPos, velocity, type, damage, knockback, player.whoAmI, targetIdx, 0f);
|
||||
|
||||
var source = player.GetProjectileSource_Item(player.ActiveItem());
|
||||
int projectile = Projectile.NewProjectile(source, spawnPos, velocity, type, damage, knockback, player.whoAmI, targetIdx, 0f);
|
||||
Main.projectile[projectile].extraUpdates += extraUpdateAmt;
|
||||
}
|
||||
#endregion
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_BloodflareSummonSet : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_BloodflareSummonSet(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_HydrothermalSmoke : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_HydrothermalSmoke(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_InfernoPotionBoost : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_InfernoPotionBoost(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_OmegaBlueTentacles : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_OmegaBlueTentacles(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_PlaguebringerSetBoost : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_PlaguebringerSetBoost(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_PrismaticArmorLasers : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_PrismaticArmorLasers(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_ReaverHeal : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_ReaverHeal(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_TarragonSummonAura : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_TarragonSummonAura(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
|
||||
namespace CalamityMod.EntitySources
|
||||
{
|
||||
public class ProjectileSource_TeslaPotion : IEntitySource
|
||||
{
|
||||
public Player player;
|
||||
public ProjectileSource_TeslaPotion(Player p) => player = p;
|
||||
}
|
||||
}
|
||||
+12
-10
@@ -1,4 +1,4 @@
|
||||
using CalamityMod.NPCs.AcidRain;
|
||||
using CalamityMod.NPCs.AcidRain;
|
||||
using CalamityMod.NPCs.OldDuke;
|
||||
using CalamityMod.Projectiles.Boss;
|
||||
using CalamityMod.World;
|
||||
@@ -7,6 +7,7 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
@@ -163,10 +164,10 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Main.raining = true;
|
||||
Main.cloudBGActive = 1f;
|
||||
Main.numCloudsTemp = Main.cloudLimit;
|
||||
Main.numCloudsTemp = Main.maxClouds;
|
||||
Main.numClouds = Main.numCloudsTemp;
|
||||
Main.windSpeedTemp = 0.72f;
|
||||
Main.windSpeedSet = Main.windSpeedTemp;
|
||||
Main.windSpeedCurrent = 0.72f;
|
||||
Main.windSpeedTarget = Main.windSpeedTarget;
|
||||
Main.weatherCounter = 60 * 60 * 10; // 10 minutes of rain. Remember, once the rain goes away, so does the invasion.
|
||||
Main.rainTime = Main.weatherCounter;
|
||||
Main.maxRaining = 0.89f;
|
||||
@@ -242,10 +243,10 @@ namespace CalamityMod.Events
|
||||
{
|
||||
Main.raining = true;
|
||||
Main.cloudBGActive = 1f;
|
||||
Main.numCloudsTemp = Main.cloudLimit;
|
||||
Main.numCloudsTemp = Main.maxClouds;
|
||||
Main.numClouds = Main.numCloudsTemp;
|
||||
Main.windSpeedTemp = 0.72f;
|
||||
Main.windSpeedSet = Main.windSpeedTemp;
|
||||
Main.windSpeedTarget = 0.72f;
|
||||
Main.windSpeedCurrent = Main.windSpeedCurrent;
|
||||
Main.weatherCounter = 60 * 60 * 10; // 10 minutes of rain. Remember, once the rain goes away, so does the invasion.
|
||||
Main.rainTime = Main.weatherCounter;
|
||||
Main.maxRaining = 0.89f;
|
||||
@@ -265,10 +266,11 @@ namespace CalamityMod.Events
|
||||
}
|
||||
else
|
||||
{
|
||||
var source = new EntitySource_WorldEvent();
|
||||
int playerClosestToAbyss = Player.FindClosest(new Vector2(CalamityWorld.abyssSide ? 0 : Main.maxTilesX * 16, (int)Main.worldSurface), 0, 0);
|
||||
Player closestToAbyss = Main.player[playerClosestToAbyss];
|
||||
if (Main.netMode != NetmodeID.MultiplayerClient && Math.Abs(closestToAbyss.Center.X - (CalamityWorld.abyssSide ? 0 : Main.maxTilesX * 16)) <= 12000f)
|
||||
Projectile.NewProjectile(closestToAbyss.Center + Vector2.UnitY * 160f, Vector2.Zero, ModContent.ProjectileType<OverlyDramaticDukeSummoner>(), 120, 8f, Main.myPlayer);
|
||||
Projectile.NewProjectile(source, closestToAbyss.Center + Vector2.UnitY * 160f, Vector2.Zero, ModContent.ProjectileType<OverlyDramaticDukeSummoner>(), 120, 8f, Main.myPlayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -291,8 +293,8 @@ namespace CalamityMod.Events
|
||||
// Turn off the rain from the event
|
||||
Main.numCloudsTemp = Main.rand.Next(5, 20 + 1);
|
||||
Main.numClouds = Main.numCloudsTemp;
|
||||
Main.windSpeedTemp = Main.rand.NextFloat(0.04f, 0.25f);
|
||||
Main.windSpeedSet = Main.windSpeedTemp;
|
||||
Main.windSpeedCurrent = Main.rand.NextFloat(0.04f, 0.25f);
|
||||
Main.windSpeedTarget = Main.windSpeedTarget;
|
||||
Main.maxRaining = 0f;
|
||||
if (win)
|
||||
{
|
||||
|
||||
@@ -15,6 +15,7 @@ using MonoMod.Cil;
|
||||
using System;
|
||||
using Terraria;
|
||||
using Terraria.DataStructures;
|
||||
using Terraria.GameContent;
|
||||
using Terraria.GameContent.Liquid;
|
||||
using Terraria.GameInput;
|
||||
using Terraria.Graphics;
|
||||
@@ -74,10 +75,10 @@ namespace CalamityMod.ILEditing
|
||||
|
||||
private static void AlterTownNPCSpawnRate(On.Terraria.Main.orig_UpdateTime_SpawnTownNPCs orig)
|
||||
{
|
||||
int oldWorldRate = Main.worldRate;
|
||||
Main.worldRate *= CalamityConfig.Instance.TownNPCSpawnRateMultiplier;
|
||||
double oldWorldRate = Main.desiredWorldTilesUpdateRate;
|
||||
Main.desiredWorldTilesUpdateRate *= CalamityConfig.Instance.TownNPCSpawnRateMultiplier;
|
||||
orig();
|
||||
Main.worldRate = oldWorldRate;
|
||||
Main.desiredWorldTilesUpdateRate = oldWorldRate;
|
||||
}
|
||||
#endregion Town NPC Spawning Improvements
|
||||
|
||||
@@ -226,12 +227,9 @@ namespace CalamityMod.ILEditing
|
||||
private static bool OpenDoor_LabDoorOverride(On.Terraria.WorldGen.orig_OpenDoor orig, int i, int j, int direction)
|
||||
{
|
||||
Tile tile = Main.tile[i, j];
|
||||
// If the tile is somehow null, that's vanilla's problem, we're outta here
|
||||
if (tile is null)
|
||||
return orig(i, j, direction);
|
||||
|
||||
// If it's one of the two lab doors, use custom code to open the door and sync tiles in multiplayer.
|
||||
else if (tile.TileType == labDoorClosed)
|
||||
if (tile.TileType == labDoorClosed)
|
||||
return OpenLabDoor(tile, i, j, labDoorOpen);
|
||||
else if (tile.TileType == aLabDoorClosed)
|
||||
return OpenLabDoor(tile, i, j, aLabDoorOpen);
|
||||
@@ -245,12 +243,9 @@ namespace CalamityMod.ILEditing
|
||||
private static bool CloseDoor_LabDoorOverride(On.Terraria.WorldGen.orig_CloseDoor orig, int i, int j, bool forced)
|
||||
{
|
||||
Tile tile = Main.tile[i, j];
|
||||
// If the tile is somehow null, that's vanilla's problem, we're outta here
|
||||
if (tile is null)
|
||||
return orig(i, j, forced);
|
||||
|
||||
// If it's one of the two lab doors, use custom code to open the door and sync tiles in multiplayer.
|
||||
else if (tile.TileType == labDoorOpen)
|
||||
if (tile.TileType == labDoorOpen)
|
||||
return CloseLabDoor(tile, i, j, labDoorClosed);
|
||||
else if (tile.TileType == aLabDoorOpen)
|
||||
return CloseLabDoor(tile, i, j, aLabDoorClosed);
|
||||
@@ -299,7 +294,7 @@ namespace CalamityMod.ILEditing
|
||||
{
|
||||
// This is unfortunately not something that can be done via SetDefaults since owner is set
|
||||
// after that method is called. Doing it directly when the projectile is spawned appears to be the only reasonable way.
|
||||
int proj = orig(x, y, xSpeed, ySpeed, type, damage, knockback, owner, ai0, ai1);
|
||||
int proj = orig(spawnSource, x, y, xSpeed, ySpeed, type, damage, knockback, owner, ai0, ai1);
|
||||
Projectile projectile = Main.projectile[proj];
|
||||
if (projectile.minion)
|
||||
{
|
||||
@@ -408,12 +403,7 @@ namespace CalamityMod.ILEditing
|
||||
|
||||
if (Main.LocalPlayer.dead)
|
||||
{
|
||||
Main.SmartInteractShowingGenuine = false;
|
||||
Main.SmartInteractShowingFake = false;
|
||||
Main.SmartInteractNPC = -1;
|
||||
Main.SmartInteractNPCsNearby.Clear();
|
||||
Main.SmartInteractTileCoords.Clear();
|
||||
Main.SmartInteractTileCoordsSelected.Clear();
|
||||
Main.ClearSmartInteract();
|
||||
Main.TileInteractionLX = (Main.TileInteractionHX = (Main.TileInteractionLY = (Main.TileInteractionHY = -1)));
|
||||
}
|
||||
|
||||
@@ -453,17 +443,17 @@ namespace CalamityMod.ILEditing
|
||||
}
|
||||
}
|
||||
|
||||
Main.spriteBatch.Draw(Main.cursorTextures[cursorIndex], drawPosition, null, desaturatedCursorColor, 0f, Vector2.Zero, Main.cursorScale, SpriteEffects.None, 0f);
|
||||
Main.spriteBatch.Draw(TextureAssets.Cursors[cursorIndex].Value, drawPosition, null, desaturatedCursorColor, 0f, Vector2.Zero, Main.cursorScale, SpriteEffects.None, 0f);
|
||||
|
||||
Main.spriteBatch.End();
|
||||
Main.spriteBatch.Begin(SpriteSortMode.Immediate, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.instance.Rasterizer, null, Main.UIScaleMatrix);
|
||||
Main.spriteBatch.Begin(SpriteSortMode.Immediate, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.UIScaleMatrix);
|
||||
GameShaders.Misc["CalamityMod:FireMouse"].UseColor(Color.Red);
|
||||
GameShaders.Misc["CalamityMod:FireMouse"].UseSecondaryColor(Color.Lerp(Color.Red, Color.Orange, 0.75f));
|
||||
GameShaders.Misc["CalamityMod:FireMouse"].Apply();
|
||||
|
||||
Main.spriteBatch.Draw(Main.cursorTextures[cursorIndex], desaturatedDrawPosition, null, cursorColor, 0f, Vector2.Zero, Main.cursorScale * 1.075f, SpriteEffects.None, 0f);
|
||||
Main.spriteBatch.Draw(TextureAssets.Cursors[cursorIndex].Value, desaturatedDrawPosition, null, cursorColor, 0f, Vector2.Zero, Main.cursorScale * 1.075f, SpriteEffects.None, 0f);
|
||||
Main.spriteBatch.End();
|
||||
Main.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.instance.Rasterizer, null, Main.GameViewMatrix.EffectMatrix);
|
||||
Main.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, Main.DefaultSamplerState, DepthStencilState.None, Main.Rasterizer, null, Main.GameViewMatrix.EffectMatrix);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -479,7 +469,7 @@ namespace CalamityMod.ILEditing
|
||||
{
|
||||
cursorColor = Color.White * Main.GamepadCursorAlpha;
|
||||
int frameX = 0;
|
||||
Texture2D smartCursorTexture = Main.cursorTextures[13];
|
||||
Texture2D smartCursorTexture = TextureAssets.Cursors[13].Value;
|
||||
Rectangle frame = smartCursorTexture.Frame(2, 1, frameX, 0);
|
||||
Main.spriteBatch.Draw(smartCursorTexture, baseDrawPosition, frame, cursorColor, 0f, frame.Size() * 0.5f, Main.cursorScale, SpriteEffects.None, 0f);
|
||||
return;
|
||||
@@ -487,7 +477,7 @@ namespace CalamityMod.ILEditing
|
||||
|
||||
// Otherwise draw an ordinary crosshair at the mouse position.
|
||||
cursorColor = Color.White;
|
||||
Texture2D crosshairTexture = Main.cursorTextures[15];
|
||||
Texture2D crosshairTexture = TextureAssets.Cursors[15].Value;
|
||||
Main.spriteBatch.Draw(crosshairTexture, baseDrawPosition, null, cursorColor, 0f, crosshairTexture.Size() * 0.5f, Main.cursorScale, SpriteEffects.None, 0f);
|
||||
}
|
||||
#endregion Fire Cursor Effect for the Calamity Accessory
|
||||
|
||||
@@ -65,13 +65,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.ArcticDivingGear)
|
||||
.AddIngredient<DepthCharm>()
|
||||
.AddIngredient<DepthCells>(10)
|
||||
.AddIngredient<Lumenite>(10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.ArcticDivingGear).
|
||||
AddIngredient<DepthCharm>().
|
||||
AddIngredient<DepthCells>(10).
|
||||
AddIngredient<Lumenite>(10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -69,17 +69,17 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AbyssalDivingGear>()
|
||||
.AddIngredient<AnechoicPlating>()
|
||||
.AddIngredient<IronBoots>()
|
||||
.AddIngredient<MolluskHusk>(15)
|
||||
.AddIngredient<Lumenite>(40)
|
||||
.AddIngredient<DepthCells>(40)
|
||||
.AddIngredient<Tenebris>(15)
|
||||
.AddIngredient(ItemID.LunarBar, 5)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AbyssalDivingGear>().
|
||||
AddIngredient<AnechoicPlating>().
|
||||
AddIngredient<IronBoots>().
|
||||
AddIngredient<MolluskHusk>(15).
|
||||
AddIngredient<Lumenite>(40).
|
||||
AddIngredient<DepthCells>(40).
|
||||
AddIngredient<Tenebris>(15).
|
||||
AddIngredient(ItemID.LunarBar, 5).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -40,15 +40,15 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<MirageMirror>()
|
||||
.AddIngredient<InkBomb>()
|
||||
.AddIngredient(ItemID.SpectreBar, 8)
|
||||
.AddIngredient<SeaPrism>(10)
|
||||
.AddIngredient<DepthCells>(5)
|
||||
.AddIngredient<Lumenite>(5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<MirageMirror>().
|
||||
AddIngredient<InkBomb>().
|
||||
AddIngredient(ItemID.SpectreBar, 8).
|
||||
AddIngredient<SeaPrism>(10).
|
||||
AddIngredient<DepthCells>(5).
|
||||
AddIngredient<Lumenite>(5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,12 +32,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.BottledWater)
|
||||
.AddIngredient(ItemID.BeeWax, 5)
|
||||
.AddIngredient<PlagueCellCluster>(10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.BottledWater).
|
||||
AddIngredient(ItemID.BeeWax, 5).
|
||||
AddIngredient<PlagueCellCluster>(10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -45,17 +45,17 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
}
|
||||
}
|
||||
player.allDamage += 0.1f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<RottenBrain>()
|
||||
.AddIngredient(ItemID.BrainOfConfusion)
|
||||
.AddIngredient(ItemID.SoulofNight, 3)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<RottenBrain>().
|
||||
AddIngredient(ItemID.BrainOfConfusion).
|
||||
AddIngredient(ItemID.SoulofNight, 3).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -36,21 +36,21 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<CorruptFlask>()
|
||||
.AddIngredient<RadiantOoze>()
|
||||
.AddIngredient<VerstaltiteBar>(5)
|
||||
.AddIngredient<SeaPrism>(10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CorruptFlask>().
|
||||
AddIngredient<RadiantOoze>().
|
||||
AddIngredient<VerstaltiteBar>(5).
|
||||
AddIngredient<SeaPrism>(10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
|
||||
CreateRecipe()
|
||||
.AddIngredient<CrimsonFlask>()
|
||||
.AddIngredient<RadiantOoze>()
|
||||
.AddIngredient<VerstaltiteBar>(5)
|
||||
.AddIngredient<SeaPrism>(10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CrimsonFlask>().
|
||||
AddIngredient<RadiantOoze>().
|
||||
AddIngredient<VerstaltiteBar>(5).
|
||||
AddIngredient<SeaPrism>(10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,10 +31,10 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddRecipeGroup("SiltGroup", 100)
|
||||
.AddTile(TileID.Furnaces)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddRecipeGroup("SiltGroup", 100).
|
||||
AddTile(TileID.Furnaces).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -46,16 +46,16 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.FrostsparkBoots)
|
||||
.AddIngredient(ItemID.LavaWaders)
|
||||
.AddIngredient<HarpyRing>()
|
||||
.AddIngredient<EssenceofCinder>(5)
|
||||
.AddIngredient(ItemID.SoulofMight)
|
||||
.AddIngredient(ItemID.SoulofSight)
|
||||
.AddIngredient(ItemID.SoulofFright)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.FrostsparkBoots).
|
||||
AddIngredient(ItemID.LavaWaders).
|
||||
AddIngredient<HarpyRing>().
|
||||
AddIngredient<EssenceofCinder>(5).
|
||||
AddIngredient(ItemID.SoulofMight).
|
||||
AddIngredient(ItemID.SoulofSight).
|
||||
AddIngredient(ItemID.SoulofFright).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -51,7 +51,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.angelicAlliance = true;
|
||||
player.allDamage += 0.08f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.08f;
|
||||
player.GetDamage(DamageClass.Summon) += 0.07f; //7% + 8% = 15%
|
||||
player.maxMinions += 2;
|
||||
if (player.controlJump)
|
||||
@@ -60,16 +60,16 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddRecipeGroup("AnyHallowedHelmet")
|
||||
.AddIngredient(ItemID.HallowedPlateMail)
|
||||
.AddIngredient(ItemID.HallowedGreaves)
|
||||
.AddIngredient(ItemID.PaladinsShield)
|
||||
.AddIngredient(ItemID.TrueExcalibur)
|
||||
.AddIngredient(ItemID.CrossNecklace)
|
||||
.AddIngredient<ShadowspecBar>(5)
|
||||
.AddTile<DraedonsForge>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddRecipeGroup("AnyHallowedHelmet").
|
||||
AddIngredient(ItemID.HallowedPlateMail).
|
||||
AddIngredient(ItemID.HallowedGreaves).
|
||||
AddIngredient(ItemID.PaladinsShield).
|
||||
AddIngredient(ItemID.TrueExcalibur).
|
||||
AddIngredient(ItemID.CrossNecklace).
|
||||
AddIngredient<ShadowspecBar>(5).
|
||||
AddTile<DraedonsForge>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,13 +34,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AncientFossil>()
|
||||
.AddIngredient<DemonicBoneAsh>()
|
||||
.AddIngredient<AncientBoneDust>(3)
|
||||
.AddIngredient(ItemID.Bone, 15)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AncientFossil>().
|
||||
AddIngredient<DemonicBoneAsh>().
|
||||
AddIngredient<AncientBoneDust>(3).
|
||||
AddIngredient(ItemID.Bone, 15).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -82,13 +82,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AsgardsValor>()
|
||||
.AddIngredient<ElysianAegis>()
|
||||
.AddIngredient<CosmiliteBar>(10)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AsgardsValor>().
|
||||
AddIngredient<ElysianAegis>().
|
||||
AddIngredient<CosmiliteBar>(10).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -59,15 +59,15 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.AnkhShield)
|
||||
.AddIngredient<OrnateShield>()
|
||||
.AddIngredient<ShieldoftheOcean>()
|
||||
.AddIngredient<Abaddon>()
|
||||
.AddIngredient<CoreofCalamity>()
|
||||
.AddIngredient(ItemID.LifeFruit, 5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.AnkhShield).
|
||||
AddIngredient<OrnateShield>().
|
||||
AddIngredient<ShieldoftheOcean>().
|
||||
AddIngredient<Abaddon>().
|
||||
AddIngredient<CoreofCalamity>().
|
||||
AddIngredient(ItemID.LifeFruit, 5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -49,12 +49,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<CelestialJewel>()
|
||||
.AddIngredient<DarkPlasma>(3)
|
||||
.AddIngredient(ItemID.LunarBar, 5)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CelestialJewel>().
|
||||
AddIngredient<DarkPlasma>(3).
|
||||
AddIngredient(ItemID.LunarBar, 5).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,11 +34,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.FeralClaws)
|
||||
.AddIngredient<UeliaceBar>(2)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.FeralClaws).
|
||||
AddIngredient<UeliaceBar>(2).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,12 +32,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<BloodSample>(5)
|
||||
.AddIngredient(ItemID.Vertebrae, 4)
|
||||
.AddIngredient(ItemID.CrimtaneBar, 4)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<BloodSample>(5).
|
||||
AddIngredient(ItemID.Vertebrae, 4).
|
||||
AddIngredient(ItemID.CrimtaneBar, 4).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,12 +31,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<BloodyWormTooth>()
|
||||
.AddIngredient(ItemID.WormScarf)
|
||||
.AddIngredient(ItemID.SoulofNight, 3)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<BloodyWormTooth>().
|
||||
AddIngredient(ItemID.WormScarf).
|
||||
AddIngredient(ItemID.SoulofNight, 3).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -46,14 +46,14 @@ namespace CalamityMod.Items.Accessories
|
||||
if (!walkTile.HasTile && walkTile.LiquidAmount == 0 && groundTile != null && WorldGen.SolidTile(groundTile))
|
||||
{
|
||||
walkTile.TileFrameY = 0;
|
||||
walkTile.slope(0);
|
||||
walkTile.Get<TileWallWireStateData>().Slope = SlopeType.Solid;
|
||||
walkTile.halfBrick(false);
|
||||
// On dirt blocks, there's a small chance to grow a dye plant.
|
||||
if (groundTile.TileType == TileID.Dirt)
|
||||
{
|
||||
if (Main.rand.NextBool(1000))
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.DyePlants;
|
||||
walkTile.TileFrameX = (short)(34 * Main.rand.Next(1, 13));
|
||||
while (walkTile.TileFrameX == 144)
|
||||
@@ -69,7 +69,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
if (Main.rand.NextBool(2))
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.Plants;
|
||||
walkTile.TileFrameX = (short)(18 * Main.rand.Next(6, 11));
|
||||
|
||||
@@ -78,7 +78,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
else
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.Plants2;
|
||||
walkTile.TileFrameX = (short)(18 * Main.rand.Next(6, 21));
|
||||
|
||||
@@ -95,7 +95,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
if (Main.rand.NextBool(2))
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.HallowedPlants;
|
||||
walkTile.TileFrameX = (short)(18 * Main.rand.Next(4, 7));
|
||||
while (walkTile.TileFrameX == 90)
|
||||
@@ -103,7 +103,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
else
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.HallowedPlants2;
|
||||
walkTile.TileFrameX = (short)(18 * Main.rand.Next(2, 8));
|
||||
while (walkTile.TileFrameX == 90)
|
||||
@@ -117,7 +117,7 @@ namespace CalamityMod.Items.Accessories
|
||||
// On jungle grass, grow jungle flowers.
|
||||
else if (groundTile.TileType == TileID.JungleGrass)
|
||||
{
|
||||
walkTile.active(true);
|
||||
walkTile.Get<TileWallWireStateData>().HasTile = true;
|
||||
walkTile.TileType = TileID.JunglePlants2;
|
||||
walkTile.TileFrameX = (short)(18 * Main.rand.Next(9, 17));
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
|
||||
//Todo - Check if its trying to replace the other rogue jetpack. If its the case, return true.
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().hasJetpack;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().hasJetpack;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
@@ -52,11 +52,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<PlaguedFuelPack>()
|
||||
.AddIngredient<EffulgentFeather>(8)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<PlaguedFuelPack>().
|
||||
AddIngredient<EffulgentFeather>(8).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,13 +25,13 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().calamityRing;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().calamityRing;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.calamityRing = true;
|
||||
player.allDamage += 0.15f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
player.endurance -= 0.1f;
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
|
||||
@@ -46,13 +46,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<CrownJewel>()
|
||||
.AddIngredient(ItemID.TeleportationPotion, 3)
|
||||
.AddIngredient<AstralJelly>(15)
|
||||
.AddIngredient<SeaPrism>(15)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CrownJewel>().
|
||||
AddIngredient(ItemID.TeleportationPotion, 3).
|
||||
AddIngredient<AstralJelly>(15).
|
||||
AddIngredient<SeaPrism>(15).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -29,11 +29,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.GoldDust, 7)
|
||||
.AddIngredient(ItemID.SpelunkerPotion, 7)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.GoldDust, 7).
|
||||
AddIngredient(ItemID.SpelunkerPotion, 7).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,12 +31,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddRecipeGroup("AnyGoldBar", 4)
|
||||
.AddRecipeGroup("AnyCopperBar", 8)
|
||||
.AddIngredient<Acidwood>(5)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddRecipeGroup("AnyGoldBar", 4).
|
||||
AddRecipeGroup("AnyCopperBar", 8).
|
||||
AddIngredient<Acidwood>(5).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -39,14 +39,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<BloodyWormScarf>()
|
||||
.AddIngredient<BloodPact>()
|
||||
.AddIngredient<FleshTotem>()
|
||||
.AddIngredient<CosmiliteBar>(5)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<BloodyWormScarf>().
|
||||
AddIngredient<BloodPact>().
|
||||
AddIngredient<FleshTotem>().
|
||||
AddIngredient<CosmiliteBar>(5).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,11 +32,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.VilePowder, 15)
|
||||
.AddIngredient(ItemID.RottenChunk, 10)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.VilePowder, 15).
|
||||
AddIngredient(ItemID.RottenChunk, 10).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -27,7 +27,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().dodgeScarf;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().dodgeScarf;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
|
||||
@@ -32,11 +32,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.ViciousPowder, 15)
|
||||
.AddIngredient(ItemID.Vertebrae, 10)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.ViciousPowder, 15).
|
||||
AddIngredient(ItemID.Vertebrae, 10).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -85,14 +85,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<DaedalusEmblem>()
|
||||
.AddIngredient<LeadCore>(3)
|
||||
.AddIngredient<MysteriousCircuitry>(15)
|
||||
.AddIngredient<DubiousPlating>(15)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<DaedalusEmblem>().
|
||||
AddIngredient<LeadCore>(3).
|
||||
AddIngredient<MysteriousCircuitry>(15).
|
||||
AddIngredient<DubiousPlating>(15).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -35,12 +35,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.CelestialStone)
|
||||
.AddIngredient(ItemID.RangerEmblem)
|
||||
.AddIngredient<CoreofCalamity>()
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.CelestialStone).
|
||||
AddIngredient(ItemID.RangerEmblem).
|
||||
AddIngredient<CoreofCalamity>().
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -40,12 +40,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<SilencingSheath>()
|
||||
.AddIngredient<RuinMedallion>()
|
||||
.AddIngredient<MeldiateBar>(5)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<SilencingSheath>().
|
||||
AddIngredient<RuinMedallion>().
|
||||
AddIngredient<MeldiateBar>(5).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -43,11 +43,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<UeliaceBar>(10)
|
||||
.AddIngredient<DarksunFragment>(20)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<UeliaceBar>(10).
|
||||
AddIngredient<DarksunFragment>(20).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,14 +34,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.CharmofMyths)
|
||||
.AddIngredient(ItemID.StarVeil)
|
||||
.AddIngredient<AstralBar>(10)
|
||||
.AddIngredient(ItemID.MeteoriteBar, 10)
|
||||
.AddIngredient<SeaPrism>(15)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.CharmofMyths).
|
||||
AddIngredient(ItemID.StarVeil).
|
||||
AddIngredient<AstralBar>(10).
|
||||
AddIngredient(ItemID.MeteoriteBar, 10).
|
||||
AddIngredient<SeaPrism>(15).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -36,12 +36,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ExodiumClusterOre>(25)
|
||||
.AddIngredient<Elumplate>(25)
|
||||
.AddIngredient<CosmiliteBar>(5)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<ExodiumClusterOre>(25).
|
||||
AddIngredient<Elumplate>(25).
|
||||
AddIngredient<CosmiliteBar>(5).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -50,12 +50,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AbyssalMirror>()
|
||||
.AddIngredient<DarkGodsSheath>()
|
||||
.AddIngredient<DarksunFragment>(20)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AbyssalMirror>().
|
||||
AddIngredient<DarkGodsSheath>().
|
||||
AddIngredient<DarksunFragment>(20).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,12 +34,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ExodiumClusterOre>(25)
|
||||
.AddIngredient<Navyplate>(25)
|
||||
.AddIngredient<Phantoplasm>(5)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<ExodiumClusterOre>(25).
|
||||
AddIngredient<Navyplate>(25).
|
||||
AddIngredient<Phantoplasm>(5).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,19 +34,19 @@ Stealth strikes also have +10 armor penetration, deal 10% more damage, and heal
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<FilthyGlove>()
|
||||
.AddIngredient(ItemID.Wire, 100)
|
||||
.AddRecipeGroup("AnyMythrilBar", 5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<FilthyGlove>().
|
||||
AddIngredient(ItemID.Wire, 100).
|
||||
AddRecipeGroup("AnyMythrilBar", 5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
|
||||
CreateRecipe()
|
||||
.AddIngredient<BloodstainedGlove>()
|
||||
.AddIngredient(ItemID.Wire, 100)
|
||||
.AddRecipeGroup("AnyMythrilBar", 5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<BloodstainedGlove>().
|
||||
AddIngredient(ItemID.Wire, 100).
|
||||
AddRecipeGroup("AnyMythrilBar", 5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -37,14 +37,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.FireGauntlet)
|
||||
.AddIngredient<YharimsInsignia>()
|
||||
.AddIngredient(ItemID.LunarBar, 8)
|
||||
.AddIngredient<GalacticaSingularity>(4)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.FireGauntlet).
|
||||
AddIngredient<YharimsInsignia>().
|
||||
AddIngredient(ItemID.LunarBar, 8).
|
||||
AddIngredient<GalacticaSingularity>(4).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -41,14 +41,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.MagicQuiver)
|
||||
.AddIngredient<DaedalusEmblem>()
|
||||
.AddIngredient(ItemID.LunarBar, 8)
|
||||
.AddIngredient<GalacticaSingularity>(4)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.MagicQuiver).
|
||||
AddIngredient<DaedalusEmblem>().
|
||||
AddIngredient(ItemID.LunarBar, 8).
|
||||
AddIngredient<GalacticaSingularity>(4).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,14 +32,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.FishingPotion)
|
||||
.AddIngredient(ItemID.CratePotion, 8)
|
||||
.AddRecipeGroup("Boss2Material", 5)
|
||||
.AddIngredient<SeaPrism>(10)
|
||||
.AddIngredient<VictideBar>(3)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.FishingPotion).
|
||||
AddIngredient(ItemID.CratePotion, 8).
|
||||
AddRecipeGroup("Boss2Material", 5).
|
||||
AddIngredient<SeaPrism>(10).
|
||||
AddIngredient<VictideBar>(3).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,14 +44,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<SigilofCalamitas>()
|
||||
.AddIngredient(ItemID.ManaFlower)
|
||||
.AddIngredient(ItemID.LunarBar, 8)
|
||||
.AddIngredient<GalacticaSingularity>(4)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<SigilofCalamitas>().
|
||||
AddIngredient(ItemID.ManaFlower).
|
||||
AddIngredient(ItemID.LunarBar, 8).
|
||||
AddIngredient<GalacticaSingularity>(4).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -28,7 +28,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.Calamity().donorItem = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().dodgeScarf;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().dodgeScarf;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
@@ -41,13 +41,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<CounterScarf>()
|
||||
.AddIngredient(ItemID.SoulofNight, 5)
|
||||
.AddIngredient(ItemID.SoulofLight, 5)
|
||||
.AddIngredient(ItemID.Silk, 15)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CounterScarf>().
|
||||
AddIngredient(ItemID.SoulofNight, 5).
|
||||
AddIngredient(ItemID.SoulofLight, 5).
|
||||
AddIngredient(ItemID.Silk, 15).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -24,7 +24,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
if (modPlayer.elementalHeart)
|
||||
|
||||
@@ -53,19 +53,19 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.GoldCrown)
|
||||
.AddIngredient<AerialiteBar>(6)
|
||||
.AddIngredient(ItemID.Feather, 8)
|
||||
.AddTile(TileID.SkyMill)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.GoldCrown).
|
||||
AddIngredient<AerialiteBar>(6).
|
||||
AddIngredient(ItemID.Feather, 8).
|
||||
AddTile(TileID.SkyMill).
|
||||
Register();
|
||||
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.PlatinumCrown)
|
||||
.AddIngredient<AerialiteBar>(6)
|
||||
.AddIngredient(ItemID.Feather, 8)
|
||||
.AddTile(TileID.SkyMill)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.PlatinumCrown).
|
||||
AddIngredient<AerialiteBar>(6).
|
||||
AddIngredient(ItemID.Feather, 8).
|
||||
AddTile(TileID.SkyMill).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,12 +32,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.RottenChunk, 4)
|
||||
.AddIngredient(ItemID.DemoniteBar, 4)
|
||||
.AddIngredient<TrueShadowScale>(5)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.RottenChunk, 4).
|
||||
AddIngredient(ItemID.DemoniteBar, 4).
|
||||
AddIngredient<TrueShadowScale>(5).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -36,13 +36,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.PaladinsShield)
|
||||
.AddIngredient(ItemID.FrozenTurtleShell)
|
||||
.AddIngredient<MolluskHusk>(5)
|
||||
.AddIngredient<CoreofEleum>(5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.PaladinsShield).
|
||||
AddIngredient(ItemID.FrozenTurtleShell).
|
||||
AddIngredient<MolluskHusk>(5).
|
||||
AddIngredient<CoreofEleum>(5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -27,7 +27,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().fungalClump;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().fungalClump;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
if (player.Calamity().gladiatorSword)
|
||||
return false;
|
||||
|
||||
@@ -35,12 +35,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ExodiumClusterOre>(25)
|
||||
.AddIngredient<PlagueContainmentCells>(25)
|
||||
.AddIngredient<HellcasterFragment>(5)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<ExodiumClusterOre>(25).
|
||||
AddIngredient<PlagueContainmentCells>(25).
|
||||
AddIngredient<HellcasterFragment>(5).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -39,14 +39,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ManaJelly>()
|
||||
.AddIngredient<LifeJelly>()
|
||||
.AddIngredient<VitalJelly>()
|
||||
.AddIngredient(ItemID.SoulofLight, 2)
|
||||
.AddIngredient(ItemID.SoulofNight, 2)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<ManaJelly>().
|
||||
AddIngredient<LifeJelly>().
|
||||
AddIngredient<VitalJelly>().
|
||||
AddIngredient(ItemID.SoulofLight, 2).
|
||||
AddIngredient(ItemID.SoulofNight, 2).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -30,14 +30,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<SpiritGenerator>()
|
||||
.AddIngredient(ItemID.HallowedBar, 18)
|
||||
.AddIngredient(ItemID.SoulofFright, 5)
|
||||
.AddIngredient(ItemID.SoulofMight, 5)
|
||||
.AddIngredient(ItemID.SoulofSight, 5)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<SpiritGenerator>().
|
||||
AddIngredient(ItemID.HallowedBar, 18).
|
||||
AddIngredient(ItemID.SoulofFright, 5).
|
||||
AddIngredient(ItemID.SoulofMight, 5).
|
||||
AddIngredient(ItemID.SoulofSight, 5).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,12 +32,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AerialiteBar>(2)
|
||||
.AddIngredient(ItemID.Feather, 5)
|
||||
.AddIngredient(ItemID.FallenStar)
|
||||
.AddTile(TileID.SkyMill)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AerialiteBar>(2).
|
||||
AddIngredient(ItemID.Feather, 5).
|
||||
AddIngredient(ItemID.FallenStar).
|
||||
AddTile(TileID.SkyMill).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -30,7 +30,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.Calamity().customRarity = CalamityRarity.Rainbow;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
if (modPlayer.brimstoneWaifu || modPlayer.sandWaifu || modPlayer.sandBoobWaifu || modPlayer.cloudWaifu || modPlayer.sirenWaifu)
|
||||
@@ -96,14 +96,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<WifeinaBottle>()
|
||||
.AddIngredient<WifeinaBottlewithBoobs>()
|
||||
.AddIngredient<LureofEnthrallment>()
|
||||
.AddIngredient<EyeoftheStorm>()
|
||||
.AddIngredient<RoseStone>()
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<WifeinaBottle>().
|
||||
AddIngredient<WifeinaBottlewithBoobs>().
|
||||
AddIngredient<LureofEnthrallment>().
|
||||
AddIngredient<EyeoftheStorm>().
|
||||
AddIngredient<RoseStone>().
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -54,14 +54,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<LivingDew>()
|
||||
.AddIngredient(ItemID.BottledHoney, 10)
|
||||
.AddIngredient<TrapperBulb>(2)
|
||||
.AddIngredient(ItemID.ButterflyDust)
|
||||
.AddIngredient<BeetleJuice>(3)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<LivingDew>().
|
||||
AddIngredient(ItemID.BottledHoney, 10).
|
||||
AddIngredient<TrapperBulb>(2).
|
||||
AddIngredient(ItemID.ButterflyDust).
|
||||
AddIngredient<BeetleJuice>(3).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,7 +33,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.Calamity().donorItem = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().howlsHeart;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().howlsHeart;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
|
||||
@@ -32,13 +32,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<WulfrumBattery>()
|
||||
.AddIngredient<VoltaicJelly>()
|
||||
.AddIngredient<PurifiedGel>(10)
|
||||
.AddIngredient<StormlionMandible>(2)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<WulfrumBattery>().
|
||||
AddIngredient<VoltaicJelly>().
|
||||
AddIngredient<PurifiedGel>(10).
|
||||
AddIngredient<StormlionMandible>(2).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -35,11 +35,11 @@ namespace CalamityMod.Items.Accessories
|
||||
if (!Collision.DrownCollision(player.position, player.width, player.height, player.gravDir))
|
||||
{
|
||||
player.endurance += 0.05f;
|
||||
player.allDamage += 0.05f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.05f;
|
||||
}
|
||||
else
|
||||
{
|
||||
player.allDamage += 0.1f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
player.statDefense += 10;
|
||||
player.moveSpeed += 0.3f;
|
||||
}
|
||||
|
||||
@@ -36,12 +36,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.Bezoar)
|
||||
.AddIngredient(ItemID.Vine, 2)
|
||||
.AddIngredient<MurkyPaste>(5)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.Bezoar).
|
||||
AddIngredient(ItemID.Vine, 2).
|
||||
AddIngredient<MurkyPaste>(5).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -39,13 +39,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AbyssalAmulet>()
|
||||
.AddIngredient<Lumenite>(15)
|
||||
.AddIngredient<Tenebris>(5)
|
||||
.AddIngredient<SeaPrism>(10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AbyssalAmulet>().
|
||||
AddIngredient<Lumenite>(15).
|
||||
AddIngredient<Tenebris>(5).
|
||||
AddIngredient<SeaPrism>(10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,7 +25,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
if (modPlayer.elementalHeart)
|
||||
|
||||
@@ -34,19 +34,19 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.MagicMirror)
|
||||
.AddIngredient(ItemID.BlackLens)
|
||||
.AddIngredient(ItemID.Bone, 50)
|
||||
.AddTile(TileID.TinkerersWorkbench)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.MagicMirror).
|
||||
AddIngredient(ItemID.BlackLens).
|
||||
AddIngredient(ItemID.Bone, 50).
|
||||
AddTile(TileID.TinkerersWorkbench).
|
||||
Register();
|
||||
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.IceMirror)
|
||||
.AddIngredient(ItemID.BlackLens)
|
||||
.AddIngredient(ItemID.Bone, 50)
|
||||
.AddTile(TileID.TinkerersWorkbench)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.IceMirror).
|
||||
AddIngredient(ItemID.BlackLens).
|
||||
AddIngredient(ItemID.Bone, 50).
|
||||
AddTile(TileID.TinkerersWorkbench).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -56,12 +56,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<FeatherCrown>()
|
||||
.AddIngredient(ItemID.LunarBar, 5)
|
||||
.AddIngredient<GalacticaSingularity>(5)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<FeatherCrown>().
|
||||
AddIngredient(ItemID.LunarBar, 5).
|
||||
AddIngredient<GalacticaSingularity>(5).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -56,16 +56,16 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<RogueEmblem>()
|
||||
.AddIngredient<RaidersTalisman>()
|
||||
.AddIngredient<MoonstoneCrown>()
|
||||
.AddIngredient<ElectriciansGlove>()
|
||||
.AddIngredient(ItemID.LunarBar, 8)
|
||||
.AddIngredient<GalacticaSingularity>(4)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<RogueEmblem>().
|
||||
AddIngredient<RaidersTalisman>().
|
||||
AddIngredient<MoonstoneCrown>().
|
||||
AddIngredient<ElectriciansGlove>().
|
||||
AddIngredient(ItemID.LunarBar, 8).
|
||||
AddIngredient<GalacticaSingularity>(4).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -39,7 +39,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
modPlayer.nCore = true;
|
||||
player.allDamage += 0.1f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
int damage = (int)(250 * player.AverageDamage());
|
||||
float knockBack = 3f;
|
||||
if (Main.rand.NextBool(15))
|
||||
|
||||
@@ -33,11 +33,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.AvengerEmblem)
|
||||
.AddIngredient<DraedonBar>(2)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.AvengerEmblem).
|
||||
AddIngredient<DraedonBar>(2).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -42,14 +42,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<StarTaintedGenerator>()
|
||||
.AddIngredient<StatisCurse>()
|
||||
.AddIngredient(ItemID.LunarBar, 8)
|
||||
.AddIngredient<GalacticaSingularity>(4)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile(ModContent.TileType<CosmicAnvil>())
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<StarTaintedGenerator>().
|
||||
AddIngredient<StatisCurse>().
|
||||
AddIngredient(ItemID.LunarBar, 8).
|
||||
AddIngredient<GalacticaSingularity>(4).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,13 +44,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<HeartofDarkness>()
|
||||
.AddIngredient<Laudanum>()
|
||||
.AddIngredient<StressPills>()
|
||||
.AddIngredient<NightmareFuel>(20)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<HeartofDarkness>().
|
||||
AddIngredient<Laudanum>().
|
||||
AddIngredient<StressPills>().
|
||||
AddIngredient<NightmareFuel>(20).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,11 +44,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<VerstaltiteBar>(5)
|
||||
.AddIngredient(ItemID.CrystalShard, 10)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<VerstaltiteBar>(5).
|
||||
AddIngredient(ItemID.CrystalShard, 10).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -37,13 +37,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<HallowedRune>()
|
||||
.AddIngredient<RuinousSoul>(5)
|
||||
.AddIngredient<BloodOrb>(10)
|
||||
.AddIngredient<ExodiumClusterOre>(20)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<HallowedRune>().
|
||||
AddIngredient<RuinousSoul>(5).
|
||||
AddIngredient<BloodOrb>(10).
|
||||
AddIngredient<ExodiumClusterOre>(20).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -26,11 +26,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<AlchemicalFlask>()
|
||||
.AddIngredient(ItemID.HoneyComb)
|
||||
.AddTile(TileID.LunarCraftingStation)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<AlchemicalFlask>().
|
||||
AddIngredient(ItemID.HoneyComb).
|
||||
AddTile(TileID.LunarCraftingStation).
|
||||
Register();
|
||||
}
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
|
||||
//Todo : Check if the slot contains the other rogue jetpack, in which case, let the player swap accs
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().hasJetpack;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().hasJetpack;
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.Calamity().donorItem = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
return !player.Calamity().pArtifact;
|
||||
}
|
||||
@@ -45,12 +45,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ExodiumClusterOre>(25)
|
||||
.AddIngredient<Chaosplate>(25)
|
||||
.AddIngredient<DivineGeode>(5)
|
||||
.AddTile(TileID.DemonAltar)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<ExodiumClusterOre>(25).
|
||||
AddIngredient<Chaosplate>(25).
|
||||
AddIngredient<DivineGeode>(5).
|
||||
AddTile(TileID.DemonAltar).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -111,7 +111,12 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
if (player.whoAmI != Main.myPlayer)
|
||||
return false;
|
||||
int weaponType = item.melee ? 1 : item.ranged ? 2 : item.magic ? 3 : item.Calamity().rogue ? 4 : -1;
|
||||
|
||||
var source = player.GetProjectileSource_Item(item);
|
||||
int weaponType = item.CountsAsClass<MeleeDamageClass>() ? 1 :
|
||||
item.CountsAsClass<RangedDamageClass>() ? 2 :
|
||||
item.CountsAsClass<MagicDamageClass>() ? 3 :
|
||||
item.Calamity().rogue ? 4 : -1;
|
||||
if (weaponType > 0)
|
||||
{
|
||||
if (player.Calamity().profanedSoulWeaponType != weaponType || player.Calamity().profanedSoulWeaponUsage >= 300)
|
||||
@@ -123,7 +128,7 @@ namespace CalamityMod.Items.Accessories
|
||||
correctedVelocity.Normalize();
|
||||
bool shouldNerf = player.Calamity().endoCooper || player.Calamity().magicHat; //No bonkers damage memes thank you very much.
|
||||
bool enrage = player.statLife <= (int)(player.statLifeMax2 * 0.5);
|
||||
if (item.melee)
|
||||
if (item.CountsAsClass<MeleeDamageClass>())
|
||||
{
|
||||
if (player.Calamity().profanedSoulWeaponUsage % (enrage ? 4 : 6) == 0)
|
||||
{
|
||||
@@ -137,7 +142,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
Vector2 perturbedspeed = new Vector2(correctedVelocity.X, correctedVelocity.Y + Main.rand.Next(-3, 4)).RotatedBy(MathHelper.ToRadians(spread));
|
||||
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y - 10, perturbedspeed.X, perturbedspeed.Y, ModContent.ProjectileType<ProfanedCrystalMeleeSpear>(), (int)((shouldNerf ? 175 : 350) * player.MinionDamage()), 1f, player.whoAmI, Main.rand.NextBool(player.Calamity().profanedSoulWeaponUsage == 4 ? 5 : 7) ? 1f : 0f);
|
||||
Projectile.NewProjectile(source, player.Center.X, player.Center.Y - 10, perturbedspeed.X, perturbedspeed.Y, ModContent.ProjectileType<ProfanedCrystalMeleeSpear>(), (int)((shouldNerf ? 175 : 350) * player.MinionDamage()), 1f, player.whoAmI, Main.rand.NextBool(player.Calamity().profanedSoulWeaponUsage == 4 ? 5 : 7) ? 1f : 0f);
|
||||
spread -= Main.rand.Next(2, 4);
|
||||
SoundEngine.PlaySound(SoundID.Item20, player.Center);
|
||||
}
|
||||
@@ -145,7 +150,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
else
|
||||
{
|
||||
Projectile.NewProjectile(player.Center, correctedVelocity * 6.9f, ModContent.ProjectileType<ProfanedCrystalMeleeSpear>(), (int)((shouldNerf ? 125 : 250) * player.MinionDamage()), 1f, player.whoAmI, Main.rand.NextBool(player.Calamity().profanedSoulWeaponUsage == 4 ? 5 : 7) ? 1f : 0f, 1f);
|
||||
Projectile.NewProjectile(source, player.Center, correctedVelocity * 6.9f, ModContent.ProjectileType<ProfanedCrystalMeleeSpear>(), (int)((shouldNerf ? 125 : 250) * player.MinionDamage()), 1f, player.whoAmI, Main.rand.NextBool(player.Calamity().profanedSoulWeaponUsage == 4 ? 5 : 7) ? 1f : 0f, 1f);
|
||||
SoundEngine.PlaySound(SoundID.Item20, player.Center);
|
||||
}
|
||||
|
||||
@@ -153,7 +158,7 @@ namespace CalamityMod.Items.Accessories
|
||||
player.Calamity().profanedSoulWeaponUsage++;
|
||||
|
||||
}
|
||||
else if (item.ranged)
|
||||
else if (item.CountsAsClass<RangedDamageClass>())
|
||||
{
|
||||
if (enrage || Main.rand.NextBool(2)) //100% chance if 50% or lower, else 1 in 2 chance
|
||||
{
|
||||
@@ -167,12 +172,12 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
case 1: //big boomer
|
||||
case 2: //boomer
|
||||
int proj = Projectile.NewProjectile(player.Center, perturbedspeed, ModContent.ProjectileType<ProfanedCrystalRangedHuges>(), dam, 0f, player.whoAmI, projType == 1 ? 1f : 0f);
|
||||
int proj = Projectile.NewProjectile(source, player.Center, perturbedspeed, ModContent.ProjectileType<ProfanedCrystalRangedHuges>(), dam, 0f, player.whoAmI, projType == 1 ? 1f : 0f);
|
||||
if (proj.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[proj].Calamity().forceMinion = true;
|
||||
break;
|
||||
case 3: //bab boomer
|
||||
int proj2 = Projectile.NewProjectile(player.Center, perturbedspeed, ModContent.ProjectileType<ProfanedCrystalRangedSmalls>(), dam, 0f, player.whoAmI, 0f);
|
||||
int proj2 = Projectile.NewProjectile(source, player.Center, perturbedspeed, ModContent.ProjectileType<ProfanedCrystalRangedSmalls>(), dam, 0f, player.whoAmI, 0f);
|
||||
if (proj2.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[proj2].Calamity().forceMinion = true;
|
||||
break;
|
||||
@@ -183,7 +188,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (item.magic)
|
||||
else if (item.CountsAsClass<MagicDamageClass>())
|
||||
{
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<ProfanedCrystalMageFireball>()] == 0 && player.ownedProjectileCounts[ModContent.ProjectileType<ProfanedCrystalMageFireballSplit>()] == 0)
|
||||
{
|
||||
@@ -209,7 +214,7 @@ namespace CalamityMod.Items.Accessories
|
||||
int sickPenalty = (int)(dam * (0.05f * ((player.buffTime[player.FindBuffIndex(BuffID.ManaSickness)] + 60) / 60)));
|
||||
dam -= sickPenalty;
|
||||
}
|
||||
int proj = Projectile.NewProjectile(player.position, correctedVelocity, ModContent.ProjectileType<ProfanedCrystalMageFireball>(), dam, 1f, player.whoAmI, enrage ? 1f : 0f);
|
||||
int proj = Projectile.NewProjectile(source, player.position, correctedVelocity, ModContent.ProjectileType<ProfanedCrystalMageFireball>(), dam, 1f, player.whoAmI, enrage ? 1f : 0f);
|
||||
if (proj.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[proj].Calamity().forceMinion = true;
|
||||
player.Calamity().profanedSoulWeaponUsage = enrage ? 20 : 25;
|
||||
@@ -229,7 +234,7 @@ namespace CalamityMod.Items.Accessories
|
||||
for (float i = 0; i < crystalCount; i++)
|
||||
{
|
||||
float angle = MathHelper.TwoPi / crystalCount * i;
|
||||
int proj = Projectile.NewProjectile(player.Center, angle.ToRotationVector2() * 8f, ModContent.ProjectileType<ProfanedCrystalRogueShard>(), (int)((shouldNerf ? 88 : 176) * player.MinionDamage()), 1f, player.whoAmI, 0f, 0f);
|
||||
int proj = Projectile.NewProjectile(source, player.Center, angle.ToRotationVector2() * 8f, ModContent.ProjectileType<ProfanedCrystalRogueShard>(), (int)((shouldNerf ? 88 : 176) * player.MinionDamage()), 1f, player.whoAmI, 0f, 0f);
|
||||
if (proj.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[proj].Calamity().forceMinion = true;
|
||||
SoundEngine.PlaySound(SoundID.Item20, player.Center);
|
||||
@@ -239,7 +244,7 @@ namespace CalamityMod.Items.Accessories
|
||||
else if (player.Calamity().profanedSoulWeaponUsage % (enrage ? 5 : 10) == 0)
|
||||
{
|
||||
float angle = MathHelper.TwoPi / (enrage ? 9 : 18) * (player.Calamity().profanedSoulWeaponUsage / (enrage ? 1 : 10));
|
||||
int proj = Projectile.NewProjectile(player.Center, angle.ToRotationVector2() * 8f, ModContent.ProjectileType<ProfanedCrystalRogueShard>(), (int)((shouldNerf ? 110 : 220) * player.MinionDamage()), 1f, player.whoAmI, 1f, 0f);
|
||||
int proj = Projectile.NewProjectile(source, player.Center, angle.ToRotationVector2() * 8f, ModContent.ProjectileType<ProfanedCrystalRogueShard>(), (int)((shouldNerf ? 110 : 220) * player.MinionDamage()), 1f, player.whoAmI, 1f, 0f);
|
||||
if (proj.WithinBounds(Main.maxProjectiles))
|
||||
Main.projectile[proj].Calamity().forceMinion = true;
|
||||
SoundEngine.PlaySound(SoundID.Item20, player.Center);
|
||||
@@ -252,32 +257,28 @@ namespace CalamityMod.Items.Accessories
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<ProfanedSoulArtifact>()
|
||||
.AddIngredient(ItemID.ObsidianRose)
|
||||
.AddIngredient<CoreofCinder>(5)
|
||||
.AddIngredient<UeliaceBar>(25)
|
||||
.AddIngredient<DivineGeode>(50)
|
||||
.AddIngredient<UnholyEssence>(100)
|
||||
.AddIngredient<ShadowspecBar>(5)
|
||||
.AddTile<ProfanedBasin>()
|
||||
.Register();
|
||||
}
|
||||
}
|
||||
|
||||
public class PSCRecipe : ModRecipe
|
||||
{
|
||||
public PSCRecipe(Mod mod) : base(mod) { }
|
||||
|
||||
public override int ConsumeItem(int type, int numRequired)
|
||||
public static void MakeRecipesCheaper(Recipe recipe, int type, ref int numRequired)
|
||||
{
|
||||
int shadowSpec = ModContent.ItemType<ShadowspecBar>();
|
||||
int geode = ModContent.ItemType<DivineGeode>();
|
||||
int essence = ModContent.ItemType<UnholyEssence>();
|
||||
bool biomePower = Main.LocalPlayer.ZoneHoly || Main.LocalPlayer.ZoneUnderworldHeight;
|
||||
return biomePower && (type == (shadowSpec | geode | essence)) ? numRequired / 2 : numRequired; //cuts the above mats consumed by half if in the biomes instead of arbitrary biome locking
|
||||
bool biomePower = Main.LocalPlayer.ZoneHallow || Main.LocalPlayer.ZoneUnderworldHeight;
|
||||
numRequired = biomePower && (type == (shadowSpec | geode | essence)) ? numRequired / 2 : numRequired; //cuts the above mats consumed by half if in the biomes instead of arbitrary biome locking
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe().
|
||||
AddIngredient<ProfanedSoulArtifact>().
|
||||
AddIngredient(ItemID.ObsidianRose).
|
||||
AddIngredient<CoreofCinder>(5).
|
||||
AddIngredient<UeliaceBar>(25).
|
||||
AddIngredient<DivineGeode>(50).
|
||||
AddIngredient<UnholyEssence>(100).
|
||||
AddIngredient<ShadowspecBar>(5).
|
||||
AddTile<ProfanedBasin>().
|
||||
AddConsumeItemCallback(MakeRecipesCheaper).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -29,11 +29,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<EbonianGel>(45)
|
||||
.AddIngredient<PurifiedGel>(15)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<EbonianGel>(45).
|
||||
AddIngredient<PurifiedGel>(15).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,11 +44,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.Leather, 5)
|
||||
.AddIngredient(ItemID.Obsidian, 20)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.Leather, 5).
|
||||
AddIngredient(ItemID.Obsidian, 20).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -43,15 +43,15 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<FrigidBulwark>()
|
||||
.AddIngredient<DeificAmulet>()
|
||||
.AddIngredient<GalacticaSingularity>(5)
|
||||
.AddIngredient<DivineGeode>(10)
|
||||
.AddIngredient<CosmiliteBar>(10)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<FrigidBulwark>().
|
||||
AddIngredient<DeificAmulet>().
|
||||
AddIngredient<GalacticaSingularity>(5).
|
||||
AddIngredient<DivineGeode>(10).
|
||||
AddIngredient<CosmiliteBar>(10).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -26,20 +26,20 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
player.allDamage += 0.15f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.15f;
|
||||
player.armorPenetration += 15;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<SandSharkToothNecklace>()
|
||||
.AddIngredient<ReaperTooth>(6)
|
||||
.AddIngredient<Lumenite>(15)
|
||||
.AddIngredient<DepthCells>(15)
|
||||
.AddIngredient<Tenebris>(5)
|
||||
.AddTile(TileID.TinkerersWorkbench)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<SandSharkToothNecklace>().
|
||||
AddIngredient<ReaperTooth>(6).
|
||||
AddIngredient<Lumenite>(15).
|
||||
AddIngredient<DepthCells>(15).
|
||||
AddIngredient<Tenebris>(5).
|
||||
AddTile(TileID.TinkerersWorkbench).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,7 +25,7 @@ namespace CalamityMod.Items.Accessories
|
||||
Item.accessory = true;
|
||||
}
|
||||
|
||||
public override bool CanEquipAccessory(Player player, int slot)
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded)
|
||||
{
|
||||
CalamityPlayer modPlayer = player.Calamity();
|
||||
if (modPlayer.elementalHeart)
|
||||
|
||||
@@ -34,12 +34,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<CoinofDeceit>()
|
||||
.AddIngredient<UnholyCore>(4)
|
||||
.AddIngredient<EssenceofChaos>(2)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<CoinofDeceit>().
|
||||
AddIngredient<UnholyCore>(4).
|
||||
AddIngredient<EssenceofChaos>(2).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -30,11 +30,11 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<SulfuricScale>(20)
|
||||
.AddRecipeGroup("IronBar", 10)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<SulfuricScale>(20).
|
||||
AddRecipeGroup("IronBar", 10).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -24,18 +24,18 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void UpdateAccessory(Player player, bool hideVisual)
|
||||
{
|
||||
player.allDamage += 0.06f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.06f;
|
||||
player.armorPenetration += 10;
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.SharkToothNecklace)
|
||||
.AddIngredient(ItemID.AvengerEmblem)
|
||||
.AddIngredient<GrandScale>()
|
||||
.AddTile(TileID.TinkerersWorkbench)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.SharkToothNecklace).
|
||||
AddIngredient(ItemID.AvengerEmblem).
|
||||
AddIngredient<GrandScale>().
|
||||
AddTile(TileID.TinkerersWorkbench).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -55,16 +55,9 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
|
||||
// Not overriding these Clones makes tooltips fail to function correctly due to HoverItem spaghetti.
|
||||
public override ModItem Clone()
|
||||
{
|
||||
var clone = (ShatteredCommunity)base.Clone();
|
||||
clone.level = level;
|
||||
clone.totalRageDamage = totalRageDamage;
|
||||
return clone;
|
||||
}
|
||||
public override ModItem Clone(Item item)
|
||||
{
|
||||
var clone = (ShatteredCommunity)base.Clone();
|
||||
var clone = (ShatteredCommunity)base.Clone(Item);
|
||||
clone.level = level;
|
||||
clone.totalRageDamage = totalRageDamage;
|
||||
return clone;
|
||||
@@ -79,7 +72,7 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
// Shattered Community gives (mostly) the same boosts as normal Community
|
||||
// It does not give melee speed or minion knockback, but always gives life regen (instead of only conditionally)
|
||||
player.allDamage += 0.1f;
|
||||
player.GetDamage<GenericDamageClass>() += 0.1f;
|
||||
modPlayer.AllCritBoost(5);
|
||||
player.statDefense += 10;
|
||||
player.endurance += 0.05f;
|
||||
@@ -91,7 +84,7 @@ namespace CalamityMod.Items.Accessories
|
||||
}
|
||||
|
||||
// Community and Shattered Community are mutually exclusive
|
||||
public override bool CanEquipAccessory(Player player, int slot) => !player.Calamity().community;
|
||||
public override bool CanEquipAccessory(Player player, int slot, bool modded) => !player.Calamity().community;
|
||||
public override bool CanUseItem(Player player) => false;
|
||||
|
||||
// Produces purple light while in the world.
|
||||
@@ -115,7 +108,7 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
Item acc = player.armor[i];
|
||||
if (acc.type == thisItemID)
|
||||
sc = acc.modItem as ShatteredCommunity;
|
||||
sc = acc.ModItem as ShatteredCommunity;
|
||||
}
|
||||
|
||||
// Safety check in case for some reason the equipped Shattered Community isn't found.
|
||||
@@ -136,9 +129,10 @@ namespace CalamityMod.Items.Accessories
|
||||
private void LevelUpEffects(Player player)
|
||||
{
|
||||
// Spawn the purple laser beam from failing the Dungeon Defenders event.
|
||||
var source = player.GetProjectileSource_Accessory(Item);
|
||||
int projID = ProjectileID.DD2ElderWins;
|
||||
Vector2 offset = new Vector2(0f, 800f); // The effect is extremely tall, so start it very low down
|
||||
Projectile fx = Projectile.NewProjectileDirect(player.Center + offset, Vector2.Zero, projID, 0, 0f, player.whoAmI);
|
||||
Projectile fx = Projectile.NewProjectileDirect(source, player.Center + offset, Vector2.Zero, projID, 0, 0f, player.whoAmI);
|
||||
fx.friendly = false;
|
||||
fx.hostile = false;
|
||||
// On the 108th update, crystal debris is spawned, so we avoid that.
|
||||
@@ -194,7 +188,6 @@ namespace CalamityMod.Items.Accessories
|
||||
{
|
||||
tag.Add("level", level);
|
||||
tag.Add("totalDamage", totalRageDamage);
|
||||
return tag;
|
||||
}
|
||||
|
||||
public override void LoadData(TagCompound tag)
|
||||
|
||||
@@ -43,11 +43,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<VictideBar>(5)
|
||||
.AddIngredient(ItemID.Coral, 5)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<VictideBar>(5).
|
||||
AddIngredient(ItemID.Coral, 5).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -36,14 +36,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.CelestialEmblem)
|
||||
.AddRecipeGroup("AnyEvilWater", 10)
|
||||
.AddIngredient<CalamityDust>(5)
|
||||
.AddIngredient<CoreofChaos>(5)
|
||||
.AddIngredient<CruptixBar>(2)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.CelestialEmblem).
|
||||
AddRecipeGroup("AnyEvilWater", 10).
|
||||
AddIngredient<CalamityDust>(5).
|
||||
AddIngredient<CoreofChaos>(5).
|
||||
AddIngredient<CruptixBar>(2).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,12 +33,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddRecipeGroup("AnyEvilBar", 8)
|
||||
.AddIngredient(ItemID.Silk, 10)
|
||||
.AddRecipeGroup("Boss2Material", 3)
|
||||
.AddTile(TileID.TinkerersWorkbench)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddRecipeGroup("AnyEvilBar", 8).
|
||||
AddIngredient(ItemID.Silk, 10).
|
||||
AddRecipeGroup("Boss2Material", 3).
|
||||
AddTile(TileID.TinkerersWorkbench).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,11 +31,11 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient(ItemID.Diamond, 5)
|
||||
.AddIngredient(ItemID.IronBar, 15)
|
||||
.AddTile(TileID.Anvils)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient(ItemID.Diamond, 5).
|
||||
AddIngredient(ItemID.IronBar, 15).
|
||||
AddTile(TileID.Anvils).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -70,14 +70,14 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<TheAbsorber>()
|
||||
.AddIngredient<MysteriousCircuitry>(10)
|
||||
.AddIngredient<DubiousPlating>(20)
|
||||
.AddIngredient<CosmiliteBar>(5)
|
||||
.AddIngredient<AscendantSpiritEssence>(4)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<TheAbsorber>().
|
||||
AddIngredient<MysteriousCircuitry>(10).
|
||||
AddIngredient<DubiousPlating>(20).
|
||||
AddIngredient<CosmiliteBar>(5).
|
||||
AddIngredient<AscendantSpiritEssence>(4).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,13 +34,13 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<JellyChargedBattery>()
|
||||
.AddIngredient<NuclearRod>()
|
||||
.AddIngredient<StarbusterCore>()
|
||||
.AddIngredient<BarofLife>(3)
|
||||
.AddTile(TileID.MythrilAnvil)
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<JellyChargedBattery>().
|
||||
AddIngredient<NuclearRod>().
|
||||
AddIngredient<StarbusterCore>().
|
||||
AddIngredient<BarofLife>(3).
|
||||
AddTile(TileID.MythrilAnvil).
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -44,12 +44,12 @@ namespace CalamityMod.Items.Accessories
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe()
|
||||
.AddIngredient<StatisNinjaBelt>()
|
||||
.AddIngredient<TwistingNether>(10)
|
||||
.AddIngredient<NightmareFuel>(20)
|
||||
.AddTile<CosmicAnvil>()
|
||||
.Register();
|
||||
CreateRecipe().
|
||||
AddIngredient<StatisNinjaBelt>().
|
||||
AddIngredient<TwistingNether>(10).
|
||||
AddIngredient<NightmareFuel>(20).
|
||||
AddTile<CosmicAnvil>().
|
||||
Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
Loaded 100 of 1013 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user