0ad/source/graphics/ObjectEntry.h
2005-03-22 17:09:36 +00:00

51 lines
1.1 KiB
C++
Executable File

#ifndef _OBJECTENTRY_H
#define _OBJECTENTRY_H
class CModel;
class CSkeletonAnim;
#include <vector>
#include "CStr.h"
#include "ObjectBase.h"
class CObjectEntry
{
public:
CObjectEntry(int type, CObjectBase* base);
~CObjectEntry();
bool BuildModel();
void ApplyRandomVariant(CObjectBase::variation_key& var);
// base actor. Contains all the things that don't change between
// different variations of the actor.
CObjectBase* m_Base;
CObjectBase::Prop* FindProp(const char* proppointname);
// texture name
CStr m_TextureName;
// model name
CStr m_ModelName;
// list of valid animations for this object
std::vector<CObjectBase::Anim> m_Animations;
CSkeletonAnim* m_IdleAnim;
CSkeletonAnim* m_WalkAnim;
CSkeletonAnim* m_DeathAnim;
CSkeletonAnim* m_MeleeAnim;
CSkeletonAnim* m_RangedAnim;
CSkeletonAnim* m_CorpseAnim;
CSkeletonAnim* GetNamedAnimation( CStr animationName );
// list of props attached to object
std::vector<CObjectBase::Prop> m_Props;
// corresponding model
CModel* m_Model;
// type of object; index into object managers types array
int m_Type;
};
#endif