-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbackground.h
More file actions
41 lines (34 loc) · 782 Bytes
/
background.h
File metadata and controls
41 lines (34 loc) · 782 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
#ifndef BACKGROUND_H_
#define BACKGROUND_H_
struct mote_attractor_ {
v2 position;
};
struct mote_ {
i32 width;
u32 color;
v2 center;
v2 velocity;
f32 z;
};
struct floaty_ {
tex2 texture;
rect_i source_rect;
v2 center;
f32 velocity;
f32 z;
};
struct background_ {
array<mote_> motes;
array<floaty_> floaties;
array<mote_attractor_> attractors;
array<tex2> textures;
color_ background_color;
f32 wind_x;
};
void create_background(game_state_* game_state,
background_* background);
void update_background(background_* background,
render_group_* render_group,
camera_ camera,
f32 dt);
#endif /* end of include guard: BACKGROUND_H_ */