diff options
author | Elias Fleckenstein <eliasfleckenstein@web.de> | 2020-11-04 16:57:41 +0100 |
---|---|---|
committer | Elias Fleckenstein <eliasfleckenstein@web.de> | 2020-11-04 16:57:41 +0100 |
commit | 6ccb5835ff55d85156be91473c598eca9d6cb9a6 (patch) | |
tree | 7f1eaf8b94694c8e24e206909ba8f55a1ebfbb3e /src/client/clientobject.h | |
parent | 244713971a976e43e8740b6a9d9d122e37020ef2 (diff) | |
download | dragonfireclient-6ccb5835ff55d85156be91473c598eca9d6cb9a6.tar.xz |
Revert "Make Lint Happy"
This reverts commit ad148587dcf5244c2d2011dba339786c765c54c4.
Diffstat (limited to 'src/client/clientobject.h')
-rw-r--r-- | src/client/clientobject.h | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/src/client/clientobject.h b/src/client/clientobject.h index 1cde010c7..4a1743d72 100644 --- a/src/client/clientobject.h +++ b/src/client/clientobject.h @@ -29,6 +29,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include <unordered_map> #include <unordered_set> + class ClientEnvironment; class ITextureSource; class Client; @@ -52,20 +53,16 @@ public: virtual bool getSelectionBox(aabb3f *toset) const { return false; } virtual bool collideWithObjects() const { return false; } virtual const v3f getPosition() const { return v3f(0.0f); } - virtual scene::ISceneNode *getSceneNode() const { return NULL; } + virtual scene::ISceneNode *getSceneNode() const + { return NULL; } virtual scene::IAnimatedMeshSceneNode *getAnimatedMeshSceneNode() const - { - return NULL; - } + { return NULL; } virtual bool isLocalPlayer() const { return false; } virtual ClientActiveObject *getParent() const { return nullptr; }; virtual const std::unordered_set<int> &getAttachmentChildIds() const - { - static std::unordered_set<int> rv; - return rv; - } - virtual void updateAttachments(){}; + { static std::unordered_set<int> rv; return rv; } + virtual void updateAttachments() {}; virtual bool doShowSelectionBox() { return true; } @@ -85,15 +82,12 @@ public: virtual void initialize(const std::string &data) {} // Create a certain type of ClientActiveObject - static ClientActiveObject *create( - ActiveObjectType type, Client *client, ClientEnvironment *env); + static ClientActiveObject *create(ActiveObjectType type, Client *client, + ClientEnvironment *env); // If returns true, punch will not be sent to the server virtual bool directReportPunch(v3f dir, const ItemStack *punchitem = nullptr, - float time_from_last_punch = 1000000) - { - return false; - } + float time_from_last_punch = 1000000) { return false; } protected: // Used for creating objects based on type @@ -101,7 +95,6 @@ protected: static void registerType(u16 type, Factory f); Client *m_client; ClientEnvironment *m_env; - private: // Used for creating objects based on type static std::unordered_map<u16, Factory> m_types; @@ -118,7 +111,7 @@ public: d = a_d; } - bool operator<(const DistanceSortedActiveObject &other) const + bool operator < (const DistanceSortedActiveObject &other) const { return d < other.d; } |