2021-09-24 10:15:43 -04:00
|
|
|
#ifndef DEFINE_H__
|
|
|
|
#define DEFINE_H__
|
|
|
|
|
|
|
|
#include <SFML/Window.hpp>
|
|
|
|
#include <SFML/Graphics.hpp>
|
2021-10-11 11:37:58 -04:00
|
|
|
#include <iostream>
|
2021-09-24 10:15:43 -04:00
|
|
|
|
|
|
|
#ifdef _WIN32
|
|
|
|
#include <windows.h>
|
2021-10-11 11:37:58 -04:00
|
|
|
#include <GL/glew.h>
|
2021-09-24 10:15:43 -04:00
|
|
|
#include <gl/GL.h>
|
|
|
|
#include <gl/GLU.h>
|
|
|
|
#endif
|
|
|
|
|
2021-10-31 00:31:08 -04:00
|
|
|
#define CHUNK_SIZE_X 16
|
|
|
|
#define CHUNK_SIZE_Y 128
|
|
|
|
#define CHUNK_SIZE_Z 16
|
2021-12-06 09:45:51 -05:00
|
|
|
#define MAX_SELECTION_DISTANCE 5
|
2021-12-12 23:31:38 -05:00
|
|
|
#define PERLIN_SEED 12345
|
2021-12-06 09:45:51 -05:00
|
|
|
|
|
|
|
#ifdef _DEBUG
|
2021-12-10 07:16:43 -05:00
|
|
|
#define WORLD_SIZE_X 64
|
|
|
|
#define WORLD_SIZE_Y 64
|
2021-12-06 09:45:51 -05:00
|
|
|
|
|
|
|
#define FRAMES_RENDER_CHUNKS 4
|
|
|
|
#define FRAMES_UPDATE_CHUNKS 4
|
|
|
|
#define FRAMES_DELETE_CHUNKS 4
|
2021-11-26 11:59:02 -05:00
|
|
|
|
2021-12-12 23:31:38 -05:00
|
|
|
#define THREADS_GENERATE_CHUNKS 1
|
|
|
|
#define THREADS_UPDATE_CHUNKS 1
|
2021-12-15 21:00:06 -05:00
|
|
|
#define THREADS_DELETE_CHUNKS 1
|
2021-12-12 23:31:38 -05:00
|
|
|
|
2021-12-10 07:16:43 -05:00
|
|
|
#define VIEW_DISTANCE 256
|
|
|
|
#define TEXTURE_SIZE 128
|
2021-12-07 18:59:50 -05:00
|
|
|
#define MAX_BULLETS 64
|
2021-12-06 10:49:55 -05:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef NDEBUG
|
2021-11-27 14:14:05 -05:00
|
|
|
#define WORLD_SIZE_X 128
|
|
|
|
#define WORLD_SIZE_Y 128
|
2021-11-26 11:59:02 -05:00
|
|
|
|
2021-12-06 11:53:18 -05:00
|
|
|
#define FRAMES_RENDER_CHUNKS 1
|
|
|
|
#define FRAMES_UPDATE_CHUNKS 1
|
|
|
|
#define FRAMES_DELETE_CHUNKS 1
|
2021-11-27 14:14:05 -05:00
|
|
|
|
2021-12-13 23:24:12 -05:00
|
|
|
#define THREADS_GENERATE_CHUNKS 12
|
|
|
|
#define THREADS_UPDATE_CHUNKS 8
|
2021-12-15 21:00:06 -05:00
|
|
|
#define THREADS_DELETE_CHUNKS 10
|
2021-12-12 23:31:38 -05:00
|
|
|
|
2021-12-06 11:53:18 -05:00
|
|
|
#define VIEW_DISTANCE 1024
|
2021-12-06 10:58:40 -05:00
|
|
|
#define TEXTURE_SIZE 512
|
2021-12-07 18:59:50 -05:00
|
|
|
#define MAX_BULLETS 512
|
2021-12-06 09:45:51 -05:00
|
|
|
#endif
|
|
|
|
|
2021-09-24 10:15:43 -04:00
|
|
|
|
2021-10-11 11:37:58 -04:00
|
|
|
typedef uint8_t BlockType;
|
2021-10-31 00:31:08 -04:00
|
|
|
enum BLOCK_TYPE { BTYPE_AIR, BTYPE_DIRT, BTYPE_GRASS, BTYPE_METAL, BTYPE_ICE, BTYPE_LAST };
|
2021-09-24 10:15:43 -04:00
|
|
|
|
2021-09-27 11:32:10 -04:00
|
|
|
#define TEXTURE_PATH "../SQCSim2021/media/textures/"
|
2021-10-11 11:37:58 -04:00
|
|
|
#define SHADER_PATH "../SQCSim2021/media/shaders/"
|
2021-10-19 10:27:59 -04:00
|
|
|
#define AUDIO_PATH "../SQCSim2021/media/audio/"
|
2021-11-30 19:55:11 -05:00
|
|
|
#define CHUNK_PATH "../SQCSim2021/media/chunks/"
|
2021-09-24 10:15:43 -04:00
|
|
|
|
|
|
|
#endif // DEFINE_H__
|