things are casting now and sfml is rendering the way I want it to.

The voxel stepping is still all messed up, and it seems that there is
some data corruption on the map that I'll need to dig into
This commit is contained in:
MitchellHansen
2016-07-31 13:52:22 -07:00
parent 1553b5da2c
commit 0b8cd9a194
5 changed files with 54 additions and 17 deletions

View File

@@ -6,6 +6,15 @@ class Map {
public:
Map(sf::Vector3i dim) {
list = new char[dim.x * dim.y * dim.z];
for (int i = 0; i < dim.x * dim.y * dim.x; i++) {
list[i] = 0;
}
for (int x = 0; x < dim.x; x++) {
for (int y = 0; y < dim.y; y++) {
list[x + dim.x * (y + dim.z * 1)] = 1;
}
}
dimensions = dim;
}