Class Object

Inheritance Relationships

Derived Types

Class Documentation

class game::environment::Object

Subclassed by game::environment::Monster, game::environment::Player

Public Functions

Object(uint32_t vid, int32_t x = 0, int32_t y = 0, float rotation = 0)
~Object()
void Show(const std::shared_ptr<core::networking::Connection> &connection) = 0
void Remove(const std::shared_ptr<core::networking::Connection> &connection) = 0
void Update(uint32_t elapsedTime)
void OnSpawned() = 0
void TakeDamage(const std::shared_ptr<Object> &object, int damage) = 0
void ObjectEnteredView(std::shared_ptr<Object> object) = 0
void ObjectLeftView(std::shared_ptr<Object> object) = 0
std::shared_ptr<Object> GetPointer() = 0
int32_t GetHP() = 0
int32_t GetMaxHP() = 0
void AddObjectToView(const std::shared_ptr<Object> object)
void RemoveObjectFromView(const std::shared_ptr<Object> object)
void RemoveObjectFromView()
void SendPacketAround(const std::shared_ptr<core::networking::Packet> &packet)
void ForEachAround(const std::function<void(const std::shared_ptr<Object>&)> &function)
size_t GetObjectsInViewCount()
void AddTargetedBy(uint32_t vid, const std::weak_ptr<Player> &object)
void RemoveTargetedBy(uint32_t vid)
ObjectType GetObjectType() const = 0
const std::string &GetName() const = 0
uint32_t GetVID() const
int32_t GetPositionX() const
void SetPositionX(int32_t posX)
int32_t GetPositionY() const
void SetPositionY(int32_t posY)
float GetRotation() const
void SetRotation(float rotation)
std::shared_ptr<Map> GetMap() const
void SetMap(std::shared_ptr<Map> map)
bool GetPositionModified() const
void SetPositionModified(bool positionModified)
void RefreshTarget()
void ClearTarget()
bool IsDead()
void Dead()

Protected Attributes

uint32_t _vid
bool _positionModified
float _rotation
std::shared_ptr<Map> _map
bool _dead = false