dtAnim::AnimationComponent Class Reference

#include <animationcomponent.h>

Inheritance diagram for dtAnim::AnimationComponent:

dtGame::GMComponent dtCore::Base

List of all members.

Public Types

typedef dtGame::GMComponent BaseClass
typedef std::map
< dtCore::UniqueId,
dtCore::RefPtr
< dtAnim::AnimationHelper > > 
AnimCompMap
typedef
AnimCompMap::allocator_type::value_type 
AnimCompMapping
typedef AnimCompMap::iterator AnimCompIter

Public Member Functions

 AnimationComponent (const std::string &name=DEFAULT_NAME)
void ProcessMessage (const dtGame::Message &message)
 handles a processed a message
const dtAnim::AnimationHelperGetHelperForProxy (dtGame::GameActorProxy &proxy) const
 Gets the helper registered for an actor.
void RegisterActor (dtGame::GameActorProxy &toRegister, dtAnim::AnimationHelper &helper)
 Registers an actor with this component.
void UnregisterActor (dtGame::GameActorProxy &toRegister)
 Registers an actor with this component.
bool IsRegisteredActor (dtGame::GameActorProxy &gameActorProxy)
 
Returns:
true if the given actor is registered with this component.

dtCore::TransformableGetTerrainActor ()
 
Returns:
the terrain actor using the given name. If it has not yet been queried, the query will run when this is called.

const dtCore::TransformableGetTerrainActor () const
 
Returns:
the terrain actor using the given name. If it has not yet been queried, the query will run when this is called.

void SetTerrainActor (dtCore::Transformable *newTerrain)
 changes the actor to use for the terrain.
dtCore::TransformableGetEyePointActor ()
 
Returns:
the actor to use as an eye point for ground clamping. This determines which LOD to clamp to.

const dtCore::TransformableGetEyePointActor () const
 
Returns:
the actor to use as an eye point for ground clamping. This determines which LOD to clamp to.

void SetEyePointActor (dtCore::Transformable *newEyePointActor)
 changes the actor to use for the terrain.

Static Public Attributes

static const std::string DEFAULT_NAME
 The default component name, used when looking it up on the GM.

Protected Member Functions

virtual ~AnimationComponent ()
virtual void TickLocal (float dt)
void GroundClamp ()


Member Typedef Documentation

typedef dtGame::GMComponent dtAnim::AnimationComponent::BaseClass

typedef std::map<dtCore::UniqueId, dtCore::RefPtr<dtAnim::AnimationHelper> > dtAnim::AnimationComponent::AnimCompMap

typedef AnimCompMap::allocator_type::value_type dtAnim::AnimationComponent::AnimCompMapping

typedef AnimCompMap::iterator dtAnim::AnimationComponent::AnimCompIter


Constructor & Destructor Documentation

dtAnim::AnimationComponent::AnimationComponent ( const std::string &  name = DEFAULT_NAME  ) 

dtAnim::AnimationComponent::~AnimationComponent (  )  [protected, virtual]


Member Function Documentation

void dtAnim::AnimationComponent::ProcessMessage ( const dtGame::Message message  )  [virtual]

handles a processed a message

See also:
dtGame::GMComponent::ProcessMessage
Parameters:
The message

Reimplemented from dtGame::GMComponent.

const dtAnim::AnimationHelper * dtAnim::AnimationComponent::GetHelperForProxy ( dtGame::GameActorProxy proxy  )  const

Gets the helper registered for an actor.

Parameters:
proxy The proxy to get the helper for
Returns:
A pointer to the helper, or NULL if the proxy is not registered

void dtAnim::AnimationComponent::RegisterActor ( dtGame::GameActorProxy toRegister,
dtAnim::AnimationHelper helper 
)

Registers an actor with this component.

To simplify coding in the actor, specifically when it comes to setting properties on the helper, the actor should create it's own helper and pass it in when registering.

Parameters:
toRegister the actor to register.
helper the preconfigured helper object to use.
Exceptions:
dtUtil::Exception if this actor is already registered with the component.

void dtAnim::AnimationComponent::UnregisterActor ( dtGame::GameActorProxy toRegister  ) 

Registers an actor with this component.

To simplify coding in the actor, specifically when it comes to setting properties on the helper, the actor should create it's own helper and pass it in when registering.

Parameters:
toRegister the actor to register.
helper the preconfigured helper object to use.

bool dtAnim::AnimationComponent::IsRegisteredActor ( dtGame::GameActorProxy gameActorProxy  ) 

Returns:
true if the given actor is registered with this component.

dtCore::Transformable * dtAnim::AnimationComponent::GetTerrainActor (  ) 

Returns:
the terrain actor using the given name. If it has not yet been queried, the query will run when this is called.

const dtCore::Transformable * dtAnim::AnimationComponent::GetTerrainActor (  )  const

Returns:
the terrain actor using the given name. If it has not yet been queried, the query will run when this is called.

void dtAnim::AnimationComponent::SetTerrainActor ( dtCore::Transformable newTerrain  ) 

changes the actor to use for the terrain.

dtCore::Transformable * dtAnim::AnimationComponent::GetEyePointActor (  ) 

Returns:
the actor to use as an eye point for ground clamping. This determines which LOD to clamp to.

const dtCore::Transformable * dtAnim::AnimationComponent::GetEyePointActor (  )  const

Returns:
the actor to use as an eye point for ground clamping. This determines which LOD to clamp to.

void dtAnim::AnimationComponent::SetEyePointActor ( dtCore::Transformable newEyePointActor  ) 

changes the actor to use for the terrain.

void dtAnim::AnimationComponent::TickLocal ( float  dt  )  [protected, virtual]

void dtAnim::AnimationComponent::GroundClamp (  )  [protected]


Member Data Documentation

const std::string dtAnim::AnimationComponent::DEFAULT_NAME [static]

The default component name, used when looking it up on the GM.


http://www.delta3d.org
2.0.0 generated 14 Feb 2008