After some thought, Nullification Pistol's effects EXCEPT scale work while a boss is alive again

Scale was the only effect that was truly broken at all with bosses using this thing. Removing the rest of the weapon's gimmick for bosses feels very awkward and unsatisfying. Personally I'm in the camp that that the scale really should be considered a feature too but that is beyond my jurisdiction at this point.
This commit is contained in:
CongratsIsTrash committed 2024-05-17 01:22:51 -04:00
1 parent 6560e30859
commit bf9d8ac229
2 files changed
+70 -72

No files matched your search

+32 -32
View File
@@ -45,44 +45,44 @@ namespace CalamityMod.Projectiles.Ranged
public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone)
{
if (target.type == NPCID.TargetDummy || CalamityPlayer.areThereAnyDamnBosses || CalamityLists.AquaticScourgeIDs.Contains(target.type))
if (target.type == NPCID.TargetDummy)
{
return;
}
int nullBuff = Main.rand.Next(7);
int randAmt = (CalamityPlayer.areThereAnyDamnBosses || CalamityLists.AquaticScourgeIDs.Contains(target.type)) ? 6 : 8;
int nullBuff = Main.rand.Next(randAmt);
if (!target.boss)
{
if (nullBuff == 0)
switch (nullBuff)
{
target.scale *= 2f;
}
else if (nullBuff == 1)
{
target.scale *= 0.5f;
}
else if (nullBuff == 2 && target.type != ModContent.NPCType<SuperDummyNPC>())
{
target.damage += 10;
}
else if (nullBuff == 3)
{
target.damage -= 10;
}
else if (nullBuff == 4)
{
target.knockBackResist = 0f;
}
else if (nullBuff == 5)
{
target.knockBackResist = 1f;
}
else if (nullBuff == 6)
{
target.defense += 5;
}
else
{
target.defense -= 5;
case 0:
if (target.type != ModContent.NPCType<SuperDummyNPC>())
target.damage += 10;
break;
case 1:
target.damage -= 10;
break;
case 2:
target.knockBackResist = 0f;
break;
case 3:
target.knockBackResist = 1f;
break;
case 4:
target.defense += 5;
break;
case 5:
target.defense -= 5;
break;
case 6:
target.scale *= 2f;
break;
case 7:
target.scale *= 0.5f;
break;
default:
break;
}
}
}
+38 -40
View File
@@ -45,52 +45,50 @@ namespace CalamityMod.Projectiles.Ranged
public override void OnHitNPC(NPC target, NPC.HitInfo hit, int damageDone)
{
if (target.type == NPCID.TargetDummy || CalamityPlayer.areThereAnyDamnBosses || CalamityLists.AquaticScourgeIDs.Contains(target.type))
if (target.type == NPCID.TargetDummy)
{
return;
}
int nullBuff = Main.rand.Next(10);
int randAmt = (CalamityPlayer.areThereAnyDamnBosses || CalamityLists.AquaticScourgeIDs.Contains(target.type)) ? 8 : 10;
int nullBuff = Main.rand.Next(randAmt);
if (!target.boss)
{
if (nullBuff == 0)
switch (nullBuff)
{
target.scale *= 5f;
}
else if (nullBuff == 1)
{
target.scale *= 0.1f;
}
else if (nullBuff == 2 && target.type != ModContent.NPCType<SuperDummyNPC>())
{
target.damage += 20;
}
else if (nullBuff == 3)
{
target.damage -= 20;
}
else if (nullBuff == 4)
{
target.knockBackResist = 0f;
}
else if (nullBuff == 5)
{
target.knockBackResist = 1f;
}
else if (nullBuff == 6)
{
target.defense += 10;
}
else if (nullBuff == 7)
{
target.defense -= 10;
}
else if (nullBuff == 8)
{
target.velocity.Y = Main.rand.NextBool() ? 30f : -30f;
}
else
{
target.velocity.X = Main.rand.NextBool() ? 30f : -30f;
case 0:
if (target.type != ModContent.NPCType<SuperDummyNPC>())
target.damage += 20;
break;
case 1:
target.damage -= 20;
break;
case 2:
target.knockBackResist = 0f;
break;
case 3:
target.knockBackResist = 1f;
break;
case 4:
target.defense += 10;
break;
case 5:
target.defense -= 10;
break;
case 6:
target.velocity.Y = Main.rand.NextBool() ? 30f : -30f;
break;
case 7:
target.velocity.X = Main.rand.NextBool() ? 30f : -30f;
break;
case 8:
target.scale *= 5f;
break;
case 9:
target.scale *= 0.1f;
break;
default:
break;
}
}
}