Optimization interne de chunk!
This commit is contained in:
		| @@ -3,6 +3,7 @@ | ||||
| #include "define.h" | ||||
| #include "array3d.h" | ||||
| #include "vertexbuffer.h" | ||||
| #include "blockinfo.h" | ||||
|  | ||||
| class Chunk { | ||||
|     private: | ||||
| @@ -10,7 +11,7 @@ class Chunk { | ||||
|         VertexBuffer m_vertexBuffer; | ||||
|         bool m_isDirty = true; | ||||
|  | ||||
|         void AddBlockToMesh(VertexBuffer::VertexData* vd, int& count, BlockType bt, int x, int y, int z); | ||||
|         void AddBlockToMesh(VertexBuffer::VertexData* vd, int& count, BlockType bt, int x, int y, int z, float u, float v, float s); | ||||
|  | ||||
|     public: | ||||
|         Chunk(); | ||||
| @@ -20,7 +21,7 @@ class Chunk { | ||||
|         void SetBlock(int x, int y, int z, BlockType type); | ||||
|         BlockType GetBlock(int x, int y, int z); | ||||
|  | ||||
|         void Update(); | ||||
|         void Update(BlockInfo* blockinfo[BTYPE_LAST]); | ||||
|          | ||||
|         void Render() const; | ||||
|         bool IsDirty() const; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user