Project

General

Profile

Statistics
| Revision:

root / proj / include / proj_func.h @ 320

History | View | Annotate | Download (1.55 KB)

1
#ifndef PROJ_FUNC_H_INCLUDED
2
#define PROJ_FUNC_H_INCLUDED
3

    
4
#include "ent.h"
5
#include "font.h"
6
#include "proj_structures.h"
7

    
8
#include <stdint.h>
9

    
10
/**
11
 * @brief Cleans up all memory, unsubscribes interrupts.
12
 * @return ERROR_CODE code representing the result of the operation, SUCCESS code is returned if everything is OK
13
 * @see {_ERRORS_H_::errors}
14
 */
15
int cleanup(void);
16

    
17
void update_key_presses(void);
18

    
19
/**
20
 * @brief Updates movement variables.
21
 */
22
void update_movement(map_t *map, gunner_t *p, keys_t *keys, list_t *shooter_list);
23

    
24
void update_mouse(struct packet *p);
25

    
26
keys_t* (get_key_presses)(void);
27

    
28
void (shoot_bullet)(const gunner_t *shooter, list_t *bullet_list, const basic_sprite_t *bsp_bullet);
29

    
30
void (update_game_state)(const map_t *map, list_t *shooter_list, list_t *bullet_list);
31

    
32
void (get_random_spawn)(const map_t *map, gunner_t *p, list_t *l);
33

    
34
void update_scale(void);
35

    
36
int32_t* get_mouse_X(void);
37

    
38
int32_t* get_mouse_Y(void);
39

    
40
void build_host_structure(host_info_t *p, gunner_t *host, gunner_t *remote, list_t *bullet_list);
41

    
42
void build_remote_structure(remote_info_t *p, keys_t *keys, double angle);
43

    
44
/**
45
 * @brief
46
 * @param
47
 * @param
48
 * @param
49
 * @return Angle
50
 */
51
double get_mouse_angle(gunner_t *p);
52

    
53
typedef struct timer {
54
    int time;
55
    text_t *text;
56
} text_timer_t;
57

    
58
text_timer_t* (timer_ctor)(const font_t *fnt);
59

    
60
void (timer_update)(text_timer_t *p);
61

    
62
void (timer_reset)(text_timer_t *p);
63

    
64
void (timer_dtor)(text_timer_t *p);
65

    
66
#endif /* end of include guard: PROJ_FUNC_H_INCLUDED */