-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcuboid.h
More file actions
39 lines (32 loc) · 727 Bytes
/
cuboid.h
File metadata and controls
39 lines (32 loc) · 727 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef CUBOID_H
#define CUBOID_H
#include <stdint.h>
#include <string.h>
#include "block.h"
#include "list.h"
struct level_t;
struct cuboid_t
{
int16_t sx, sy, sz;
int16_t ex, ey, ez;
int16_t cx, cy, cz;
enum blocktype_t old_type;
enum blocktype_t new_type;
struct level_t *level;
unsigned owner;
bool fixed;
bool owner_is_op;
bool undo;
int count;
struct level_t *srclevel;
struct client_t *client;
};
static inline bool cuboid_t_compare(struct cuboid_t *a, struct cuboid_t *b)
{
return memcmp(a, b, sizeof *a) == 0;
}
LIST(cuboid, struct cuboid_t, cuboid_t_compare)
extern struct cuboid_list_t s_cuboids;
void cuboid_remove_for_level(struct level_t *l);
void cuboid_process(void);
#endif /* CUBOID_H */