Merge branch 'master' of https://github.com/UncleDanny/CalamityMod
This commit is contained in:
commit
14563443fa
35 files changed
+119
-362
No files matched your search
@@ -2414,7 +2414,7 @@ namespace CalamityMod.CalPlayer
|
||||
double deltaAngle = spread / 8f;
|
||||
double offsetAngle;
|
||||
int i;
|
||||
int damage = 800;
|
||||
int damage = (int)(800 * player.RangedDamage());
|
||||
if (player.whoAmI == Main.myPlayer)
|
||||
{
|
||||
for (i = 0; i < 8; i++)
|
||||
@@ -2533,7 +2533,7 @@ namespace CalamityMod.CalPlayer
|
||||
}
|
||||
gaelRageCooldown = 60 * GaelsGreatsword.SkullsplosionCooldownSeconds;
|
||||
float rageRatio = (float)stress / stressMax;
|
||||
int damage = (int)(rageRatio * GaelsGreatsword.MaxRageBoost * GaelsGreatsword.BaseDamage);
|
||||
int damage = (int)(rageRatio * GaelsGreatsword.MaxRageBoost * GaelsGreatsword.BaseDamage * player.MeleeDamage());
|
||||
float skullCount = 5f;
|
||||
float skullSpeed = 5f;
|
||||
if (CalamityWorld.downedYharon)
|
||||
|
||||
@@ -505,8 +505,7 @@ namespace CalamityMod.CalPlayer
|
||||
bool immunityToHotAndCold = hasMoltenSet || player.magmaStone || player.frostArmor || modPlayer.fBulwark || modPlayer.fBarrier ||
|
||||
modPlayer.frostFlare || modPlayer.rampartOfDeities || modPlayer.cryogenSoul || modPlayer.snowman || modPlayer.blazingCore || modPlayer.permafrostsConcoction || modPlayer.profanedCrystalBuffs || modPlayer.coldDivinity;
|
||||
|
||||
bool immunityToCold = player.HasBuff(BuffID.Campfire) || Main.campfire || player.resistCold || modPlayer.eskimoSet || player.buffImmune[BuffID.Frozen] ||
|
||||
player.HasBuff(BuffID.Inferno) || immunityToHotAndCold || modPlayer.externalColdImmunity;
|
||||
bool immunityToCold = player.HasBuff(BuffID.Campfire) || Main.campfire || player.resistCold || modPlayer.eskimoSet || player.buffImmune[BuffID.Frozen] || modPlayer.aAmpoule || player.HasBuff(BuffID.Inferno) || immunityToHotAndCold || modPlayer.externalColdImmunity;
|
||||
|
||||
bool immunityToHot = player.lavaImmune || player.lavaRose || player.lavaMax > 0 || immunityToHotAndCold || modPlayer.externalHeatImmunity;
|
||||
|
||||
|
||||
+2
-280
@@ -15,6 +15,7 @@ using CalamityMod.Items.Fishing.FishingRods;
|
||||
using CalamityMod.Items.Fishing.SunkenSeaCatches;
|
||||
using CalamityMod.Items.LoreItems;
|
||||
using CalamityMod.Items.Materials;
|
||||
using CalamityMod.Items.Placeables;
|
||||
using CalamityMod.Items.Placeables.Furniture.Trophies;
|
||||
using CalamityMod.Items.TreasureBags;
|
||||
using CalamityMod.Items.Tools;
|
||||
@@ -64,23 +65,6 @@ using CalamityMod.Projectiles.Ranged;
|
||||
using CalamityMod.Projectiles.Rogue;
|
||||
using CalamityMod.Projectiles.Typeless;
|
||||
using CalamityMod.Skies;
|
||||
using CalamityMod.Tiles.Abyss;
|
||||
using CalamityMod.Tiles.Furniture;
|
||||
using CalamityMod.Tiles.Furniture.CraftingStations;
|
||||
using CalamityMod.Tiles.FurnitureAbyss;
|
||||
using CalamityMod.Tiles.FurnitureAncient;
|
||||
using CalamityMod.Tiles.FurnitureAshen;
|
||||
using CalamityMod.Tiles.FurnitureBotanic;
|
||||
using CalamityMod.Tiles.FurnitureCosmilite;
|
||||
using CalamityMod.Tiles.FurnitureEutrophic;
|
||||
using CalamityMod.Tiles.FurnitureOccult;
|
||||
using CalamityMod.Tiles.FurniturePlaguedPlate;
|
||||
using CalamityMod.Tiles.FurnitureProfaned;
|
||||
using CalamityMod.Tiles.FurnitureSilva;
|
||||
using CalamityMod.Tiles.FurnitureStatigel;
|
||||
using CalamityMod.Tiles.FurnitureStratus;
|
||||
using CalamityMod.Tiles.FurnitureVoid;
|
||||
using CalamityMod.Tiles.SunkenSea;
|
||||
using CalamityMod.UI;
|
||||
using CalamityMod.World;
|
||||
using Microsoft.Xna.Framework;
|
||||
@@ -182,10 +166,6 @@ namespace CalamityMod
|
||||
public static List<int> trapProjectileList;
|
||||
public static List<int> scopedWeaponList;
|
||||
public static List<int> trueMeleeBoostExceptionList;
|
||||
public static List<int> tableList;
|
||||
public static List<int> chairList;
|
||||
public static List<int> lightList;
|
||||
public static List<int> doorList;
|
||||
public static List<int> boomerangList;
|
||||
public static List<int> javelinList;
|
||||
public static List<int> daggerList;
|
||||
@@ -395,10 +375,6 @@ namespace CalamityMod
|
||||
trapProjectileList = null;
|
||||
scopedWeaponList = null;
|
||||
trueMeleeBoostExceptionList = null;
|
||||
tableList = null;
|
||||
chairList = null;
|
||||
lightList = null;
|
||||
doorList = null;
|
||||
boomerangList = null;
|
||||
javelinList = null;
|
||||
daggerList = null;
|
||||
@@ -2326,7 +2302,7 @@ namespace CalamityMod
|
||||
ModContent.ItemType<VictoryShard>(),
|
||||
ModContent.ItemType<AeroStone>(),
|
||||
ModContent.ItemType<DukesDecapitator>(),
|
||||
ModContent.ItemType<Items.Placeables.SulphurousSand>(),
|
||||
ModContent.ItemType<SulphurousSand>(),
|
||||
ModContent.ItemType<MagnumRounds>(),
|
||||
ModContent.ItemType<GrenadeRounds>(),
|
||||
ModContent.ItemType<ExplosiveShells>(),
|
||||
@@ -2362,260 +2338,6 @@ namespace CalamityMod
|
||||
ItemID.SuperHealingPotion
|
||||
};
|
||||
|
||||
tableList = new List<int>()
|
||||
{
|
||||
ModContent.TileType<AbyssBath>(),
|
||||
ModContent.TileType<AbyssBookcase>(),
|
||||
ModContent.TileType<AbyssDresser>(),
|
||||
ModContent.TileType<AbyssPiano>(),
|
||||
ModContent.TileType<AbyssTable>(),
|
||||
ModContent.TileType<AbyssWorkbench>(),
|
||||
ModContent.TileType<AncientBath>(),
|
||||
ModContent.TileType<AncientBookcase>(),
|
||||
ModContent.TileType<AncientDresser>(),
|
||||
ModContent.TileType<AncientPiano>(),
|
||||
ModContent.TileType<AncientTable>(),
|
||||
ModContent.TileType<AncientWorkbench>(),
|
||||
ModContent.TileType<AshenBath>(),
|
||||
ModContent.TileType<AshenBookcase>(),
|
||||
ModContent.TileType<AshenDresser>(),
|
||||
ModContent.TileType<AshenPiano>(),
|
||||
ModContent.TileType<AshenTable>(),
|
||||
ModContent.TileType<AshenWorkbench>(),
|
||||
ModContent.TileType<BotanicBathtub>(),
|
||||
ModContent.TileType<BotanicBookcase>(),
|
||||
ModContent.TileType<BotanicDresser>(),
|
||||
ModContent.TileType<BotanicPiano>(),
|
||||
ModContent.TileType<BotanicTable>(),
|
||||
ModContent.TileType<BotanicWorkBench>(),
|
||||
ModContent.TileType<CosmiliteBath>(),
|
||||
ModContent.TileType<CosmiliteBookcase>(),
|
||||
ModContent.TileType<CosmiliteDresser>(),
|
||||
ModContent.TileType<CosmilitePiano>(),
|
||||
ModContent.TileType<CosmiliteTable>(),
|
||||
ModContent.TileType<CosmiliteWorkbench>(),
|
||||
ModContent.TileType<EutrophicBathtub>(),
|
||||
ModContent.TileType<EutrophicBookcase>(),
|
||||
ModContent.TileType<EutrophicDresser>(),
|
||||
ModContent.TileType<EutrophicPiano>(),
|
||||
ModContent.TileType<EutrophicTable>(),
|
||||
ModContent.TileType<EutrophicWorkBench>(),
|
||||
ModContent.TileType<OccultBathtub>(),
|
||||
ModContent.TileType<OccultBookcase>(),
|
||||
ModContent.TileType<OccultDresser>(),
|
||||
ModContent.TileType<OccultPiano>(),
|
||||
ModContent.TileType<OccultTable>(),
|
||||
ModContent.TileType<OccultWorkBench>(),
|
||||
ModContent.TileType<PlaguedPlateBathtub>(),
|
||||
ModContent.TileType<PlaguedPlateBookcase>(),
|
||||
ModContent.TileType<PlaguedPlateDresser>(),
|
||||
ModContent.TileType<PlaguedPlatePiano>(),
|
||||
ModContent.TileType<PlaguedPlateTable>(),
|
||||
ModContent.TileType<PlaguedPlateWorkbench>(),
|
||||
ModContent.TileType<ProfanedBath>(),
|
||||
ModContent.TileType<ProfanedBookcase>(),
|
||||
ModContent.TileType<ProfanedDresser>(),
|
||||
ModContent.TileType<ProfanedPiano>(),
|
||||
ModContent.TileType<ProfanedTable>(),
|
||||
ModContent.TileType<ProfanedWorkbench>(),
|
||||
ModContent.TileType<SilvaBathtub>(),
|
||||
ModContent.TileType<SilvaBookcase>(),
|
||||
ModContent.TileType<SilvaDresser>(),
|
||||
ModContent.TileType<SilvaPiano>(),
|
||||
ModContent.TileType<SilvaTable>(),
|
||||
ModContent.TileType<SilvaWorkBench>(),
|
||||
ModContent.TileType<StatigelBath>(),
|
||||
ModContent.TileType<StatigelBookcase>(),
|
||||
ModContent.TileType<StatigelDresser>(),
|
||||
ModContent.TileType<StatigelPiano>(),
|
||||
ModContent.TileType<StatigelTable>(),
|
||||
ModContent.TileType<StatigelWorkbench>(),
|
||||
ModContent.TileType<StratusBathtub>(),
|
||||
ModContent.TileType<StratusBookcase>(),
|
||||
ModContent.TileType<StratusDresser>(),
|
||||
ModContent.TileType<StratusPiano>(),
|
||||
ModContent.TileType<StratusTable>(),
|
||||
ModContent.TileType<StratusWorkbench>(),
|
||||
ModContent.TileType<VoidBath>(),
|
||||
ModContent.TileType<VoidBookcase>(),
|
||||
ModContent.TileType<VoidDresser>(),
|
||||
ModContent.TileType<VoidPiano>(),
|
||||
ModContent.TileType<VoidTable>(),
|
||||
ModContent.TileType<VoidWorkbench>()
|
||||
};
|
||||
|
||||
chairList = new List<int>()
|
||||
{
|
||||
ModContent.TileType<AbyssBed>(),
|
||||
ModContent.TileType<AbyssChair>(),
|
||||
ModContent.TileType<AbyssSofa>(),
|
||||
ModContent.TileType<AncientBed>(),
|
||||
ModContent.TileType<AncientChair>(),
|
||||
ModContent.TileType<AncientSofa>(),
|
||||
ModContent.TileType<AshenBed>(),
|
||||
ModContent.TileType<AshenChair>(),
|
||||
ModContent.TileType<AshenSofa>(),
|
||||
ModContent.TileType<BotanicBed>(),
|
||||
ModContent.TileType<BotanicBench>(),
|
||||
ModContent.TileType<BotanicChair>(),
|
||||
ModContent.TileType<CosmiliteBed>(),
|
||||
ModContent.TileType<CosmiliteChair>(),
|
||||
ModContent.TileType<CosmiliteSofa>(),
|
||||
ModContent.TileType<EutrophicBed>(),
|
||||
ModContent.TileType<EutrophicBench>(),
|
||||
ModContent.TileType<EutrophicChair>(),
|
||||
ModContent.TileType<OccultBed>(),
|
||||
ModContent.TileType<OccultChair>(),
|
||||
ModContent.TileType<OccultSofa>(),
|
||||
ModContent.TileType<PlaguedPlateBed>(),
|
||||
ModContent.TileType<PlaguedPlateChair>(),
|
||||
ModContent.TileType<PlaguedPlateSofa>(),
|
||||
ModContent.TileType<ProfanedBed>(),
|
||||
ModContent.TileType<ProfanedChair>(),
|
||||
ModContent.TileType<ProfanedBench>(),
|
||||
ModContent.TileType<SilvaBed>(),
|
||||
ModContent.TileType<SilvaChair>(),
|
||||
ModContent.TileType<SilvaBench>(),
|
||||
ModContent.TileType<StatigelBed>(),
|
||||
ModContent.TileType<StatigelChair>(),
|
||||
ModContent.TileType<StatigelSofa>(),
|
||||
ModContent.TileType<StratusBed>(),
|
||||
ModContent.TileType<StratusChair>(),
|
||||
ModContent.TileType<StratusSofa>(),
|
||||
ModContent.TileType<VoidBed>(),
|
||||
ModContent.TileType<VoidChair>(),
|
||||
ModContent.TileType<VoidSofa>()
|
||||
};
|
||||
|
||||
lightList = new List<int>()
|
||||
{
|
||||
ModContent.TileType<BlueCandle>(),
|
||||
ModContent.TileType<ChaosCandle>(),
|
||||
ModContent.TileType<LumenylCrystals>(),
|
||||
ModContent.TileType<PinkCandle>(),
|
||||
ModContent.TileType<PurpleCandle>(),
|
||||
ModContent.TileType<TranquilityCandle>(),
|
||||
ModContent.TileType<YellowCandle>(),
|
||||
ModContent.TileType<SeaPrismCrystals>(),
|
||||
|
||||
ModContent.TileType<AbyssCandelabra>(),
|
||||
ModContent.TileType<AbyssCandle>(),
|
||||
ModContent.TileType<AbyssChandelier>(),
|
||||
ModContent.TileType<AbyssLamp>(),
|
||||
ModContent.TileType<AbyssLantern>(),
|
||||
ModContent.TileType<AbyssTorch>(),
|
||||
ModContent.TileType<AncientAltar>(),
|
||||
ModContent.TileType<AncientBasin>(),
|
||||
ModContent.TileType<AncientChandelier>(),
|
||||
ModContent.TileType<AncientLamp>(),
|
||||
ModContent.TileType<AncientLantern>(),
|
||||
ModContent.TileType<AshenAltar>(),
|
||||
ModContent.TileType<AshenBasin>(),
|
||||
ModContent.TileType<AshenChandelier>(),
|
||||
ModContent.TileType<AshenCandle>(),
|
||||
ModContent.TileType<AshenCandelabra>(),
|
||||
ModContent.TileType<AshenLamp>(),
|
||||
ModContent.TileType<AshenLantern>(),
|
||||
ModContent.TileType<BotanicCandle>(),
|
||||
ModContent.TileType<BotanicCandelabra>(),
|
||||
ModContent.TileType<BotanicChandelier>(),
|
||||
ModContent.TileType<BotanicLamp>(),
|
||||
ModContent.TileType<BotanicLantern>(),
|
||||
ModContent.TileType<BotanicPlanter>(),
|
||||
ModContent.TileType<CosmiliteBasinTile>(),
|
||||
ModContent.TileType<CosmiliteCandle>(),
|
||||
ModContent.TileType<CosmiliteCandelabra>(),
|
||||
ModContent.TileType<CosmiliteChandelier>(),
|
||||
ModContent.TileType<CosmiliteLamp>(),
|
||||
ModContent.TileType<CosmiliteLantern>(),
|
||||
ModContent.TileType<CosmiliteSconce>(),
|
||||
ModContent.TileType<EutrophicCandle>(),
|
||||
ModContent.TileType<EutrophicCandelabra>(),
|
||||
ModContent.TileType<EutrophicChandelier>(),
|
||||
ModContent.TileType<EutrophicLamp>(),
|
||||
ModContent.TileType<EutrophicLantern>(),
|
||||
ModContent.TileType<PlaguedPlateBasin>(),
|
||||
ModContent.TileType<PlaguedPlateCandle>(),
|
||||
ModContent.TileType<PlaguedPlateCandelabra>(),
|
||||
ModContent.TileType<PlaguedPlateChandelier>(),
|
||||
ModContent.TileType<PlaguedPlateLamp>(),
|
||||
ModContent.TileType<PlaguedPlateLantern>(),
|
||||
ModContent.TileType<OccultCandle>(),
|
||||
ModContent.TileType<OccultCandelabra>(),
|
||||
ModContent.TileType<OccultChandelier>(),
|
||||
ModContent.TileType<OccultLamp>(),
|
||||
ModContent.TileType<OccultLantern>(),
|
||||
ModContent.TileType<ProfanedBasin>(),
|
||||
ModContent.TileType<ProfanedCandle>(),
|
||||
ModContent.TileType<ProfanedCandelabra>(),
|
||||
ModContent.TileType<ProfanedChandelier>(),
|
||||
ModContent.TileType<ProfanedLamp>(),
|
||||
ModContent.TileType<ProfanedLantern>(),
|
||||
ModContent.TileType<SilvaBasin>(),
|
||||
ModContent.TileType<SilvaCandle>(),
|
||||
ModContent.TileType<SilvaCandelabra>(),
|
||||
ModContent.TileType<SilvaChandelier>(),
|
||||
ModContent.TileType<SilvaLamp>(),
|
||||
ModContent.TileType<SilvaLantern>(),
|
||||
ModContent.TileType<StatigelChandelier>(),
|
||||
ModContent.TileType<StatigelCandle>(),
|
||||
ModContent.TileType<StatigelCandelabra>(),
|
||||
ModContent.TileType<StatigelLamp>(),
|
||||
ModContent.TileType<StatigelLantern>(),
|
||||
ModContent.TileType<StratusCandle>(),
|
||||
ModContent.TileType<StratusCandelabra>(),
|
||||
ModContent.TileType<StratusChandelier>(),
|
||||
ModContent.TileType<StratusLantern>(),
|
||||
ModContent.TileType<StratusLamp>(),
|
||||
ModContent.TileType<VoidCandle>(),
|
||||
ModContent.TileType<VoidCandelabra>(),
|
||||
ModContent.TileType<VoidChandelier>(),
|
||||
ModContent.TileType<VoidLamp>(),
|
||||
ModContent.TileType<VoidLantern>()
|
||||
};
|
||||
|
||||
doorList = new List<int>()
|
||||
{
|
||||
ModContent.TileType<AbyssDoorOpen>(),
|
||||
ModContent.TileType<AbyssDoorClosed>(),
|
||||
ModContent.TileType<AncientDoorOpen>(),
|
||||
ModContent.TileType<AncientDoorClosed>(),
|
||||
ModContent.TileType<AshenDoorClosed>(),
|
||||
ModContent.TileType<AshenDoorOpen>(),
|
||||
ModContent.TileType<AshenPlatform>(),
|
||||
ModContent.TileType<BotanicDoorOpen>(),
|
||||
ModContent.TileType<BotanicDoorClosed>(),
|
||||
ModContent.TileType<BotanicPlatform>(),
|
||||
ModContent.TileType<CosmiliteDoorOpen>(),
|
||||
ModContent.TileType<CosmiliteDoorClosed>(),
|
||||
ModContent.TileType<CosmilitePlatform>(),
|
||||
ModContent.TileType<EutrophicDoorOpen>(),
|
||||
ModContent.TileType<EutrophicDoorClosed>(),
|
||||
ModContent.TileType<EutrophicPlatform>(),
|
||||
ModContent.TileType<OccultDoorOpen>(),
|
||||
ModContent.TileType<OccultDoorClosed>(),
|
||||
ModContent.TileType<OccultPlatform>(),
|
||||
ModContent.TileType<PlaguedPlateDoorOpen>(),
|
||||
ModContent.TileType<PlaguedPlateDoorClosed>(),
|
||||
ModContent.TileType<PlaguedPlatePlatform>(),
|
||||
ModContent.TileType<ProfanedDoorOpen>(),
|
||||
ModContent.TileType<ProfanedDoorClosed>(),
|
||||
ModContent.TileType<ProfanedPlatform>(),
|
||||
ModContent.TileType<SilvaDoorOpen>(),
|
||||
ModContent.TileType<SilvaDoorClosed>(),
|
||||
ModContent.TileType<SilvaPlatform>(),
|
||||
ModContent.TileType<SmoothAbyssGravelPlatform>(),
|
||||
ModContent.TileType<SmoothVoidstonePlatform>(),
|
||||
ModContent.TileType<StratusDoorOpen>(),
|
||||
ModContent.TileType<StratusDoorClosed>(),
|
||||
ModContent.TileType<StatigelPlatform>(),
|
||||
ModContent.TileType<StatigelDoorOpen>(),
|
||||
ModContent.TileType<StatigelDoorClosed>(),
|
||||
ModContent.TileType<StratusPlatform>(),
|
||||
ModContent.TileType<VoidDoorOpen>(),
|
||||
ModContent.TileType<VoidDoorClosed>()
|
||||
};
|
||||
|
||||
zombieList = new List<int>()
|
||||
{
|
||||
NPCID.Zombie,
|
||||
|
||||
@@ -37,12 +37,6 @@ namespace CalamityMod.Items.Armor
|
||||
player.Calamity().hydrothermalSmoke = true;
|
||||
}
|
||||
|
||||
public override void DrawHair(ref bool drawHair, ref bool drawAltHair)
|
||||
{
|
||||
drawHair = true;
|
||||
drawAltHair = true;
|
||||
}
|
||||
|
||||
public override void UpdateArmorSet(Player player)
|
||||
{
|
||||
player.setBonus = "5% increased ranged damage\n" +
|
||||
|
||||
@@ -57,7 +57,7 @@ namespace CalamityMod.Items.Armor
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<ChaosSpirit>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<ChaosSpirit>(), (int)(190f * player.MinionDamage()), 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<ChaosSpirit>(), (int)(190f * player.MinionDamage()), 0f, Main.myPlayer, 38f, 0f);
|
||||
}
|
||||
}
|
||||
player.minionDamage += 0.4f;
|
||||
|
||||
@@ -76,7 +76,7 @@ namespace CalamityMod.Items.Armor
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<SilvaCrystal>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<SilvaCrystal>(), (int)(3000f * (player.allDamage + player.minionDamage - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<SilvaCrystal>(), (int)(3000f * player.MinionDamage()), 0f, Main.myPlayer, -20f, 0f);
|
||||
}
|
||||
if (player.FindBuffIndex(ModContent.BuffType<Mechworm>()) == -1)
|
||||
{
|
||||
@@ -105,7 +105,7 @@ namespace CalamityMod.Items.Armor
|
||||
{
|
||||
maxMinionScale = 10;
|
||||
}
|
||||
int damage = (int)(35 * (((player.allDamage + player.minionDamage - 1f) * 5 / 3) + ((player.allDamage + player.minionDamage - 1f) * 0.46f * (maxMinionScale - 1))));
|
||||
int damage = (int)(35 * ((player.MinionDamage() * 5 / 3) + (player.MinionDamage() * 0.46f * (maxMinionScale - 1))));
|
||||
Vector2 vector2 = player.RotatedRelativePoint(player.MountedCenter, true);
|
||||
Vector2 value = Vector2.UnitX.RotatedBy((double)player.fullRotation, default);
|
||||
Vector2 vector3 = Main.MouseWorld - vector2;
|
||||
|
||||
@@ -51,7 +51,7 @@ namespace CalamityMod.Items.Armor
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<DaedalusCrystal>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<DaedalusCrystal>(), (int)(95f * (player.allDamage + player.minionDamage - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<DaedalusCrystal>(), (int)(95f * player.MinionDamage()), 0f, Main.myPlayer, 50f, 0f);
|
||||
}
|
||||
}
|
||||
player.minionDamage += 0.2f;
|
||||
|
||||
@@ -95,7 +95,7 @@ namespace CalamityMod.Items.Armor
|
||||
num18 = (float)num17 / num18;
|
||||
num15 *= num18;
|
||||
num16 *= num18;
|
||||
int num19 = Projectile.NewProjectile(x, y, num15, num16, ModContent.ProjectileType<TheSyringeCinder>(), 40,4f, player.whoAmI, 0f, 0f);
|
||||
int num19 = Projectile.NewProjectile(x, y, num15, num16, ModContent.ProjectileType<TheSyringeCinder>(), (int)(40 * player.RangedDamage()),4f, player.whoAmI, 0f, 0f);
|
||||
Main.projectile[num19].Calamity().rogue = false;
|
||||
Main.projectile[num19].ai[1] = player.position.Y;
|
||||
}
|
||||
|
||||
@@ -52,7 +52,7 @@ namespace CalamityMod.Items.Armor
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<ReaverOrb>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<ReaverOrb>(), (int)(80f * (player.allDamage + player.minionDamage - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<ReaverOrb>(), (int)(80f * player.MinionDamage()), 0f, Main.myPlayer, 50f, 0f);
|
||||
}
|
||||
}
|
||||
player.minionDamage += 0.16f;
|
||||
|
||||
@@ -61,7 +61,7 @@ namespace CalamityMod.Items.Armor
|
||||
}
|
||||
if (player.ownedProjectileCounts[ModContent.ProjectileType<SilvaCrystal>()] < 1)
|
||||
{
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<SilvaCrystal>(), (int)(1500f * (player.allDamage + player.minionDamage - 1f)), 0f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(player.Center.X, player.Center.Y, 0f, -1f, ModContent.ProjectileType<SilvaCrystal>(), (int)(1500f * player.MinionDamage()), 0f, Main.myPlayer, -20f, 0f);
|
||||
}
|
||||
}
|
||||
player.minionDamage += 0.75f;
|
||||
|
||||
@@ -21,8 +21,8 @@ namespace CalamityMod.Items.Weapons.Ranged
|
||||
item.width = 30;
|
||||
item.height = 38;
|
||||
item.crit += 20;
|
||||
item.useTime = 60;
|
||||
item.useAnimation = 60;
|
||||
item.useTime = 45;
|
||||
item.useAnimation = 45;
|
||||
item.useStyle = 5;
|
||||
item.noMelee = true;
|
||||
item.knockBack = 6f;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Rogue
|
||||
{
|
||||
item.width = 26;
|
||||
item.height = 16;
|
||||
item.damage = 15;
|
||||
item.damage = 14;
|
||||
item.thrown = true;
|
||||
item.noMelee = true;
|
||||
item.noUseGraphic = true;
|
||||
@@ -42,7 +42,7 @@ namespace CalamityMod.Items.Weapons.Rogue
|
||||
if (player.Calamity().StealthStrikeAvailable()) //setting the stealth strike
|
||||
{
|
||||
int spread = 3;
|
||||
for (int i = 0; i < 7; i++)
|
||||
for (int i = 0; i < 5; i++)
|
||||
{
|
||||
Vector2 perturbedspeed = new Vector2(speedX + Main.rand.Next(-3,4), speedY + Main.rand.Next(-3,4)).RotatedBy(MathHelper.ToRadians(spread));
|
||||
int proj = Projectile.NewProjectile(position.X, position.Y, perturbedspeed.X, perturbedspeed.Y, ModContent.ProjectileType<SnapClamStealth>(), damage, knockBack, player.whoAmI, 0f, 0f);
|
||||
|
||||
@@ -12,12 +12,13 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Entropy's Vigil");
|
||||
Tooltip.SetDefault("Summons Calamitas and her brothers to protect you");
|
||||
Tooltip.SetDefault("Summons Calamitas and her brothers to protect you\n" +
|
||||
"One minion trio takes two minion slots");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 27;
|
||||
item.damage = 35;
|
||||
item.mana = 10;
|
||||
item.width = 62;
|
||||
item.height = 62;
|
||||
|
||||
@@ -13,7 +13,8 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Ethereal Subjugator");
|
||||
Tooltip.SetDefault("Summons a phantom to protect you");
|
||||
Tooltip.SetDefault("Summons a phantom to protect you\n" +
|
||||
"Each phantom takes only half of a minion slot");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
|
||||
@@ -11,10 +11,8 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Gamma Heart");
|
||||
Tooltip.SetDefault("Summons a horrible head that's attached to you\n" +
|
||||
"If more than seven heads exist, nuclear canisters appear somewhere in the screen view sometimes\n" +
|
||||
"Canisters appear more commonly the more heads exist\n" +
|
||||
"When a head touches a canister, it is consumed, and 7 existing heads begin firing a laser beam");
|
||||
Tooltip.SetDefault("Summons radioactive heads that are bound by your body\n" +
|
||||
"If the entity already exists, using this item again will cause it to gain more heads");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
|
||||
@@ -11,7 +11,8 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Herring Staff");
|
||||
Tooltip.SetDefault("Summons a herring to fight for you");
|
||||
Tooltip.SetDefault("Summons a herring to fight for you\n" +
|
||||
"Each herring takes only half of a minion slot");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
item.damage = 25;
|
||||
item.damage = 38;
|
||||
item.mana = 10;
|
||||
item.width = 46;
|
||||
item.height = 46;
|
||||
|
||||
@@ -836,7 +836,7 @@ namespace CalamityMod
|
||||
sAssociation.Call("AddMinionInfo", ItemType<SunGodStaff>(), BuffType<SolarSpiritGod>(), ProjectileType<SolarGod>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<DormantBrimseeker>(), BuffType<DormantBrimseekerBuff>(), ProjectileType<DormantBrimseekerBab>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<IgneousExaltation>(), BuffType<IgneousExaltationBuff>(), ProjectileType<IgneousBlade>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<BlightedEyeStaff>(), BuffType<CalamitasEyes>(), new List<int>() { ProjectileType<Calamitamini>(), ProjectileType<Cataclymini>(), ProjectileType<Catastromini>()}, new List<float>() {1f-0.6666666f, 0.3333333f, 0.3333333f});
|
||||
sAssociation.Call("AddMinionInfo", ItemType<BlightedEyeStaff>(), BuffType<CalamitasEyes>(), new List<int>() { ProjectileType<Calamitamini>(), ProjectileType<Cataclymini>(), ProjectileType<Catastromini>()}, new List<float>() {1-(1f/3f), 2f/3f, 2f/3f});
|
||||
//Entropy's Vigil is a bruh moment
|
||||
sAssociation.Call("AddMinionInfo", ItemType<PlantationStaff>(), BuffType<PlantationBuff>(), ProjectileType<PlantSummon>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<SandSharknadoStaff>(), BuffType<Sandnado>(), ProjectileType<SandnadoMinion>());
|
||||
@@ -850,6 +850,7 @@ namespace CalamityMod
|
||||
sAssociation.Call("AddMinionInfo", ItemType<Cosmilamp>(), BuffType<CosmilampBuff>(), ProjectileType<CosmilampMinion>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<EtherealSubjugator>(), BuffType<Phantom>(), ProjectileType<PhantomGuy>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<CalamarisLament>(), BuffType<Calamari>(), ProjectileType<CalamariMinion>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<GammaHeart>(), BuffType<GammaHeadBuff>(), ProjectileType<GammaHead>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<StaffoftheMechworm>(), BuffType<Mechworm>(), ProjectileType<MechwormBody>(), 1f);
|
||||
sAssociation.Call("AddMinionInfo", ItemType<CorvidHarbringerStaff>(), BuffType<CorvidHarbringerBuff>(), ProjectileType<PowerfulRaven>());
|
||||
sAssociation.Call("AddMinionInfo", ItemType<EndoHydraStaff>(), BuffType<EndoHydraBuff>(), ProjectileType<EndoHydraHead>());
|
||||
|
||||
@@ -3445,6 +3445,8 @@ namespace CalamityMod.NPCs
|
||||
}
|
||||
else if (projectile.type == ModContent.ProjectileType<BrimstoneSwordExplosion>())
|
||||
{
|
||||
if (projectile.penetrate == -1)
|
||||
projectile.penetrate = 5;
|
||||
damage = (int)(damage * 0.1);
|
||||
}
|
||||
}
|
||||
@@ -3460,6 +3462,8 @@ namespace CalamityMod.NPCs
|
||||
}
|
||||
else if (projectile.type == ModContent.ProjectileType<BrimstoneSwordExplosion>())
|
||||
{
|
||||
if (projectile.penetrate == -1)
|
||||
projectile.penetrate = 5;
|
||||
damage = (int)(damage * 0.1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,11 +62,11 @@ namespace CalamityMod.Projectiles.Hybrid
|
||||
float num370 = projectile.velocity.X / 3f * (float)num369;
|
||||
float num371 = projectile.velocity.Y / 3f * (float)num369;
|
||||
int num372 = Dust.NewDust(projectile.position, projectile.width, projectile.height, dustType, 0f, 0f, 0, default, 1f);
|
||||
Main.dust[num372].position.X = projectile.Center.X - num370;
|
||||
Main.dust[num372].position.Y = projectile.Center.Y - num371;
|
||||
Dust dust = Main.dust[num372];
|
||||
dust.position.X = projectile.Center.X - num370;
|
||||
dust.position.Y = projectile.Center.Y - num371;
|
||||
dust.velocity *= 0f;
|
||||
Main.dust[num372].scale = 0.5f;
|
||||
dust.scale = 0.5f;
|
||||
}
|
||||
projectile.rotation = (float)Math.Atan2((double)projectile.velocity.Y, (double)projectile.velocity.X) - 1.57f;
|
||||
float num373 = projectile.position.X;
|
||||
|
||||
@@ -63,7 +63,7 @@ namespace CalamityMod.Projectiles.Rogue
|
||||
if (openClam)
|
||||
{
|
||||
onEnemy = true;
|
||||
CalamityUtils.ModifyHitNPCSticky(projectile, 7, false);
|
||||
CalamityUtils.ModifyHitNPCSticky(projectile, 5, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using CalamityMod.Buffs.DamageOverTime;
|
||||
using CalamityMod.Dusts;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
@@ -21,7 +22,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minion = true;
|
||||
projectile.minionSlots = 0f;
|
||||
projectile.penetrate = 1;
|
||||
projectile.penetrate = -1;
|
||||
projectile.extraUpdates = 3;
|
||||
projectile.timeLeft = 50;
|
||||
}
|
||||
@@ -45,7 +46,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
num296 = 0.75f;
|
||||
}
|
||||
projectile.ai[0] += 1f;
|
||||
int num297 = 235;
|
||||
int num297 = (int)CalamityDusts.Brimstone;
|
||||
if (Main.rand.NextBool(2))
|
||||
{
|
||||
for (int num298 = 0; num298 < 1; num298++)
|
||||
@@ -77,6 +78,12 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
|
||||
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
||||
{
|
||||
target.immune[projectile.owner] = 9;
|
||||
target.AddBuff(ModContent.BuffType<BrimstoneFlames>(), 120);
|
||||
}
|
||||
|
||||
public override void OnHitPvp(Player target, int damage, bool crit)
|
||||
{
|
||||
target.AddBuff(ModContent.BuffType<BrimstoneFlames>(), 120);
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
projectile.width = 32;
|
||||
projectile.width = 2;
|
||||
projectile.height = 2;
|
||||
projectile.aiStyle = 1;
|
||||
aiType = ProjectileID.DeathLaser;
|
||||
@@ -43,6 +43,11 @@ namespace CalamityMod.Projectiles.Summon
|
||||
target.AddBuff(ModContent.BuffType<BrimstoneFlames>(), 120);
|
||||
}
|
||||
|
||||
public override void OnHitPvp(Player target, int damage, bool crit)
|
||||
{
|
||||
target.AddBuff(ModContent.BuffType<BrimstoneFlames>(), 120);
|
||||
}
|
||||
|
||||
public override Color? GetAlpha(Color lightColor)
|
||||
{
|
||||
return new Color(250, 50, 50, projectile.alpha);
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.netImportant = true;
|
||||
projectile.friendly = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minionSlots = 0.5f;
|
||||
projectile.minionSlots = 1f;
|
||||
projectile.timeLeft = 18000;
|
||||
projectile.penetrate = -1;
|
||||
projectile.tileCollide = false;
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.netImportant = true;
|
||||
projectile.friendly = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minionSlots = 0.25f;
|
||||
projectile.minionSlots = 0.5f;
|
||||
projectile.timeLeft = 18000;
|
||||
projectile.penetrate = -1;
|
||||
projectile.tileCollide = false;
|
||||
@@ -237,7 +237,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
if (projectile.ai[1] > 0f)
|
||||
{
|
||||
projectile.ai[1] += (float)Main.rand.Next(1, 80);
|
||||
projectile.ai[1] += (float)Main.rand.Next(1, 30);
|
||||
}
|
||||
if (projectile.ai[1] > 90f)
|
||||
{
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.netImportant = true;
|
||||
projectile.friendly = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minionSlots = 0.25f;
|
||||
projectile.minionSlots = 0.5f;
|
||||
projectile.timeLeft = 18000;
|
||||
projectile.penetrate = -1;
|
||||
projectile.tileCollide = false;
|
||||
@@ -292,5 +292,10 @@ namespace CalamityMod.Projectiles.Summon
|
||||
Main.spriteBatch.Draw(texture2D13, projectile.Center - Main.screenPosition + new Vector2(0f, projectile.gfxOffY), new Microsoft.Xna.Framework.Rectangle?(new Rectangle(0, y6, texture2D13.Width, num214)), projectile.GetAlpha(lightColor), projectile.rotation, new Vector2((float)texture2D13.Width / 2f, (float)num214 / 2f), projectile.scale, spriteEffects, 0f);
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
||||
{
|
||||
target.immune[projectile.owner] = 8;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -73,7 +73,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
if (projectile.owner == Main.myPlayer)
|
||||
{
|
||||
NPC potentialTarget = projectile.Center.MinionHoming(600f, player);
|
||||
NPC potentialTarget = projectile.Center.MinionHoming(700f, player);
|
||||
if (potentialTarget != null)
|
||||
{
|
||||
if (projectile.ai[1]++ % 35f == 34f &&
|
||||
|
||||
@@ -120,7 +120,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int num512 = 0; num512 < 200; num512++)
|
||||
for (int num512 = 0; num512 < Main.maxNPCs; num512++)
|
||||
{
|
||||
if (Main.npc[num512].CanBeChasedBy(projectile, false))
|
||||
{
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.netImportant = true;
|
||||
projectile.friendly = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minionSlots = 0.5f;
|
||||
projectile.minionSlots = 1f;
|
||||
projectile.timeLeft = 18000;
|
||||
projectile.penetrate = -1;
|
||||
projectile.tileCollide = false;
|
||||
@@ -207,8 +207,8 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
if (num651 > 2000f)
|
||||
{
|
||||
projectile.position.X = Main.player[projectile.owner].Center.X - (float)(projectile.width / 2);
|
||||
projectile.position.Y = Main.player[projectile.owner].Center.Y - (float)(projectile.height / 2);
|
||||
projectile.position.X = player.Center.X - (float)(projectile.width / 2);
|
||||
projectile.position.Y = player.Center.Y - (float)(projectile.height / 2);
|
||||
projectile.netUpdate = true;
|
||||
}
|
||||
if (num651 > 70f)
|
||||
@@ -229,7 +229,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.ai[1] += (float)Main.rand.Next(1, 3);
|
||||
|
||||
// Reset timer
|
||||
if (projectile.ai[1] > 60f)
|
||||
if (projectile.ai[1] > 70f)
|
||||
{
|
||||
projectile.ai[1] = 0f;
|
||||
projectile.netUpdate = true;
|
||||
@@ -258,7 +258,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
for (int i = 0; i < numProj + 1; i++)
|
||||
{
|
||||
Vector2 perturbedSpeed = value19.RotatedBy(MathHelper.Lerp(-rotation, rotation, i / (numProj - 1)));
|
||||
Projectile.NewProjectile(projectile.Center.X, projectile.Center.Y, perturbedSpeed.X, perturbedSpeed.Y, projectileType, projectile.damage / 2, projectile.knockBack * 0.5f, Main.myPlayer, 0f, 0f);
|
||||
Projectile.NewProjectile(projectile.Center.X, projectile.Center.Y, perturbedSpeed.X, perturbedSpeed.Y, projectileType, projectile.damage / 2, projectile.knockBack * 0.5f, projectile.owner, 0f, 0f);
|
||||
}
|
||||
projectile.netUpdate = true;
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
projectile.netImportant = true;
|
||||
projectile.friendly = true;
|
||||
projectile.ignoreWater = true;
|
||||
projectile.minionSlots = 0.5f;
|
||||
projectile.minionSlots = 1f;
|
||||
projectile.timeLeft = 18000;
|
||||
projectile.penetrate = -1;
|
||||
projectile.tileCollide = false;
|
||||
@@ -283,9 +283,9 @@ namespace CalamityMod.Projectiles.Summon
|
||||
public override void ModifyHitNPC(NPC target, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
|
||||
{
|
||||
if (target.type == NPCID.DukeFishron)
|
||||
damage = (int)((double)damage * 2.0);
|
||||
damage = (int)(damage * 2.0);
|
||||
else if (target.type == NPCID.CultistBoss)
|
||||
damage = (int)((double)damage * 0.6);
|
||||
damage = (int)(damage * 0.75);
|
||||
}
|
||||
|
||||
public override void OnHitNPC(NPC target, int damage, float knockback, bool crit)
|
||||
|
||||
@@ -30,6 +30,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
|
||||
public override void AI()
|
||||
{
|
||||
Player player = Main.player[projectile.owner];
|
||||
projectile.rotation += (Math.Abs(projectile.velocity.X) + Math.Abs(projectile.velocity.Y)) * 0.02f;
|
||||
|
||||
float num472 = projectile.Center.X;
|
||||
@@ -37,12 +38,13 @@ namespace CalamityMod.Projectiles.Summon
|
||||
float num474 = 400f;
|
||||
bool flag17 = false;
|
||||
|
||||
for (int num475 = 0; num475 < 200; num475++)
|
||||
if (player.HasMinionAttackTargetNPC)
|
||||
{
|
||||
if (Main.npc[num475].CanBeChasedBy(projectile, false) || Main.npc[num475].type == NPCID.DukeFishron)
|
||||
NPC npc = Main.npc[player.MinionAttackTargetNPC];
|
||||
if ((npc.CanBeChasedBy(projectile, false) || npc.type == NPCID.DukeFishron) && npc.active)
|
||||
{
|
||||
float num476 = Main.npc[num475].position.X + (float)(Main.npc[num475].width / 2);
|
||||
float num477 = Main.npc[num475].position.Y + (float)(Main.npc[num475].height / 2);
|
||||
float num476 = npc.position.X + (float)(npc.width / 2);
|
||||
float num477 = npc.position.Y + (float)(npc.height / 2);
|
||||
float num478 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num476) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num477);
|
||||
if (num478 < num474)
|
||||
{
|
||||
@@ -53,6 +55,26 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int num475 = 0; num475 < Main.maxNPCs; num475++)
|
||||
{
|
||||
NPC npc = Main.npc[num475];
|
||||
if ((npc.CanBeChasedBy(projectile, false) || npc.type == NPCID.DukeFishron) && npc.active)
|
||||
{
|
||||
float num476 = npc.position.X + (float)(npc.width / 2);
|
||||
float num477 = npc.position.Y + (float)(npc.height / 2);
|
||||
float num478 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num476) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num477);
|
||||
if (num478 < num474)
|
||||
{
|
||||
num474 = num478;
|
||||
num472 = num476;
|
||||
num473 = num477;
|
||||
flag17 = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (flag17)
|
||||
{
|
||||
@@ -77,9 +99,9 @@ namespace CalamityMod.Projectiles.Summon
|
||||
public override void ModifyHitNPC(NPC target, ref int damage, ref float knockback, ref bool crit, ref int hitDirection)
|
||||
{
|
||||
if (target.type == NPCID.DukeFishron)
|
||||
damage = (int)((double)damage * 2.0);
|
||||
damage = (int)(damage * 2.0);
|
||||
else if (target.type == NPCID.CultistBoss)
|
||||
damage = (int)((double)damage * 0.6);
|
||||
damage = (int)(damage * 0.75);
|
||||
}
|
||||
|
||||
public override void Kill(int timeLeft)
|
||||
|
||||
@@ -69,7 +69,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
projectile.position.X = player.Center.X - (float)(projectile.width / 2);
|
||||
projectile.position.Y = player.Center.Y - (float)(projectile.height / 2) + player.gfxOffY - 60f;
|
||||
if (Main.player[projectile.owner].gravDir == -1f)
|
||||
if (player.gravDir == -1f)
|
||||
{
|
||||
projectile.position.Y = projectile.position.Y + 120f;
|
||||
projectile.rotation = 3.14f;
|
||||
@@ -211,13 +211,10 @@ namespace CalamityMod.Projectiles.Summon
|
||||
float scaleFactor5 = (float)Math.Cos((double)(6.28318548f * (projectile.localAI[0] / 60f))) + 3f + 3f;
|
||||
for (float num286 = 0f; num286 < 4f; num286 += 1f)
|
||||
{
|
||||
SpriteBatch arg_F907_0 = Main.spriteBatch;
|
||||
Texture2D arg_F907_1 = texture2D34;
|
||||
Vector2 arg_F8CE_0 = vector59;
|
||||
Vector2 arg_F8BE_0 = Vector2.UnitY;
|
||||
double arg_F8BE_1 = (double)(num286 * 1.57079637f);
|
||||
SpriteBatch spritebatch = Main.spriteBatch;
|
||||
double arg_F8BE_1 = (double)(num286 * MathHelper.PiOver2);
|
||||
Vector2 center = default;
|
||||
arg_F907_0.Draw(arg_F907_1, arg_F8CE_0 + arg_F8BE_0.RotatedBy(arg_F8BE_1, center) * scaleFactor5, new Microsoft.Xna.Framework.Rectangle?(rectangle17), alpha5 * 0.2f, projectile.rotation, origin11, projectile.scale, SpriteEffects.None, 0f);
|
||||
spritebatch.Draw(texture2D34, vector59 + Vector2.UnitY.RotatedBy(arg_F8BE_1, center) * scaleFactor5, new Microsoft.Xna.Framework.Rectangle?(rectangle17), alpha5 * 0.2f, projectile.rotation, origin11, projectile.scale, SpriteEffects.None, 0f);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -52,19 +52,17 @@ namespace CalamityMod.Projectiles.Summon
|
||||
{
|
||||
projectile.frame = 0;
|
||||
}
|
||||
int num3;
|
||||
for (int num369 = 0; num369 < 1; num369 = num3 + 1)
|
||||
for (int num369 = 0; num369 < 1; num369++)
|
||||
{
|
||||
int dustType = 7;
|
||||
float num370 = projectile.velocity.X / 3f * (float)num369;
|
||||
float num371 = projectile.velocity.Y / 3f * (float)num369;
|
||||
int num372 = Dust.NewDust(projectile.position, projectile.width, projectile.height, dustType, 0f, 0f, 0, default, 1f);
|
||||
Main.dust[num372].position.X = projectile.Center.X - num370;
|
||||
Main.dust[num372].position.Y = projectile.Center.Y - num371;
|
||||
Dust dust = Main.dust[num372];
|
||||
dust.position.X = projectile.Center.X - num370;
|
||||
dust.position.Y = projectile.Center.Y - num371;
|
||||
dust.velocity *= 0f;
|
||||
Main.dust[num372].scale = 0.5f;
|
||||
num3 = num369;
|
||||
dust.scale = 0.5f;
|
||||
}
|
||||
projectile.rotation = (float)Math.Atan2((double)projectile.velocity.Y, (double)projectile.velocity.X) - MathHelper.PiOver2;
|
||||
float num373 = projectile.position.X;
|
||||
@@ -83,7 +81,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
float num377 = npc.position.X + (float)(npc.width / 2);
|
||||
float num378 = npc.position.Y + (float)(npc.height / 2);
|
||||
float num379 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num377) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num378);
|
||||
if (num379 < 800f && num379 < num375 && Collision.CanHit(projectile.position, projectile.width, projectile.height, npc.position, npc.width, npc.height))
|
||||
if (num379 < 640f && num379 < num375 && Collision.CanHit(projectile.position, projectile.width, projectile.height, npc.position, npc.width, npc.height))
|
||||
{
|
||||
num375 = num379;
|
||||
num373 = num377;
|
||||
@@ -96,12 +94,13 @@ namespace CalamityMod.Projectiles.Summon
|
||||
{
|
||||
for (int num376 = 0; num376 < Main.maxNPCs; num376++)
|
||||
{
|
||||
if (Main.npc[num376].CanBeChasedBy(projectile, false))
|
||||
NPC npc = Main.npc[num376];
|
||||
if (npc.CanBeChasedBy(projectile, false))
|
||||
{
|
||||
float num377 = Main.npc[num376].position.X + (float)(Main.npc[num376].width / 2);
|
||||
float num378 = Main.npc[num376].position.Y + (float)(Main.npc[num376].height / 2);
|
||||
float num377 = npc.position.X + (float)(npc.width / 2);
|
||||
float num378 = npc.position.Y + (float)(npc.height / 2);
|
||||
float num379 = Math.Abs(projectile.position.X + (float)(projectile.width / 2) - num377) + Math.Abs(projectile.position.Y + (float)(projectile.height / 2) - num378);
|
||||
if (num379 < 800f && num379 < num375 && Collision.CanHit(projectile.position, projectile.width, projectile.height, Main.npc[num376].position, Main.npc[num376].width, Main.npc[num376].height))
|
||||
if (num379 < 640f && num379 < num375 && Collision.CanHit(projectile.position, projectile.width, projectile.height, npc.position, npc.width, npc.height))
|
||||
{
|
||||
num375 = num379;
|
||||
num373 = num377;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Eater of Souls");
|
||||
DisplayName.SetDefault("Baby Eater");
|
||||
Main.projFrames[projectile.type] = 4;
|
||||
ProjectileID.Sets.MinionSacrificable[projectile.type] = true;
|
||||
ProjectileID.Sets.MinionTargettingFeature[projectile.type] = true;
|
||||
@@ -151,7 +151,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
}
|
||||
|
||||
Vector2 vector46 = projectile.position;
|
||||
float num633 = 800f; //50 block detection range
|
||||
float num633 = 640f; //40 block detection range
|
||||
bool targetFound = false;
|
||||
if (player.HasMinionAttackTargetNPC)
|
||||
{
|
||||
@@ -322,20 +322,20 @@ namespace CalamityMod.Projectiles.Summon
|
||||
if (projectile.owner == Main.myPlayer)
|
||||
{
|
||||
if (eaterCooldown > 0)
|
||||
eaterCooldown -= Main.rand.Next(1,4);
|
||||
eaterCooldown -= Main.rand.Next(1,3);
|
||||
|
||||
if (eaterCooldown <= 0)
|
||||
{
|
||||
int projNumber = Main.rand.Next(1,4);
|
||||
int projNumber = Main.rand.Next(1,3);
|
||||
for (int index2 = 0; index2 < projNumber; index2++)
|
||||
{
|
||||
float xVector = (float)Main.rand.Next(-35, 36) * 0.02f;
|
||||
float yVector = (float)Main.rand.Next(-35, 36) * 0.02f;
|
||||
xVector *= 10f;
|
||||
yVector *= 10f;
|
||||
Projectile.NewProjectile(projectile.Center.X, projectile.Center.Y, xVector, yVector, ModContent.ProjectileType<VileFeederProjectile>(), (int)(VileFeeder.BaseDamage * player.MinionDamage() * 1.5f), projectile.knockBack, projectile.owner, 0f, 0f);
|
||||
Projectile.NewProjectile(projectile.Center.X, projectile.Center.Y, xVector, yVector, ModContent.ProjectileType<VileFeederProjectile>(), (int)(VileFeeder.BaseDamage * player.MinionDamage() * 1.25f), projectile.knockBack, projectile.owner, 0f, 0f);
|
||||
}
|
||||
eaterCooldown = 70;
|
||||
eaterCooldown = 80;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@ namespace CalamityMod.Tiles.FurniturePlaguedPlate
|
||||
disableSmartCursor = true;
|
||||
adjTiles = new int[] { TileID.Beds };
|
||||
bed = true;
|
||||
AddToArray(ref TileID.Sets.RoomNeeds.CountsAsChair);
|
||||
}
|
||||
|
||||
public override bool CreateDust(int i, int j, ref int type)
|
||||
|
||||
Reference in new issue
Block a user