summaryrefslogtreecommitdiff
path: root/include/worldgen.h
blob: 5e3601e918c32cf9ab48627b32be8410a6cf2fc9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef STATES_WORLDGEN_H
#define STATES_WORLDGEN_H
#ifdef __cplusplus
extern "C" {
#endif

#include <engine/core/types.h>

// first 4 bits for material type
#define BLOCK_none    0
#define BLOCK_grass   1
#define BLOCK_rock    2

// next 4 bits for shape type
#define SHAPE_filled (1 << 4)
#define SHAPE_slope  (2 << 4)

void gen_terrain(u8 *world, usize height, usize length, usize width);


#ifdef __cplusplus
}
#endif
#endif