Génération de Chunks en multithreads
This commit is contained in:
@@ -13,6 +13,8 @@
|
||||
#include <fstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <future>
|
||||
#include <thread>
|
||||
|
||||
class Chunk;
|
||||
class Player;
|
||||
@@ -44,8 +46,7 @@ private:
|
||||
|
||||
int m_center[2] = { INT16_MAX / 2 - WORLD_SIZE_X / 2, INT16_MAX / 2 - WORLD_SIZE_Y / 2 };
|
||||
|
||||
bool GenerateChunk(int x, int y, Perlin& perlin);
|
||||
void UpdateChunk(int& generates, int& updates, int chx, int chy, Perlin& perlin, BlockInfo* blockinfo[BTYPE_LAST]);
|
||||
void UpdateChunk(int& updates, int chx, int chy, BlockInfo* blockinfo[BTYPE_LAST]);
|
||||
void RenderWorld(int& rendercount, Player& player, Transformation& world, Shader& shader);
|
||||
void UpdateWorld(Player& player, Perlin& perlin, BlockInfo* blockinfo[BTYPE_LAST]);
|
||||
void TransposeWorld(Player& player, Bullet* bullets[MAX_BULLETS]);
|
||||
|
Reference in New Issue
Block a user