Sunken Sea Gen optimization, wall water colors

Plus other stuff
This commit is contained in:
Heart-Plus-Up committed 2025-02-22 22:35:30 -07:00
1 parent 18debcec81
commit 6811bf53c4
22 files changed
+323 -240

No files matched your search

+5 -5
View File
@@ -173,14 +173,14 @@ namespace CalamityMod.Systems
};
// place each piece of the sunken sea based on the above positons
SunkenSea.PlaceRadiantReefs(sunkenSeaX - 100, sunkenSeaY + 75, true);
SunkenSea.PlaceRadiantReefs(sunkenSeaX + 100, sunkenSeaY + 75, false);
SunkenSea.PlacePolypForest(sunkenSeaX, sunkenSeaY + 500);
SunkenSea.PlaceBasaltGully(sunkenSeaX, sunkenSeaY + (Main.maxTilesY / 4));
SunkenSea.PlaceRadiantReefs(sunkenSeaX, sunkenSeaY + 110);
SunkenSea.PlacePolypForest(sunkenSeaX, sunkenSeaY + 500);
SunkenSea.PlaceGleamingBurrows(sunkenSeaX, sunkenSeaY + (Main.maxTilesY / 4) - 50);
SunkenSea.PlaceSunkenSeaAmbience();
SunkenSea.BasaltGullyLavaCleanup(sunkenSeaX, sunkenSeaY + (Main.maxTilesY / 4));
SunkenSea.PlaceClamDen(sunkenSeaX, sunkenSeaY + 615);
SunkenSea.PlaceTimelessShores(sunkenSeaX, sunkenSeaY);
SunkenSea.BasaltGullyLavaCleanup(sunkenSeaX, sunkenSeaY + (Main.maxTilesY / 4));
SunkenSea.PlaceSunkenSeaAmbience();
}));
}
+1 -1
View File
@@ -24,7 +24,7 @@ namespace CalamityMod.Tiles.Abyss
CalamityUtils.MergeWithGeneral(Type);
CalamityUtils.MergeWithAbyss(Type);
AddMapEntry(new Color(25, 28, 54));
AddMapEntry(new Color(30, 37, 56));
MineResist = 5f;
MinPick = 65;
HitSound = MineSound;
+1 -1
View File
@@ -28,7 +28,7 @@ namespace CalamityMod.Tiles.Abyss
HitSound = MineSound;
MineResist = 10f;
MinPick = 180;
AddMapEntry(new Color(43, 40, 40));
AddMapEntry(new Color(31, 31, 37));
this.RegisterUniversalMerge(TileID.Dirt, "CalamityMod/Tiles/Merges/DirtMerge");
this.RegisterUniversalMerge(TileID.Stone, "CalamityMod/Tiles/Merges/StoneMerge");
+3 -3
View File
@@ -17,11 +17,11 @@ namespace CalamityMod.Tiles.Abyss
{
Main.tileLighted[Type] = true;
Main.tileCut[Type] = true;
Main.tileBlockLight[Type] = true;
Main.tileBlockLight[Type] = false;
Main.tileLavaDeath[Type] = true;
Main.tileNoFail[Type] = true;
Main.tileNoSunLight[Type] = false;
AddMapEntry(new Color(0, 50, 0));
AddMapEntry(new Color(54, 99, 100));
HitSound = SoundID.Grass;
DustType = 2;
TileID.Sets.IsVine[Type] = true;
@@ -88,7 +88,7 @@ namespace CalamityMod.Tiles.Abyss
}
// Ozzatron 01JUL2022: heavily refactored this code to not suck. also, sulphurous vines won't grow in honey anymore.
private const int MaxVineHeight = 10;
private const int MaxVineHeight = 15;
public override void RandomUpdate(int i, int j)
{
+11 -8
View File
@@ -17,6 +17,10 @@ namespace CalamityMod.Tiles.Abyss
Main.tileBlockLight[Type] = true;
Main.tileLavaDeath[Type] = true;
Main.tileNoFail[Type] = true;
TileID.Sets.IsVine[Type] = true;
TileID.Sets.ReplaceTileBreakDown[Type] = true;
TileID.Sets.VineThreads[Type] = true;
TileID.Sets.DrawFlipMode[Type] = 1;
TileMaterials.SetForTileId(Type, TileMaterials._materialsByName["Plant"]);
AddMapEntry(new Color(0, 50, 0));
HitSound = SoundID.Grass;
@@ -36,15 +40,14 @@ namespace CalamityMod.Tiles.Abyss
public override bool TileFrame(int i, int j, ref bool resetFrame, ref bool noBreak)
{
if (WorldGen.loadSuccess)
Tile tileAbove = Framing.GetTileSafely(i, j - 1);
if (!tileAbove.HasTile)
{
Tile tileAbove = Framing.GetTileSafely(i, j - 1);
if (!tileAbove.HasTile)
{
WorldGen.KillTile(i, j);
return true;
}
WorldGen.KillTile(i, j);
return true;
}
return true;
}
@@ -67,7 +70,7 @@ namespace CalamityMod.Tiles.Abyss
}
}
}
private const int MaxVineHeight = 20;
public override void RandomUpdate(int i, int j)
{
Tile tileBelow = Framing.GetTileSafely(i, j + 1);
+2
View File
@@ -26,6 +26,8 @@ namespace CalamityMod.Tiles
public static List<int> GrowthTiles = new List<int>()
{
ModContent.TileType<SeaPrism>(),
ModContent.TileType<AbyssGravel>(),
ModContent.TileType<PyreMantle>(),
ModContent.TileType<Navystone>(),
ModContent.TileType<Shellstone>(),
ModContent.TileType<Limestone>(),
+1 -1
View File
@@ -30,7 +30,7 @@ namespace CalamityMod.Tiles.Ores
TileID.Sets.Ore[Type] = true;
DustType = 105;
AddMapEntry(new Color(210, 101, 28), CreateMapEntryName());
AddMapEntry(new Color(167, 80, 22), CreateMapEntryName());
MineResist = 3f;
MinPick = 210;
HitSound = SoundID.Tink;
@@ -3,6 +3,7 @@ using Terraria.ID;
using Terraria.ModLoader;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using System;
namespace CalamityMod.Tiles.SunkenSea.Ambient
@@ -15,7 +16,8 @@ namespace CalamityMod.Tiles.SunkenSea.Ambient
Main.tileSolid[Type] = false;
Main.tileNoFail[Type] = true;
Main.tileNoAttach[Type] = true;
TileID.Sets.IsVine[Type] = true;
Main.tileNoSunLight[Type] = false;
TileID.Sets.IsVine[Type] = true;
TileID.Sets.VineThreads[Type] = true;
AddMapEntry(new Color(48, 98, 192));
DustType = DustID.Grass;
@@ -50,17 +52,8 @@ namespace CalamityMod.Tiles.SunkenSea.Ambient
}
public override void NearbyEffects(int i, int j, bool closer)
{
// Baby blue
if (closer && Main.rand.NextBool(1200))
{
Dust dust;
dust = Main.dust[Dust.NewDust(new Vector2(i * 16f, j * 16f), 274, 279, DustID.Firefly, 0.23255825f, 10f, 0, new Color(106, 154, 238), 1.5f)];
dust.noGravity = true;
dust.noLight = true;
dust.fadeIn = 2.5813954f;
}
// Light Cyan
if (closer && Main.rand.NextBool(1200))
if (closer && Main.rand.NextBool(600))
{
Dust dust;
dust = Main.dust[Dust.NewDust(new Vector2(i * 16f, j * 16f), 274, 279, DustID.Firefly, 0.23255825f, 10f, 0, new Color(136, 206, 215), 1.7f)];
@@ -68,17 +61,8 @@ namespace CalamityMod.Tiles.SunkenSea.Ambient
dust.noLight = true;
dust.fadeIn = 2.5813954f;
}
//Mint Green
if (closer && Main.rand.NextBool(1200))
{
Dust dust;
dust = Main.dust[Dust.NewDust(new Vector2(i * 16f, j * 16f), 274, 279, DustID.Firefly, 0.23255825f, 10f, 0, new Color(163, 252, 195), 1.4f)];
dust.noGravity = true;
dust.noLight = true;
dust.fadeIn = 2.5813954f;
}
//Lilac
if (closer && Main.rand.NextBool(1200))
if (closer && Main.rand.NextBool(600))
{
Dust dust;
dust = Main.dust[Dust.NewDust(new Vector2(i * 16f, j * 16f), 274, 279, DustID.Firefly, 0.23255825f, 10f, 0, new Color(236, 194, 252), 1.6f)];
@@ -86,15 +70,23 @@ namespace CalamityMod.Tiles.SunkenSea.Ambient
dust.noLight = true;
dust.fadeIn = 2.5813954f;
}
//Dim Lilac
if (closer && Main.rand.NextBool(1200))
{
Dust dust;
dust = Main.dust[Dust.NewDust(new Vector2(i * 16f, j * 16f), 274, 279, DustID.Firefly, 0.23255825f, 10f, 0, new Color(192, 170, 233), 1.3f)];
dust.noGravity = true;
dust.noLight = true;
dust.fadeIn = 2.5813954f;
}
}
public override void ModifyLight(int i, int j, ref float r, ref float g, ref float b)
{
float brightness = 0.9f;
brightness += 0.6f;
brightness = MathHelper.Clamp(brightness, 0.5f, 0.9f);
brightness *= (float)MathF.Sin(-j / 40f + Main.GameUpdateCount * 0.01f + i);
Color lilac = new Color(236, 194, 252);
Color mint = new Color(163, 252, 195);
Color value = Color.Lerp(lilac, mint, (MathF.Sin(j / 30f + Main.GameUpdateCount * 0.017f + -i / 40f) + 1f) / 2f);
Color value1 = Color.Lerp(lilac, mint, (MathF.Sin((-j - 100) / 40f + Main.GameUpdateCount * 0.014f + i / 20f) + 1f) / 2f);
r = (value.R + value1.R) / 300f;
g = (value.G + value1.G) / 300f;
b = (value.B + value1.B) / 300f;
r *= brightness;
g *= brightness;
b *= brightness;
}
public override void RandomUpdate(int i, int j)
+3 -1
View File
@@ -5,12 +5,14 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class AbyssGravelWall : ModWall
public class AbyssGravelWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
DustType = 33;
AddMapEntry(new Color(6, 10, 54));
this.AddMapEntryWithWaterVisibility(new Color(21, 47, 111));
}
public override void RandomUpdate(int i, int j)
+3 -1
View File
@@ -4,13 +4,15 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class AbyssGravelWallSafe : ModWall
public class AbyssGravelWallSafe : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override string Texture => "CalamityMod/Walls/AbyssGravelWall";
public override void SetStaticDefaults()
{
Main.wallHouse[Type] = true;
AddMapEntry(new Color(6, 10, 54));
this.AddMapEntryWithWaterVisibility(new Color(21, 47, 111));
DustType = 33;
}
+3 -1
View File
@@ -4,13 +4,15 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class HardenedSulphurousSandstoneWall : ModWall
public class HardenedSulphurousSandstoneWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
Main.wallHouse[Type] = true;
DustType = 32;
AddMapEntry(new Color(62, 50, 39));
this.AddMapEntryWithWaterVisibility(new Color(49, 66, 133));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -8,8 +8,9 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class PlantyMushWall : ModWall
public class PlantyMushWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public static Asset<Texture2D> leafTexture = null;
public static Vector2 TileAdj => (Lighting.Mode == Terraria.Graphics.Light.LightMode.Retro || Lighting.Mode == Terraria.Graphics.Light.LightMode.Trippy) ? Vector2.Zero : Vector2.One * 12;
@@ -22,6 +23,7 @@ namespace CalamityMod.Walls
{
DustType = DustID.Grass;
AddMapEntry(new Color(54, 72, 9));
this.AddMapEntryWithWaterVisibility(new Color(37, 59, 69));
if (!Main.dedServ)
{
leafTexture = ModContent.Request<Texture2D>("CalamityMod/Walls/PlantyMushWallLeaves");
+3 -1
View File
@@ -5,12 +5,14 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class PyreMantleWall : ModWall
public class PyreMantleWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
DustType = 33;
AddMapEntry(new Color(33, 30, 30));
this.AddMapEntryWithWaterVisibility(new Color(16, 35, 82));
}
public override void RandomUpdate(int i, int j)
+3 -1
View File
@@ -4,8 +4,9 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class PyreMantleWallSafe : ModWall
public class PyreMantleWallSafe : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override string Texture => "CalamityMod/Walls/PyreMantleWall";
public override void SetStaticDefaults()
@@ -13,6 +14,7 @@ namespace CalamityMod.Walls
DustType = 33;
Main.wallHouse[Type] = true;
AddMapEntry(new Color(33, 30, 30));
this.AddMapEntryWithWaterVisibility(new Color(16, 35, 82));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -5,12 +5,14 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class SulphurousSandWall : ModWall
public class SulphurousSandWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
DustType = 32;
AddMapEntry(new Color(84, 71, 46));
this.AddMapEntryWithWaterVisibility(new Color(59, 69, 121));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -4,14 +4,16 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class SulphurousSandWallSafe : ModWall
public class SulphurousSandWallSafe : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override string Texture => "CalamityMod/Walls/SulphurousSandWall";
public override void SetStaticDefaults()
{
Main.wallHouse[Type] = true;
DustType = 32;
AddMapEntry(new Color(84, 71, 46));
this.AddMapEntryWithWaterVisibility(new Color(59, 69, 121));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -5,12 +5,14 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class SulphurousSandstoneWall : ModWall
public class SulphurousSandstoneWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
DustType = 32;
AddMapEntry(new Color(57, 45, 38));
this.AddMapEntryWithWaterVisibility(new Color(45, 60, 120));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -5,12 +5,14 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class SulphurousShaleWall : ModWall
public class SulphurousShaleWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override void SetStaticDefaults()
{
DustType = 32;
AddMapEntry(new Color(59, 40, 63));
this.AddMapEntryWithWaterVisibility(new (44, 62, 125));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -4,14 +4,16 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class SulphurousShaleWallSafe : ModWall
public class SulphurousShaleWallSafe : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
public override string Texture => "CalamityMod/Walls/SulphurousShaleWall";
public override void SetStaticDefaults()
{
Main.wallHouse[Type] = true;
DustType = 32;
AddMapEntry(new Color(59, 40, 63));
this.AddMapEntryWithWaterVisibility(new Color(44, 62, 125));
}
public override void NumDust(int i, int j, bool fail, ref int num) => num = fail ? 1 : 3;
+3 -1
View File
@@ -9,8 +9,9 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class VoidstoneWall : ModWall
public class VoidstoneWall : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
internal static FramedMaskTexture GlowMask;
public override void SetStaticDefaults()
@@ -19,6 +20,7 @@ namespace CalamityMod.Walls
Main.wallHouse[Type] = true;
AddMapEntry(new Color(0, 0, 0));
this.AddMapEntryWithWaterVisibility(new Color(11, 28, 67));
}
public override void Unload()
+3 -1
View File
@@ -9,8 +9,9 @@ using Terraria.ModLoader;
namespace CalamityMod.Walls
{
public class VoidstoneWallUnsafe : ModWall
public class VoidstoneWallUnsafe : ModWall, IVisibleThroughWater
{
int IVisibleThroughWater.WaterMapEntry { get; set; }
internal static FramedMaskTexture GlowMask;
public override string Texture => "CalamityMod/Walls/VoidstoneWall";
@@ -22,6 +23,7 @@ namespace CalamityMod.Walls
DustType = 187;
AddMapEntry(new Color(0, 0, 0));
this.AddMapEntryWithWaterVisibility(new Color(11, 28, 67));
}
public override void Unload()
+238 -178
View File
@@ -267,48 +267,6 @@ namespace CalamityMod.World
});
//Makes a hole into the actual Sunken Sea at the bottom - left and bottom-right of the middle platform of the Timeless Shores.
ForLoop.Invoke(startPosX - furthestDistanceFromCenter, startPosX - shortestDistanceFromCenter, 1, (holeX) =>
{
for (int holeY = startPosY + holeStart; holeY <= startPosY + holeDepth; holeY += 1)
{
ShapeData circle = new ShapeData();
GenAction blotchFilter = new Modifiers.Blotches(6, 1.9);
//WorldUtils.Gen(new Point(holeX, holeY), new Shapes.Circle(2, 3), Actions.Chain(new GenAction[]
//{
// blotchFilter.Output(circle), // Applies a blotch filter to the rectangle.
//}));
WorldUtils.Gen(new Point(holeX / 2, holeY / 2), new Shapes.Circle(2, 3), Actions.Chain(new GenAction[]
{
new Actions.ClearTile(), // The shape removes tiles.
new Actions.SetLiquid() // The shape adds liquid (Default to max water).
}));
}
});
ForLoop.Invoke(startPosX - furthestDistanceFromCenter, startPosX + furthestDistanceFromCenter, 1, (holeX) =>
{
for (int holeY = startPosY + holeStart; holeY <= startPosY + holeDepth; holeY += 1)
{
ShapeData circle = new ShapeData();
GenAction blotchFilter = new Modifiers.Blotches(6, 1.9);
//WorldUtils.Gen(new Point(holeX, holeY), new Shapes.Circle(2, 3), Actions.Chain(new GenAction[]
//{
// blotchFilter.Output(circle), // Applies a blotch filter to the rectangle.
//}));
WorldUtils.Gen(new Point(holeX / 2, holeY / 2), new Shapes.Circle(2, 3), Actions.Chain(new GenAction[]
{
new Actions.ClearTile(), // The shape removes tiles.
new Actions.SetLiquid() // The shape adds liquid (Default to max water).
}));
}
});
//place water below the clear barrier for the islands so that theres water inbetween them
ForLoop.Invoke(startPosX - biomeSize + 35, startPosX + biomeSize - 35, 1, (WaterX) =>
{
@@ -353,16 +311,16 @@ namespace CalamityMod.World
// Makes the transition area to the Timeless Shores.
// Replaces tiles, walls, and places some water spots.
//
ForLoop.Invoke(startPosX - biomeSize - 25, startPosX + biomeSize + 25, 20, (x) =>
ForLoop.Invoke(startPosX - biomeSize - 30, startPosX + biomeSize + 30, 20, (x) =>
{
int curveDepth = (int)MathHelper.Lerp(
totalCuveDepth,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 20, startPosX + biomeSize - 200, x, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 25, startPosX + biomeSize - 200, x, true)));
int curveDepth2 = (int)MathHelper.Lerp(
totalCuveDepth,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 17, startPosX - biomeSize + 200, x, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 25, startPosX - biomeSize + 200, x, true)));
for (int y = startPosY - 5; y >= startPosY - 149; y -= 15)
{
float interpolator = Utils.GetLerpValue(startPosY - 90, startPosY - 150, y, true);
@@ -454,26 +412,26 @@ namespace CalamityMod.World
WorldGen.KillTile(X, Y);
}
//Timeless Shores ambiant tiles
if (Main.tile[X, Y].TileType == ModContent.TileType<Dunesand>())
{
//Driftwood Ambiance
if (WorldGen.genRand.NextBool(150))
{
ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
//if (Main.tile[X, Y].TileType == ModContent.TileType<Dunesand>())
//{
// //Driftwood Ambiance
// if (WorldGen.genRand.NextBool(150))
// {
// ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
WorldGen.PlaceObject(X, Y - 1, WorldGen.genRand.Next(DriftwoodPiles));
}
}
if (Main.tile[X, Y].TileType == ModContent.TileType<Runestone>())
{
//Driftwood Ambiance
if (WorldGen.genRand.NextBool(150))
{
ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
// WorldGen.PlaceObject(X, Y - 1, WorldGen.genRand.Next(DriftwoodPiles));
// }
//}
//if (Main.tile[X, Y].TileType == ModContent.TileType<Runestone>())
//{
// //Driftwood Ambiance
// if (WorldGen.genRand.NextBool(150))
// {
// ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
WorldGen.PlaceObject(X, Y - 1, WorldGen.genRand.Next(DriftwoodPiles));
}
}
// WorldGen.PlaceObject(X, Y - 1, WorldGen.genRand.Next(DriftwoodPiles));
// }
//}
}
});
@@ -492,7 +450,7 @@ namespace CalamityMod.World
//sides of the sunken sea (radiant reefs)
//LeftSideBarrier is used to make the barrier of basalt either on the left or right, since the sunken sea is meant to have barriers on both sides and the reefs is generated twice
public static void PlaceRadiantReefs(int startPosX, int startPosY, bool LeftSideBarrier)
public static void PlaceRadiantReefs(int startPosX, int startPosY)
{
int cavePerlinSeed = WorldGen.genRand.Next();
int cavePerlinSeedWalls = WorldGen.genRand.Next();
@@ -500,78 +458,23 @@ namespace CalamityMod.World
Point origin = new Point(startPosX, startPosY);
Vector2 center = origin.ToVector2() * 16f + new Vector2(8f);
float angle = MathHelper.Pi * 0.15f;
float angle = MathHelper.Pi * 0.20f;
float otherAngle = MathHelper.PiOver2 - angle;
int biomeSize = 180 + (Main.maxTilesX / 180);
int biomeSize = 280 + (Main.maxTilesX / 180);
float actualSize = biomeSize * 16f;
float constant = actualSize * 2f / (float)Math.Sin(angle);
float fociSpacing = actualSize * (float)Math.Sin(otherAngle) / (float)Math.Sin(angle);
int verticalRadius = (int)(constant / 16f);
int verticalRadius = (int)(constant / 20f);
Vector2 fociOffset = Vector2.UnitY * fociSpacing;
Vector2 topFoci = center - fociOffset;
Vector2 bottomFoci = center + fociOffset;
//first, place a basalt barrier on the left and right of the biome
ForLoop.Invoke(origin.X - biomeSize - 3, origin.X + biomeSize + 3, 1, (X) =>
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
if (CheckInBiomeArea(new Point(X, Y), topFoci, bottomFoci, constant, center, out float dist, Y < origin.Y))
{
float percent = dist / constant;
float blurPercent = 0.99f;
if (percent > blurPercent)
{
if (Y > origin.Y - 60)
{
if (LeftSideBarrier)
{
if (X <= origin.X && Main.tile[X - 40, Y - 25].TileType != ModContent.TileType<Basalt>())
{
ShapeData circle = new ShapeData();
GenAction blotchMod = new Modifiers.Blotches(2, 0.4);
WorldUtils.Gen(new Point(X - 15, Y - 20), new Shapes.Tail(50, new Vector2D(0,-50)), Actions.Chain(new GenAction[]
{
blotchMod.Output(circle)
}));
WorldUtils.Gen(new Point(X - 15, Y - 20), new ModShapes.All(circle), Actions.Chain(new GenAction[]
{
new Actions.Clear(),
new Actions.PlaceTile((ushort)ModContent.TileType<Basalt>())
}));
}
}
else
{
if (X >= origin.X && Main.tile[X + 40, Y - 25].TileType != ModContent.TileType<Basalt>())
{
ShapeData circle = new ShapeData();
GenAction blotchMod = new Modifiers.Blotches(2, 0.4);
WorldUtils.Gen(new Point(X + 10, Y - 5), new Shapes.Tail(50, new Vector2D(37, -20)), Actions.Chain(new GenAction[]
{
blotchMod.Output(circle)
}));
WorldUtils.Gen(new Point(X + 10, Y - 5), new ModShapes.All(circle), Actions.Chain(new GenAction[]
{
new Actions.Clear(),
new Actions.PlaceTile((ushort)ModContent.TileType<Basalt>())
}));
}
}
}
}
}
}
});
bool runonce = false; // this is used to make the wall on the left side go boom on the second run
//generate the actual caverns
for (int X = origin.X - biomeSize - 3; X <= origin.X + biomeSize + 3; X++)
for (int X = origin.X - biomeSize - 170; X <= origin.X + biomeSize + 170; X++)
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
@@ -791,8 +694,8 @@ namespace CalamityMod.World
//generate perlin noise caves
float horizontalOffsetNoise = CalamityUtils.PerlinNoise2D(X / 80f, Y / 80f, 5, unchecked(cavePerlinSeed + 1)) * 0.01f;
float cavePerlinValue = CalamityUtils.PerlinNoise2D(X / 600f, Y / 550f, 5, cavePerlinSeed) + 0.5f + horizontalOffsetNoise;
float cavePerlinValue2 = CalamityUtils.PerlinNoise2D(X / 600f, Y / 550f, 5, unchecked(cavePerlinSeed - 1)) + 0.5f;
float cavePerlinValue = CalamityUtils.PerlinNoise2D(X / 800f, Y / 450f, 5, cavePerlinSeed) + 0.5f + horizontalOffsetNoise;
float cavePerlinValue2 = CalamityUtils.PerlinNoise2D(X / 800f, Y / 450f, 5, unchecked(cavePerlinSeed - 1)) + 0.5f;
float caveNoiseMap = (cavePerlinValue + cavePerlinValue2) * 0.5f;
float caveCreationThreshold = horizontalOffsetNoise * 3.5f + 0.235f;
@@ -820,7 +723,7 @@ namespace CalamityMod.World
WorldGen.PlaceWall(X, Y, ModContent.WallType<LimestoneWall>());
}
if ((caveNoiseMapWalls + 0.065f) * (caveNoiseMapWalls + 0.065f) > caveCreationThresholdWalls)
if ((caveNoiseMapWalls + 0.085f) * (caveNoiseMapWalls + 0.085f) > caveCreationThresholdWalls)
{
WorldGen.PlaceWall(X, Y, ModContent.WallType<ScarletSeaGrassWall>());
}
@@ -942,7 +845,6 @@ namespace CalamityMod.World
}
});
}
//bottom of the biome (gleaming burrows)
public static void PlaceGleamingBurrows(int startPosX, int startPosY)
{
@@ -998,6 +900,8 @@ namespace CalamityMod.World
}
});
//place the gleaming burrows caverns
for (int X = origin.X - biomeSize - 3; X <= origin.X + biomeSize + 3; X++)
{
@@ -1074,6 +978,7 @@ namespace CalamityMod.World
}
}
//cleanup the perlin caves
ForLoop.Invoke(origin.X - biomeSize - 3, origin.X + biomeSize + 3, 1, (X) =>
{
@@ -1101,6 +1006,7 @@ namespace CalamityMod.World
}
});
//place extra tiles
ForLoop.Invoke(origin.X - biomeSize - 3, origin.X + biomeSize + 3, 1, (X) =>
{
@@ -1167,6 +1073,193 @@ namespace CalamityMod.World
}
}
//Very bottom of the biome (Clam Den)
public static void PlaceClamDen(int startPosX, int startPosY)
{
int cavePerlinSeed = WorldGen.genRand.Next();
int cavePerlinSeedWalls = WorldGen.genRand.Next();
Point origin = new Point(startPosX, startPosY);
Vector2 center = origin.ToVector2() * 16f + new Vector2(8f);
float angle = MathHelper.Pi * 0.15f;
float otherAngle = MathHelper.PiOver2 - angle;
int biomeSize = 60 + (Main.maxTilesX / 180);
float actualSize = biomeSize * 16f;
float constant = actualSize * 2f / (float)Math.Sin(angle);
float fociSpacing = actualSize * (float)Math.Sin(otherAngle) / (float)Math.Sin(angle);
int verticalRadius = (int)(constant / 16f);
Vector2 fociOffset = Vector2.UnitY * fociSpacing;
Vector2 topFoci = center - fociOffset;
Vector2 bottomFoci = center + fociOffset;
//place the Clam Den caverns
for (int X = origin.X - biomeSize - 3; X <= origin.X + biomeSize + 3; X++)
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
if (CheckInBiomeArea(new Point(X, Y), topFoci, bottomFoci, constant, center, out float dist, true))
{
float percent = dist / constant;
float blurPercent = 0.99f;
if (percent > blurPercent)
{
if (Y > origin.Y - 50)
{
//place smaller navystone clumps infront of the basalt so the basalt isnt actually inside of the biome itself
WorldGen.TileRunner(X, Y, WorldGen.genRand.Next(8, 12), WorldGen.genRand.Next(8, 12), ModContent.TileType<WhitePearlPile>(), true, 0f, 0f, true, true);
}
//place clean transition between the burrows and the other biomes
if (Y < origin.Y && Main.tile[X, Y].HasTile && Main.tile[X, Y].TileType != ModContent.TileType<Navystone>())
{
ShapeData circle = new ShapeData();
GenAction blotchMod = new Modifiers.Blotches(2, 0.4);
WorldUtils.Gen(new Point(X, Y), new Shapes.Slime(WorldGen.genRand.Next(1, 3)), Actions.Chain(new GenAction[]
{
blotchMod.Output(circle)
}));
WorldUtils.Gen(new Point(X, Y), new ModShapes.All(circle), Actions.Chain(new GenAction[]
{
new Actions.ClearTile(), new Actions.PlaceTile((ushort)ModContent.TileType<Navystone>())
}));
}
}
else
{
//clear absolutely everything before generating the caverns
Main.tile[X, Y].ClearEverything();
////generate perlin noise caves
//float horizontalOffsetNoise = CalamityUtils.PerlinNoise2D(X / 80, Y / 80, 5, unchecked(cavePerlinSeed + 1)) * 0.01f;
//float cavePerlinValue = CalamityUtils.PerlinNoise2D(X / 1075f, Y / 1075f, 5, cavePerlinSeed) + 0.5f + horizontalOffsetNoise;
//float cavePerlinValue2 = CalamityUtils.PerlinNoise2D(X / 1075f, Y / 1075f, 5, unchecked(cavePerlinSeed - 1)) + 0.5f;
//float caveNoiseMap = (cavePerlinValue + cavePerlinValue2) * 0.5f;
//float caveCreationThreshold = horizontalOffsetNoise * 3.5f + 0.235f;
////kill or place tiles depending on the noise map
//if (caveNoiseMap * caveNoiseMap > caveCreationThreshold)
//{
// WorldGen.KillTile(X, Y);
//}
//else
//{
// WorldGen.PlaceTile(X, Y, (ushort)ModContent.TileType<Navystone>());
//}
//place walls in the biome using a different "seed" so it differs from the cave generation
//this creates a neat effect where walls worm their way through the caverns while leaving openings for the background to show through
float horizontalOffsetNoiseWalls = CalamityUtils.PerlinNoise2D(X / 80, Y / 80, 5, unchecked(cavePerlinSeedWalls + 1)) * 0.01f;
float cavePerlinValueWalls = CalamityUtils.PerlinNoise2D(X / 375f, Y / 375f, 5, cavePerlinSeedWalls) + 0.5f + horizontalOffsetNoiseWalls;
float cavePerlinValue2Walls = CalamityUtils.PerlinNoise2D(X / 375f, Y / 375f, 5, unchecked(cavePerlinSeedWalls - 1)) + 0.5f;
float caveNoiseMapWalls = (cavePerlinValueWalls + cavePerlinValue2Walls) * 0.5f;
float caveCreationThresholdWalls = horizontalOffsetNoiseWalls * 5.5f + 0.235f;
if (caveNoiseMapWalls * caveNoiseMapWalls > caveCreationThresholdWalls)
{
WorldGen.PlaceWall(X, Y, ModContent.WallType<NavystoneWall>());
}
Main.tile[X, Y].Get<LiquidData>().LiquidType = LiquidID.Water;
Main.tile[X, Y].LiquidAmount = byte.MaxValue;
}
}
}
}
//cleanup the perlin caves
ForLoop.Invoke(origin.X - biomeSize - 3, origin.X + biomeSize + 3, 1, (X) =>
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
if (CheckInBiomeArea(new Point(X, Y), topFoci, bottomFoci, constant, center, out float dist, true))
{
//clean tiles that are sticking out (aka tiles only attached to one tile on one side)
bool OnlyRight = !Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile;
bool OnlyLeft = !Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X + 1, Y].HasTile;
bool OnlyDown = !Main.tile[X, Y - 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile;
bool OnlyUp = !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile;
if (OnlyRight || OnlyLeft || OnlyDown || OnlyUp)
{
WorldGen.KillTile(X, Y);
}
//kill random single floating tiles
if (!Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile)
{
WorldGen.KillTile(X, Y);
}
}
}
});
//place extra tiles
ForLoop.Invoke(origin.X - biomeSize - 3, origin.X + biomeSize + 3, 1, (X) =>
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
if (CheckInBiomeArea(new Point(X, Y), topFoci, bottomFoci, constant, center, out float dist, true))
{
bool canPlaceSand = false;
//place sand clumps on top of exposed navystone
if (Main.tile[X, Y].TileType == ModContent.TileType<Navystone>() && !Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y - 2].HasTile && !Main.tile[X, Y - 3].HasTile)
{
canPlaceSand = true;
}
if (canPlaceSand)
{
PlaceSand(X, Y, 4, ModContent.TileType<WhitePearlPile>());
}
}
}
});
//cleanup again
for (int X = origin.X - biomeSize - 3; X <= origin.X + biomeSize + 3; X++)
{
for (int Y = (int)(origin.Y - verticalRadius * 0.4f) - 3; Y <= origin.Y + verticalRadius + 3; Y++)
{
if (CheckInBiomeArea(new Point(X, Y), topFoci, bottomFoci, constant, center, out float dist, true))
{
//clean tiles that are sticking out (aka tiles only attached to one tile on one side)
bool OnlyRight = !Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile;
bool OnlyLeft = !Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X + 1, Y].HasTile;
bool OnlyDown = !Main.tile[X, Y - 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile;
bool OnlyUp = !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile;
if (OnlyRight || OnlyLeft || OnlyDown || OnlyUp)
{
WorldGen.KillTile(X, Y);
}
//kill random single floating tiles
if (!Main.tile[X, Y - 1].HasTile && !Main.tile[X, Y + 1].HasTile && !Main.tile[X - 1, Y].HasTile && !Main.tile[X + 1, Y].HasTile)
{
WorldGen.KillTile(X, Y);
}
//if any sand is floating, put tiles below it
if (Main.tile[X, Y].TileType == ModContent.TileType<WhitePearlPile>() && !Main.tile[X, Y + 1].HasTile)
{
WorldGen.PlaceTile(X, Y + 1, (ushort)ModContent.TileType<Navystone>());
Main.tile[X, Y].TileType = (ushort)ModContent.TileType<Navystone>();
}
Tile.SmoothSlope(X, Y);
}
}
}
}
//basalt biome underneath the sunken sea
public static void PlaceBasaltGully(int startPosX, int startPosY)
{
@@ -1174,67 +1267,31 @@ namespace CalamityMod.World
int XLeft = GenVars.UndergroundDesertLocation.Left + 40;
int XRight = GenVars.UndergroundDesertLocation.Right - 70;
//place circles of basalt along the 2 edges of the area
//for (int Y = startPosY - 50; Y <= Main.maxTilesY - 200; Y += 20)
//{
// ShapeData circle = new ShapeData();
// GenAction blotchMod = new Modifiers.Blotches(2, 0.4);
// int radius = WorldGen.genRand.Next(30, 45);
// int RandomX = Main.rand.Next(-25, 25);
// WorldUtils.Gen(new Point(XLeft, Y), new Shapes.Rectangle(radius, (radius)), Actions.Chain(new GenAction[]
// {
// blotchMod.Output(circle)
// }));
// WorldUtils.Gen(new Point(XLeft, Y), new ModShapes.All(circle), Actions.Chain(new GenAction[]
// {
// new Actions.Clear(),
// new Actions.PlaceTile((ushort)ModContent.TileType<Basalt>()),
// new Actions.PlaceWall(WallID.LavaUnsafe1)
// }));
// WorldUtils.Gen(new Point(XRight, Y), new Shapes.Rectangle(radius, (radius)), Actions.Chain(new GenAction[]
// {
// blotchMod.Output(circle)
// }));
// WorldUtils.Gen(new Point(XRight, Y), new ModShapes.All(circle), Actions.Chain(new GenAction[]
// {
// new Actions.Clear(),
// new Actions.PlaceTile((ushort)ModContent.TileType<Basalt>()),
// new Actions.PlaceWall(WallID.LavaUnsafe1)
// }));
//}
//place blocks of basalt all the way down to hell, here it just places one block and wall so it doesnt hurt preformance
ForLoop.Invoke(startPosX - biomeSize - 25, startPosX + biomeSize + 25, 1, (X) =>
ForLoop.Invoke(startPosX - biomeSize - 60, startPosX + biomeSize + 60, 1, (X) =>
{
//const int totalCuveDepth = -120;
//const int totalCuveDepth2 = 120;
int basaltbordernoise = Main.rand.Next(180, 185);
int basaltbordernoisetop = Main.rand.Next(145, 150);
int basaltbordernoisetop = Main.rand.Next(645, 650);
const int totalCuveDepth = -220;
const int totalCuveDepth2 = 80;
const int totalCuveDepth2 = 90;
int curveDepth = (int)MathHelper.Lerp(
totalCuveDepth,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 20, startPosX + biomeSize - 200, X, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 60, startPosX + biomeSize - 200, X, true)));
int curveDepth2 = (int)MathHelper.Lerp(
totalCuveDepth,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 20, startPosX - biomeSize + 200, X, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 60, startPosX - biomeSize + 200, X, true)));
int curveDepthtop = (int)MathHelper.Lerp(
totalCuveDepth2,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 20, startPosX + biomeSize - 200, X, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX + biomeSize + 60, startPosX + biomeSize - 200, X, true)));
int curveDepth2top = (int)MathHelper.Lerp(
totalCuveDepth2,
0f,
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 20, startPosX - biomeSize + 200, X, true)));
MathF.Sqrt(Utils.GetLerpValue(startPosX - biomeSize - 60, startPosX - biomeSize + 200, X, true)));
for (int Y = startPosY - basaltbordernoisetop + curveDepthtop + curveDepth2top; Y <= Main.maxTilesY - basaltbordernoise + curveDepth + curveDepth2; Y++)
{
@@ -1347,6 +1404,7 @@ namespace CalamityMod.World
}
}
//place all the ambient tiles in the sunken sea
public static void PlaceSunkenSeaAmbience()
{
@@ -1381,7 +1439,7 @@ namespace CalamityMod.World
if (Main.tile[X, Y].TileType == ModContent.TileType<Dunesand>())
{
//Driftwood Ambiance
if (WorldGen.genRand.NextBool(5))
if (WorldGen.genRand.NextBool(100))
{
ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
@@ -1391,7 +1449,7 @@ namespace CalamityMod.World
if (Main.tile[X, Y].TileType == ModContent.TileType<Runestone>())
{
//Driftwood Ambiance
if (WorldGen.genRand.NextBool(5))
if (WorldGen.genRand.NextBool(100))
{
ushort[] DriftwoodPiles = new ushort[] { (ushort)ModContent.TileType<DriftwoodAmbient1>(), (ushort)ModContent.TileType<DriftwoodAmbient2>(), (ushort)ModContent.TileType<DriftwoodAmbient3>(), (ushort)ModContent.TileType<DriftwoodAmbient4>(), (ushort)ModContent.TileType<DriftwoodAmbient5>(), (ushort)ModContent.TileType<DriftwoodAmbient6>() };
@@ -1567,8 +1625,8 @@ namespace CalamityMod.World
}
if (Main.tile[X, Y].TileType == ModContent.TileType<ScarletSeaGrassTile>())
{
if (WorldGen.genRand.NextBool(100) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(7), Actions.Chain(new GenAction[]
if (WorldGen.genRand.NextBool(50) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(3), Actions.Chain(new GenAction[]
{
new Modifiers.OnlyTiles((ushort)ModContent.TileType<ScarletSeaGrassTile>(),(ushort)ModContent.TileType<PolypSand>()),
new Actions.ClearTile(),
@@ -1765,10 +1823,11 @@ namespace CalamityMod.World
WorldGen.PlaceTile(X - 2, Y, WorldGen.genRand.Next(WallCorals), true, false, -1, 0);
}
}
// Pearl Autism
if (Main.tile[X, Y].TileType == ModContent.TileType<VolcanicSand>())
{
if (WorldGen.genRand.NextBool(100) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(7), Actions.Chain(new GenAction[]
if (WorldGen.genRand.NextBool(50) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(3), Actions.Chain(new GenAction[]
{
new Modifiers.OnlyTiles((ushort)ModContent.TileType<VolcanicSand>()),
new Actions.ClearTile(),
@@ -1777,8 +1836,8 @@ namespace CalamityMod.World
}
if (Main.tile[X, Y].TileType == ModContent.TileType<HardenedEutrophicSand>())
{
if (WorldGen.genRand.NextBool(60) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(7), Actions.Chain(new GenAction[]
if (WorldGen.genRand.NextBool(30) && !Main.tile[X - 1, Y].HasTile)
WorldUtils.Gen(new Point(X, Y), new Shapes.Circle(3), Actions.Chain(new GenAction[]
{
new Modifiers.OnlyTiles((ushort)ModContent.TileType<HardenedEutrophicSand>()),
new Actions.ClearTile(),
@@ -1937,6 +1996,7 @@ namespace CalamityMod.World
});
}
//method to make sure things only generate in each biome circle
public static bool CheckInBiomeArea(Point tile, Vector2 focus1, Vector2 focus2, float distanceConstant, Vector2 center, out float distance, bool collapse = false, bool collapseBottom = false)
{