WIP: Vibra support
[neverball] / share / solid_all.h
1 #ifndef SOLID_ALL_H
2 #define SOLID_ALL_H
3
4 #include "solid_vary.h"
5
6 void sol_body_p(float p[3], const struct s_vary *, int pi, float t);
7 void sol_body_v(float v[3], const struct s_vary *, int pi, float t, float dt);
8 void sol_body_e(float e[3], const struct s_vary *, const struct v_body *bp,
9                 float dt);
10 void sol_body_w(float w[3], const struct s_vary *, const struct v_body *bp);
11
12 void sol_rotate(float e[3][3], const float w[3], float dt);
13
14 void sol_pendulum(struct v_ball *up,
15                   const float a[3],
16                   const float g[3], float dt);
17
18 void sol_swch_step(struct s_vary *, float dt, int ms);
19 void sol_body_step(struct s_vary *, float dt, int ms);
20 void sol_ball_step(struct s_vary *, float dt);
21
22 enum
23 {
24     JUMP_OUTSIDE = 0,
25     JUMP_TRIGGER,
26     JUMP_INSIDE
27 };
28
29 enum
30 {
31     SWCH_OUTSIDE = 0,
32     SWCH_TRIGGER,
33     SWCH_INSIDE
34 };
35
36 int            sol_item_test(struct s_vary *, float *p, float item_r);
37 struct b_goal *sol_goal_test(struct s_vary *, float *p, int ui);
38 int            sol_jump_test(struct s_vary *, float *p, int ui);
39 int            sol_swch_test(struct s_vary *, int ui);
40
41 #endif