summaryrefslogtreecommitdiffstats
path: root/src/RendererSectionData.hpp
diff options
context:
space:
mode:
authorLaG1924 <12997935+LaG1924@users.noreply.github.com>2018-08-05 19:17:24 +0200
committerLaG1924 <12997935+LaG1924@users.noreply.github.com>2018-08-05 19:17:24 +0200
commitea12fb0d8ce8a351f4dc559d2357191849be874b (patch)
tree756a814bfbd3016585526a10faf85faa783cff67 /src/RendererSectionData.hpp
parentChange OpenGL context profile to core (diff)
downloadAltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar.gz
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar.bz2
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar.lz
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar.xz
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.tar.zst
AltCraft-ea12fb0d8ce8a351f4dc559d2357191849be874b.zip
Diffstat (limited to 'src/RendererSectionData.hpp')
-rw-r--r--src/RendererSectionData.hpp18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/RendererSectionData.hpp b/src/RendererSectionData.hpp
index a60f671..1250d39 100644
--- a/src/RendererSectionData.hpp
+++ b/src/RendererSectionData.hpp
@@ -9,6 +9,20 @@
class World;
+enum BlockDirection {
+ down, //Y-
+ up, //Y+
+ north, //Z-
+ south, //Z+
+ west, //X-
+ east, //X+
+ none,
+};
+
+struct BlockLightness {
+ unsigned char face[BlockDirection::none] = { 0,0,0,0,0,0 };
+};
+
struct SectionsData {
Section section;
Section west;
@@ -18,9 +32,9 @@ struct SectionsData {
Section north;
Section south;
- unsigned char GetLight(const Vector &pos) const;
+ BlockLightness GetLight(const Vector &pos) const;
- unsigned char GetSkyLight(const Vector &pos) const;
+ BlockLightness GetSkyLight(const Vector &pos) const;
};
struct RendererSectionData {