blob: 87c33fa20159637a87e48b98c5c2f245ccb6824a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#pragma once
#include "block.h"
#include "world.h"
#include "junk/vector.h"
#include <stdint.h>
enum biome {
JUNK_BIOME_PLAINS,
};
#define CHUNK_WIDTH 16
#define CHUNK_LENGTH 16
#define CHUNK_HEIGHT 128
struct chunk {
struct block* blocks[CHUNK_WIDTH][CHUNK_LENGTH][CHUNK_HEIGHT];
enum biome biome;
vec2 coord;
};
int chunk_gen(struct world* world, struct chunk* chunk);
int chunk_gen_structures(void* neighbor_data, struct chunk* chunk);
int chunk_gen_terrain(void* neighbor_data, struct chunk* chunk);
|