Revert "Add: Helper methods for obtaining block's X and Z chunk coordinates given block's world coordinates."

This reverts commit 592a98831a0cb1eb98824bf19b3cead11d2d2d0c.
This commit is contained in:
Drew DeVault 2015-05-04 13:17:16 -06:00
parent 70f17b73ae
commit 3e124b2a0f
2 changed files with 2 additions and 12 deletions

View File

@ -184,16 +184,6 @@ namespace TrueCraft.Core
return (int)Math.Floor((double)BlockCoord / Chunk.Depth);
}
public static int BlockToChunkBlockX(int BlockX)
{
return BlockX % Chunk.Width;
}
public static int BlockToChunkBlockZ(int BlockZ)
{
return BlockZ % Chunk.Depth;
}
/// <summary>
/// Returns a value indicating the most extreme value of the
/// provided Vector.

View File

@ -304,9 +304,9 @@ namespace TrueCraft.Core.World
chunk = GetChunk(new Coordinates2D(chunkX, chunkZ));
return new Coordinates3D(
MathHelper.BlockToChunkBlockX(coordinates.X),
(coordinates.X - chunkX * Chunk.Width) % Chunk.Width,
coordinates.Y,
MathHelper.BlockToChunkBlockZ(coordinates.Z));
(coordinates.Z - chunkZ * Chunk.Depth) % Chunk.Depth);
}
public bool IsValidPosition(Coordinates3D position)