mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-06-07 03:25:10 +00:00
Trying things.
This commit is contained in:
@@ -8,9 +8,9 @@
|
||||
|
||||
namespace BBM
|
||||
{
|
||||
AnimationsComponent::AnimationsComponent(WAL::Entity &entity, const RAY::ModelAnimations &modelAnimation, int animIndex, bool play)
|
||||
AnimationsComponent::AnimationsComponent(WAL::Entity &entity, int animIndex, bool play)
|
||||
: WAL::Component(entity),
|
||||
_modelAnimation(modelAnimation),
|
||||
_modelAnimation("assets/player/player.iqm"),
|
||||
_currentAnimIndex(animIndex),
|
||||
_animDisabled(play)
|
||||
{
|
||||
@@ -20,7 +20,6 @@ namespace BBM
|
||||
WAL::Component *AnimationsComponent::clone(WAL::Entity &entity) const
|
||||
{
|
||||
return new AnimationsComponent(entity,
|
||||
RAY::ModelAnimations(this->_modelAnimation.getFilePath()),
|
||||
this->_currentAnimIndex);
|
||||
}
|
||||
|
||||
@@ -29,7 +28,7 @@ namespace BBM
|
||||
return this->_modelAnimation.at(this->_currentAnimIndex).getFrameCounter();
|
||||
}
|
||||
|
||||
RAY::ModelAnimation AnimationsComponent::getCurrentModelAnim()
|
||||
RAY::ModelAnimation &AnimationsComponent::getCurrentModelAnim()
|
||||
{
|
||||
return this->_modelAnimation[this->_currentAnimIndex];
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace BBM
|
||||
size_t getCurrentAnimFrameCounter() const;
|
||||
|
||||
//! @brief get the current
|
||||
RAY::ModelAnimation getCurrentModelAnim();
|
||||
RAY::ModelAnimation &getCurrentModelAnim();
|
||||
|
||||
//! @brief set the anim frame counter
|
||||
void setCurrentAnimFrameCounter(size_t animFrameCounter);
|
||||
@@ -52,7 +52,7 @@ namespace BBM
|
||||
bool isAnimDisabled() const;
|
||||
|
||||
//! @brief ctor entity and the path of the animation file
|
||||
explicit AnimationsComponent(WAL::Entity &entity, const RAY::ModelAnimations& modelAnimation, int animIndex, bool play = true);
|
||||
AnimationsComponent(WAL::Entity &entity, int animIndex, bool play = true);
|
||||
//! @brief copy ctor
|
||||
AnimationsComponent(const AnimationsComponent &) = default;
|
||||
//! @brief dtor
|
||||
|
||||
Reference in New Issue
Block a user