mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-05-25 23:49:03 +00:00
3D drawables all have a position. Non-positionable object will throw an error when a setter/getter is called
This commit is contained in:
@@ -7,8 +7,8 @@
|
||||
|
||||
#include "Drawables/ADrawable3D.hpp"
|
||||
|
||||
RAY::Drawables::Drawables3D::ADrawable3D::ADrawable3D(const RAY::Color &color):
|
||||
_color(color)
|
||||
RAY::Drawables::Drawables3D::ADrawable3D::ADrawable3D(const RAY::Vector3 &position, const RAY::Color &color):
|
||||
_position(position), _color(color)
|
||||
{
|
||||
|
||||
}
|
||||
@@ -23,3 +23,16 @@ RAY::Drawables::Drawables3D::ADrawable3D &RAY::Drawables::Drawables3D::ADrawable
|
||||
this->_color = color;
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
const RAY::Vector3 &RAY::Drawables::Drawables3D::ADrawable3D::getPosition(void) const
|
||||
{
|
||||
return this->_position;
|
||||
}
|
||||
|
||||
|
||||
RAY::Drawables::Drawables3D::ADrawable3D &RAY::Drawables::Drawables3D::ADrawable3D::setPosition(const RAY::Vector3 &position)
|
||||
{
|
||||
this->_position = position;
|
||||
return *this;
|
||||
}
|
||||
Reference in New Issue
Block a user