astral to other conversion now uses a method
This commit is contained in:
1 parent
c6b2179232
commit
1f76789e5b
2 files changed
+12
-10
No files matched your search
@@ -127,16 +127,7 @@ namespace CalamityMod.NPCs.TownNPCs
|
||||
type = ConvertType.Crimson;
|
||||
break;
|
||||
}
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
for (int j = 0; j < 3; j++)
|
||||
{
|
||||
AstralBiome.ConvertFromAstral(x + i, y + j, type);
|
||||
AstralBiome.ConvertFromAstral(x - i, y - j, type);
|
||||
AstralBiome.ConvertFromAstral(x + i, y - j, type);
|
||||
AstralBiome.ConvertFromAstral(x - i, y + j, type);
|
||||
}
|
||||
}
|
||||
AstralBiome.ConvertFromAstral(x - 2, x + 2, y - 2, y + 2, type);
|
||||
WorldGen.Convert(x, y, conversionType, 2);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -892,6 +892,17 @@ namespace CalamityMod.World
|
||||
}
|
||||
}
|
||||
|
||||
public static void ConvertFromAstral(int startX, int endX, int startY, int endY, ConvertType convert)
|
||||
{
|
||||
for (int x = startX; x <= endX; x++)
|
||||
{
|
||||
for (int y = startY; y <= endY; y++)
|
||||
{
|
||||
ConvertFromAstral(x, y, convert);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void ConvertFromAstral(int x, int y, ConvertType convert, bool tileframe = true)
|
||||
{
|
||||
Tile tile = Main.tile[x, y];
|
||||
|
||||
Reference in new issue
Block a user