edited rendering
This commit is contained in:
@@ -15,14 +15,12 @@ namespace Voxel
|
|||||||
public bool NeedsUpdate = false;
|
public bool NeedsUpdate = false;
|
||||||
public int Length = 0;
|
public int Length = 0;
|
||||||
private List<FaceData> _faces;
|
private List<FaceData> _faces;
|
||||||
public int SSBO;
|
|
||||||
|
|
||||||
public ChunkMesh(int x, int y)
|
public ChunkMesh(int x, int y)
|
||||||
{
|
{
|
||||||
_packedData = new byte[0];
|
_packedData = new byte[0];
|
||||||
X = x;
|
X = x;
|
||||||
Y = y;
|
Y = y;
|
||||||
SSBO = GL.GenBuffer();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetFaces(List<FaceData> faces)
|
public void SetFaces(List<FaceData> faces)
|
||||||
|
|||||||
@@ -15,16 +15,18 @@ internal class Program
|
|||||||
|
|
||||||
window.Player = player;
|
window.Player = player;
|
||||||
|
|
||||||
for (int x = 0; x < 2; x++)
|
for (int x = 0; x < 4; x++)
|
||||||
{
|
{
|
||||||
for (int y = 0; y < 2; y++)
|
for (int y = 0; y < 4; y++)
|
||||||
{
|
{
|
||||||
Chunk chunk = new Chunk(1+ x, 1 +y);
|
Chunk chunk = new Chunk(x, y);
|
||||||
|
|
||||||
world.AddChunk(chunk);
|
world.AddChunk(chunk);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// xmax ymin gör bugg
|
||||||
|
|
||||||
Renderer.SetWorld(world);
|
Renderer.SetWorld(world);
|
||||||
|
|
||||||
window.Run();
|
window.Run();
|
||||||
|
|||||||
Reference in New Issue
Block a user