Added day&night cycle. Also fixed world loading
Build / build (push) Has been cancelled

This commit is contained in:
milkwx3
2026-07-07 22:02:10 +03:00
parent 7ab2d5a083
commit 04d1969084
25 changed files with 3018 additions and 888 deletions
+4 -3
View File
@@ -5,7 +5,6 @@
#undef Escape
#endif
#include "glfw_keycodes_to_string.h"
#include "../PerlinNoise.hpp"
#ifdef WIN32
#include "external/fix_win32_compatibility.h"
@@ -99,10 +98,10 @@
#define GAME_VERSION_INT 0
#define DEFAULT_FONT_SIZE 16
#define TPS 30.0
#define TPS 30
#define TPS_DIV 1.0 / TPS
//Rendering
#define RENDER_DISTANCE 5
#define RENDER_DISTANCE 16
#define RENDER_DISTANCE_SQUARED RENDER_DISTANCE*RENDER_DISTANCE
//Game stuff
@@ -115,6 +114,8 @@
#define INVENTORY_HEIGHT 6
#define INVENTORY_SIZE INVENTORY_WIDTH*INVENTORY_HEIGHT
#define WORLD_TIME_SECONDS (24*60)
#define WORLD_TIME_TICKS WORLD_TIME_SECONDS*TPS
enum BlockType {
B_Wood,
B_Stone,