-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathspace.h
More file actions
51 lines (43 loc) · 976 Bytes
/
space.h
File metadata and controls
51 lines (43 loc) · 976 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
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef _SPACE_H_
#define _SPACE_H_
#include <vector>
#include <list>
#include <map>
#include "body.h"
#include "loot.h"
#include "duder.h"
#include "geom.h"
#include "asteroid.h"
#include "cuzer.h"
using namespace std;
enum class ColorTheme {
NORMAL,
WARM,
COOL,
NEON,
MONO
};
struct SpaceTraits {
int numBodies;
int numFuel;
int numBoost;
int numMushroom;
int numDuders;
int numAsteroids;
int numCuzers;
int numGravityWells;
float asteroidSpeed;
float cuzerSpeed;
ColorTheme theme;
};
// Generate traits for a chunk at (cx, cy) with given difficulty
SpaceTraits generateTraitsForChunk(int cx, int cy, int difficulty);
// A loaded chunk of the world
struct Chunk {
int cx, cy;
SpaceTraits traits;
// Entity tracking for cleanup — stores pointers into global lists
vector<Body*> bodies;
// We track iterators would be fragile, so we tag entities with chunk coords instead
};
#endif