]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/common/anim.qh
Remove .move_* fields and MOVETYPE_PUSH logic (doesn't work)
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / anim.qh
1 #ifndef ANIM_H
2 #define ANIM_H
3
4 // begin engine fields
5
6 /** primary framegroup animation (strength = 1 - lerpfrac - lerpfrac3 - lerpfrac4) */
7 .float frame;
8 /** secondary framegroup animation (strength = lerpfrac) */
9 .float frame2;
10 /** tertiary framegroup animation (strength = lerpfrac3) */
11 .float frame3;
12 /** quaternary framegroup animation (strength = lerpfrac4) */
13 .float frame4;
14
15 /** strength of framegroup blend */
16 .float lerpfrac;
17 /** strength of framegroup blend */
18 .float lerpfrac3;
19 /** strength of framegroup blend */
20 .float lerpfrac4;
21
22 /** start time of framegroup animation */
23 .float frame1time;
24 /** start time of framegroup animation */
25 .float frame2time;
26 /** start time of framegroup animation */
27 .float frame3time;
28 /** start time of framegroup animation */
29 .float frame4time;
30
31 // end engine fields
32
33 // player animation state
34
35 .int animstate_startframe;
36 .int animstate_numframes;
37 .float animstate_framerate;
38 .float animstate_starttime;
39 .float animstate_endtime;
40 /** whether to repeat */
41 .bool animstate_looping;
42 /** true for one cycle, then changed to false */
43 .bool animstate_override;
44
45 void anim_set(entity e, vector anim, bool looping, bool override, bool restart);
46 #define setanim(...) anim_set(__VA_ARGS__)
47 void anim_update(entity e);
48 #define updateanim(...) anim_update(__VA_ARGS__)
49
50 #endif