X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fgame%2Fentity.h;h=e6d1cf940cd8da44783976a29fd1ce407cf01770;hb=12c863fc1bc5456a4b3aceacc88904d76bd1d8bb;hp=c4cf83c119b26bce36fce09ac1238be2bebcd1d2;hpb=c3ac50ad3e79b26d1d99bd222a7e43adb86c2c1e;p=libs%2Fgame.git diff --git a/source/game/entity.h b/source/game/entity.h index c4cf83c..e6d1cf9 100644 --- a/source/game/entity.h +++ b/source/game/entity.h @@ -2,6 +2,7 @@ #define MSP_GAME_ENTITY_H_ #include "handle.h" +#include "mspgame_api.h" #include "owned.h" namespace Msp::Game { @@ -11,13 +12,13 @@ class Stage; class Transform; struct TransformValues; -class hierarchy_error: public std::logic_error +class MSPGAME_API hierarchy_error: public std::logic_error { public: hierarchy_error(): std::logic_error("hierarchy error") { } }; -class Entity +class MSPGAME_API Entity { public: enum TransformTag { NO_TRANSFORM }; @@ -35,6 +36,7 @@ public: void add_component(Handle); void remove_component(Handle); + const std::vector> &get_components() const { return components; } template Handle get_component();