1 - Blorb.
2 - Changed life fruit upgrade recipes. 3 - DoG phase 2 teleport refactor. 4 - Reduced life fruit spawns pre-mech by 3x.
This commit is contained in:
1 parent
e1695292a0
commit
4dfca3e890
7 files changed
+33
-67
No files matched your search
@@ -7,7 +7,7 @@ namespace CalamityMod.Items.Materials
|
||||
{
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Blood Orb");
|
||||
DisplayName.SetDefault("Blorb");
|
||||
}
|
||||
|
||||
public override void SetDefaults()
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
item.width = 20;
|
||||
item.height = 20;
|
||||
item.useAnimation = 30;
|
||||
item.rare = 5;
|
||||
item.rare = ItemRarityID.LightPurple;
|
||||
item.useTime = 30;
|
||||
item.useStyle = ItemUseStyleID.HoldingUp;
|
||||
item.UseSound = SoundID.Item4;
|
||||
@@ -57,12 +57,12 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.LifeFruit, 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofChaos>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofCinder>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<EssenceofEleum>(), 5);
|
||||
recipe.AddIngredient(ItemID.SoulofNight, 10);
|
||||
recipe.AddIngredient(ItemID.SoulofLight, 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.AddIngredient(ItemID.OrangeBloodroot);
|
||||
recipe.AddIngredient(ModContent.ItemType<BloodOrb>(), 10);
|
||||
recipe.AddIngredient(ItemID.SoulofMight, 5);
|
||||
recipe.AddIngredient(ItemID.SoulofSight, 5);
|
||||
recipe.AddIngredient(ItemID.SoulofFright, 5);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
item.useStyle = ItemUseStyleID.HoldingUp;
|
||||
item.UseSound = SoundID.Item4;
|
||||
item.consumable = true;
|
||||
item.rare = 10;
|
||||
item.rare = ItemRarityID.Red;
|
||||
item.Calamity().customRarity = CalamityRarity.Violet;
|
||||
}
|
||||
|
||||
@@ -59,11 +59,10 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.LifeFruit, 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<Phantoplasm>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<CosmiliteBar>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<DarksunFragment>(), 10);
|
||||
recipe.AddIngredient(ItemID.SkyBlueFlower);
|
||||
recipe.AddIngredient(ItemID.FragmentSolar, 15);
|
||||
recipe.AddIngredient(ModContent.ItemType<NightmareFuel>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<DarksunFragment>(), 10);
|
||||
recipe.AddIngredient(ModContent.ItemType<NightmareFuel>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<EndothermicEnergy>(), 5);
|
||||
recipe.AddTile(ModContent.TileType<DraedonsForge>());
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -21,8 +21,9 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
item.width = 20;
|
||||
item.height = 20;
|
||||
item.useAnimation = 30;
|
||||
item.rare = 10;
|
||||
item.useTime = 30;
|
||||
item.rare = ItemRarityID.Red;
|
||||
item.Calamity().customRarity = CalamityRarity.Turquoise;
|
||||
item.useTime = 30;
|
||||
item.useStyle = ItemUseStyleID.HoldingUp;
|
||||
item.UseSound = SoundID.Item4;
|
||||
item.consumable = true;
|
||||
@@ -57,8 +58,9 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.LifeFruit, 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<UeliaceBar>(), 10);
|
||||
recipe.AddIngredient(ItemID.LunarBar, 10);
|
||||
recipe.AddIngredient(ItemID.BlueBerries);
|
||||
recipe.AddIngredient(ModContent.ItemType<UeliaceBar>(), 10);
|
||||
recipe.AddIngredient(ModContent.ItemType<DivineGeode>(), 10);
|
||||
recipe.AddIngredient(ModContent.ItemType<UnholyEssence>(), 20);
|
||||
recipe.AddTile(TileID.LunarCraftingStation);
|
||||
recipe.SetResult(this);
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
item.width = 20;
|
||||
item.height = 20;
|
||||
item.useAnimation = 30;
|
||||
item.rare = 7;
|
||||
item.rare = ItemRarityID.Yellow;
|
||||
item.useTime = 30;
|
||||
item.useStyle = ItemUseStyleID.HoldingUp;
|
||||
item.UseSound = SoundID.Item4;
|
||||
@@ -58,9 +58,10 @@ namespace CalamityMod.Items.PermanentBoosters
|
||||
{
|
||||
ModRecipe recipe = new ModRecipe(mod);
|
||||
recipe.AddIngredient(ItemID.LifeFruit, 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<AstralJelly>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<LivingShard>(), 10);
|
||||
recipe.AddIngredient(ModContent.ItemType<Stardust>(), 20);
|
||||
recipe.AddIngredient(ItemID.TealMushroom);
|
||||
recipe.AddIngredient(ModContent.ItemType<TrapperBulb>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<BarofLife>(), 5);
|
||||
recipe.AddIngredient(ModContent.ItemType<LivingShard>(), 10);
|
||||
recipe.AddTile(TileID.MythrilAnvil);
|
||||
recipe.SetResult(this);
|
||||
recipe.AddRecipe();
|
||||
|
||||
@@ -871,51 +871,16 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
postTeleportTimer = 255;
|
||||
npc.alpha = postTeleportTimer;
|
||||
|
||||
int playerWidth = player.width / 2;
|
||||
int playerHeight = player.height / 2;
|
||||
Vector2 targetVector = player.Center + Vector2.Normalize(player.velocity) * 320f + new Vector2(Main.rand.Next(-40, 41), Main.rand.Next(-40, 41));
|
||||
|
||||
float playerVelocityX = player.velocity.X;
|
||||
float playerVelocityY = player.velocity.Y;
|
||||
|
||||
int x = (int)player.position.X + playerWidth - 25;
|
||||
int y = (int)player.position.Y + playerHeight - 25;
|
||||
|
||||
float velocityThreshold = 0.05f;
|
||||
int vectorAdjustment = 500;
|
||||
if (playerVelocityX >= velocityThreshold)
|
||||
{
|
||||
x += vectorAdjustment;
|
||||
yAdjustment();
|
||||
}
|
||||
else if (playerVelocityX <= -velocityThreshold)
|
||||
{
|
||||
x -= vectorAdjustment;
|
||||
yAdjustment();
|
||||
}
|
||||
|
||||
void yAdjustment()
|
||||
{
|
||||
if (playerVelocityY >= velocityThreshold)
|
||||
y += vectorAdjustment;
|
||||
else if (playerVelocityY <= -velocityThreshold)
|
||||
y -= vectorAdjustment;
|
||||
}
|
||||
|
||||
int x2 = x + 50;
|
||||
int y2 = y + 50;
|
||||
|
||||
float locationX = Main.rand.Next(x, x2);
|
||||
float locationY = Main.rand.Next(y, y2);
|
||||
Vector2 teleportLocation = new Vector2(locationX, locationY);
|
||||
|
||||
npc.position = teleportLocation;
|
||||
npc.position = targetVector;
|
||||
npc.netUpdate = true;
|
||||
|
||||
for (int i = 0; i < 200; i++)
|
||||
for (int i = 0; i < Main.maxNPCs; i++)
|
||||
{
|
||||
if (Main.npc[i].active && (Main.npc[i].type == ModContent.NPCType<DevourerofGodsBodyS>() || Main.npc[i].type == ModContent.NPCType<DevourerofGodsTailS>()))
|
||||
{
|
||||
Main.npc[i].position = teleportLocation;
|
||||
Main.npc[i].position = targetVector;
|
||||
if (Main.npc[i].type == ModContent.NPCType<DevourerofGodsTailS>())
|
||||
{
|
||||
((DevourerofGodsTailS)Main.npc[i].modNPC).setInvulTime(720);
|
||||
@@ -924,8 +889,7 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 npcCenter = new Vector2(npc.position.X + (npc.width / 2), npc.position.Y + (npc.height / 2));
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Item, "Sounds/Item/LargeMechGaussRifle"), (int)npcCenter.X, (int)npcCenter.Y);
|
||||
Main.PlaySound(mod.GetLegacySoundSlot(SoundType.Item, "Sounds/Item/LargeMechGaussRifle"), (int)npc.Center.X, (int)npc.Center.Y);
|
||||
|
||||
int dustAmt = 50;
|
||||
int random = 5;
|
||||
@@ -935,8 +899,8 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
random += j * 2;
|
||||
int dustAmtSpawned = 0;
|
||||
int scale = random * 13;
|
||||
float dustPositionX = npcCenter.X - (scale / 2);
|
||||
float dustPositionY = npcCenter.Y - (scale / 2);
|
||||
float dustPositionX = npc.Center.X - (scale / 2);
|
||||
float dustPositionY = npc.Center.Y - (scale / 2);
|
||||
while (dustAmtSpawned < dustAmt)
|
||||
{
|
||||
float dustVelocityX = Main.rand.Next(-random, random);
|
||||
@@ -948,8 +912,8 @@ namespace CalamityMod.NPCs.DevourerofGods
|
||||
dustVelocityY *= dustVelocity;
|
||||
int dust = Dust.NewDust(new Vector2(dustPositionX, dustPositionY), scale, scale, 173, 0f, 0f, 100, default, 5f);
|
||||
Main.dust[dust].noGravity = true;
|
||||
Main.dust[dust].position.X = teleportLocation.X;
|
||||
Main.dust[dust].position.Y = teleportLocation.Y;
|
||||
Main.dust[dust].position.X = targetVector.X;
|
||||
Main.dust[dust].position.Y = targetVector.Y;
|
||||
Main.dust[dust].position.X += Main.rand.Next(-10, 11);
|
||||
Main.dust[dust].position.Y += Main.rand.Next(-10, 11);
|
||||
Main.dust[dust].velocity.X = dustVelocityX;
|
||||
|
||||
@@ -1124,7 +1124,7 @@ namespace CalamityMod.World
|
||||
}
|
||||
|
||||
// Life Fruit pre-mech
|
||||
int random = Main.expertMode ? 30 : 40;
|
||||
int random = Main.expertMode ? 90 : 120;
|
||||
if (WorldGen.genRand.Next(random) == 0)
|
||||
{
|
||||
if (Main.hardMode && !NPC.downedMechBossAny)
|
||||
|
||||
Reference in new issue
Block a user