| 1 | /* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */ |
|---|---|
| 2 | /* If you are missing that file, acquire a complete release at teeworlds.com. */ |
| 3 | #ifndef GAME_CLIENT_ANIMSTATE_H |
| 4 | #define GAME_CLIENT_ANIMSTATE_H |
| 5 | |
| 6 | #include <generated/data_types.h> |
| 7 | |
| 8 | class CAnimState |
| 9 | { |
| 10 | CAnimKeyframe m_Body; |
| 11 | CAnimKeyframe m_BackFoot; |
| 12 | CAnimKeyframe m_FrontFoot; |
| 13 | CAnimKeyframe m_Attach; |
| 14 | |
| 15 | void AnimAdd(CAnimState *pState, const CAnimState *pAdded, float Amount); |
| 16 | |
| 17 | public: |
| 18 | const CAnimKeyframe *GetBody() const { return &m_Body; } |
| 19 | const CAnimKeyframe *GetBackFoot() const { return &m_BackFoot; } |
| 20 | const CAnimKeyframe *GetFrontFoot() const { return &m_FrontFoot; } |
| 21 | const CAnimKeyframe *GetAttach() const { return &m_Attach; } |
| 22 | void Set(CAnimation *pAnim, float Time); |
| 23 | void Add(CAnimation *pAnim, float Time, float Amount); |
| 24 | |
| 25 | const static CAnimState *GetIdle(); |
| 26 | }; |
| 27 | |
| 28 | #endif |
| 29 |