diff options
| author | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2022-04-23 14:40:51 +0200 |
|---|---|---|
| committer | vaxerski <43317083+vaxerski@users.noreply.github.com> | 2022-04-23 14:40:51 +0200 |
| commit | 306d163613c6940e73ad58e852b42cdb236a5bc4 (patch) | |
| tree | 95d550abf8fbd4c02f25687d8b9a4f96fbdc3520 /src/helpers/AnimatedVariable.hpp | |
| parent | 77002eeea0d10661c2b90345bf6c5b9888afcff6 (diff) | |
return const refs + vec constantize
Diffstat (limited to 'src/helpers/AnimatedVariable.hpp')
| -rw-r--r-- | src/helpers/AnimatedVariable.hpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/helpers/AnimatedVariable.hpp b/src/helpers/AnimatedVariable.hpp index d6e058f0..ccdd78e3 100644 --- a/src/helpers/AnimatedVariable.hpp +++ b/src/helpers/AnimatedVariable.hpp @@ -22,37 +22,37 @@ public: ~CAnimatedVariable(); // gets the current vector value (real time) - Vector2D vec() { + const Vector2D& vec() const { ASSERT(m_eVarType == AVARTYPE_VECTOR); return m_vValue; } // gets the current float value (real time) - float fl() { + const float& fl() const { ASSERT(m_eVarType == AVARTYPE_FLOAT); return m_fValue; } // gets the current color value (real time) - CColor col() { + const CColor& col() const { ASSERT(m_eVarType == AVARTYPE_COLOR); return m_cValue; } // gets the goal vector value - Vector2D goalv() { + const Vector2D& goalv() const { ASSERT(m_eVarType == AVARTYPE_VECTOR); return m_vGoal; } // gets the goal float value - float goalf() { + const float& goalf() const { ASSERT(m_eVarType == AVARTYPE_FLOAT); return m_fGoal; } // gets the goal color value - CColor goalc() { + const CColor& goalc() const { ASSERT(m_eVarType == AVARTYPE_COLOR); return m_cGoal; } |
