prime/include/Kyoto/Animation/CPASDatabase.hpp

40 lines
967 B
C++
Raw Normal View History

#ifndef _CPASDATABASE
#define _CPASDATABASE
#include "types.h"
2022-10-06 23:10:07 +00:00
#include "Kyoto/Animation/CPASAnimState.hpp"
2022-10-06 21:07:41 +00:00
#include "rstl/pair.hpp"
#include "rstl/vector.hpp"
2022-10-06 21:07:41 +00:00
class CPASAnimParmData;
class CRandom16;
class CPASDatabase {
2022-10-06 21:07:41 +00:00
public:
2022-10-28 10:49:33 +00:00
bool HasState(int id) const;
2022-10-08 22:03:50 +00:00
const CPASAnimState* GetAnimState(int) const;
2022-10-28 12:33:10 +00:00
rstl::pair< float, int > FindBestAnimation(const CPASAnimParmData& data, int ignoreAnim) const;
rstl::pair< float, int > FindBestAnimation(const CPASAnimParmData&, CRandom16&, int) const;
2022-10-25 15:43:42 +00:00
2022-10-28 12:33:10 +00:00
size_t GetNumAnimStates() const; // { return x0_states.size(); }
2022-10-25 15:43:42 +00:00
const CPASAnimState* GetAnimStateByIndex(int index) const; /* {
if (index >= x0_states.size()) {
return nullptr;
}
return &x0_states[index];
}*/
int GetDefaultState() const { return x10_defaultState; }
2022-10-25 15:43:42 +00:00
private:
rstl::vector< CPASAnimState > x0_states;
int x10_defaultState;
};
CHECK_SIZEOF(CPASDatabase, 0x14)
#endif // _CPASDATABASE