BIG REFACTOR
This commit is contained in:
@@ -56,8 +56,8 @@ GL::VertexArray loadWorldModel(const td::game::World* world) {
|
||||
const td::game::ChunkCoord& coords = chunkInfo.first;
|
||||
td::game::ChunkPtr chunk = chunkInfo.second;
|
||||
|
||||
std::int32_t chunkX = coords.first * td::game::Chunk::ChunkWidth;
|
||||
std::int32_t chunkY = coords.second * td::game::Chunk::ChunkHeight;
|
||||
std::int32_t chunkX = coords.x * td::game::Chunk::ChunkWidth;
|
||||
std::int32_t chunkY = coords.y * td::game::Chunk::ChunkHeight;
|
||||
|
||||
for (int tileY = 0; tileY < td::game::Chunk::ChunkHeight; tileY++) {
|
||||
for (int tileX = 0; tileX < td::game::Chunk::ChunkWidth; tileX++) {
|
||||
@@ -97,8 +97,8 @@ GL::VertexArray loadWorldModel(const td::game::World* world) {
|
||||
|
||||
for (int spawnColor = 0; spawnColor < 2; spawnColor++) {
|
||||
const game::Spawn& spawn = world->getTeam(game::TeamColor(spawnColor)).getSpawn();
|
||||
float fromX = spawn.getTopLeft().getX() , toX = spawn.getBottomRight().getX();
|
||||
float fromY = spawn.getTopLeft().getY() , toY = spawn.getBottomRight().getY();
|
||||
float fromX = spawn.getTopLeft().getX(), toX = spawn.getBottomRight().getX();
|
||||
float fromY = spawn.getTopLeft().getY(), toY = spawn.getBottomRight().getY();
|
||||
|
||||
positions.insert(positions.end(), {
|
||||
fromX, fromY,
|
||||
|
||||
Reference in New Issue
Block a user