Pyrogenesis
trunk
|
#include <ObjectEntry.h>
Public Member Functions | |
CObjectEntry (const std::shared_ptr< CObjectBase > &base, CSimulation2 &simulation) | |
~CObjectEntry () | |
bool | BuildVariation (const std::vector< const std::set< CStr > *> &completeSelections, const std::vector< u8 > &variationKey, CObjectManager &objectManager) |
CSkeletonAnim * | GetRandomAnimation (const CStr &animationName, const CStr &ID="") const |
Returns a randomly-chosen animation matching the given ID, or animationName if ID is empty. More... | |
std::vector< CSkeletonAnim * > | GetAnimations (const CStr &animationName, const CStr &ID="") const |
Returns all the animations matching the given ID or animationName if ID is empty. More... | |
Public Attributes | |
std::shared_ptr< CObjectBase > | m_Base |
std::vector< CObjectBase::Samp > | m_Samplers |
VfsPath | m_ModelName |
CColor | m_Color |
std::wstring | m_ProjectileModelName |
CModelAbstract * | m_Model |
Private Types | |
using | SkeletonAnimMap = std::multimap< CStr, std::unique_ptr< CSkeletonAnim > > |
Private Member Functions | |
NONCOPYABLE (CObjectEntry) | |
Private Attributes | |
CSimulation2 & | m_Simulation |
SkeletonAnimMap | m_Animations |
|
private |
CObjectEntry::CObjectEntry | ( | const std::shared_ptr< CObjectBase > & | base, |
CSimulation2 & | simulation | ||
) |
CObjectEntry::~CObjectEntry | ( | ) |
bool CObjectEntry::BuildVariation | ( | const std::vector< const std::set< CStr > *> & | completeSelections, |
const std::vector< u8 > & | variationKey, | ||
CObjectManager & | objectManager | ||
) |
std::vector< CSkeletonAnim * > CObjectEntry::GetAnimations | ( | const CStr & | animationName, |
const CStr & | ID = "" |
||
) | const |
Returns all the animations matching the given ID or animationName if ID is empty.
If none found returns Idle animations (which are always added)
CSkeletonAnim * CObjectEntry::GetRandomAnimation | ( | const CStr & | animationName, |
const CStr & | ID = "" |
||
) | const |
Returns a randomly-chosen animation matching the given ID, or animationName if ID is empty.
The chosen animation is picked randomly from the GetAnimations list with the frequencies as weights (if there are any defined). This method should always return an animation
|
private |
|
private |
std::shared_ptr<CObjectBase> CObjectEntry::m_Base |
CColor CObjectEntry::m_Color |
CModelAbstract* CObjectEntry::m_Model |
VfsPath CObjectEntry::m_ModelName |
std::wstring CObjectEntry::m_ProjectileModelName |
std::vector<CObjectBase::Samp> CObjectEntry::m_Samplers |
|
private |