summaryrefslogtreecommitdiff
path: root/src/unittest/test_clientactiveobjectmgr.cpp
diff options
context:
space:
mode:
authorLoic Blot <loic.blot@unix-experience.fr>2021-04-29 09:07:36 +0200
committerLoïc Blot <nerzhul@users.noreply.github.com>2021-05-03 19:49:19 +0200
commit809e68fdc0f7855730ee3409e6f1ddfe975b671f (patch)
tree4d132940fe3dd48f8044cae2c7f9ef287ee9eb25 /src/unittest/test_clientactiveobjectmgr.cpp
parent1bc855646e2c920c1df55bb73416f72295c020f4 (diff)
downloadminetest-809e68fdc0f7855730ee3409e6f1ddfe975b671f.tar.gz
minetest-809e68fdc0f7855730ee3409e6f1ddfe975b671f.tar.bz2
minetest-809e68fdc0f7855730ee3409e6f1ddfe975b671f.zip
refacto: don't use RenderingEngine singleton on CAO
* we don't need on CAO side more than SceneManager, and temporary. Pass only required SceneManager as a parameter to build CAO and add them to the current scene * Use temporary the RenderingEngine singleton from ClientEnvironment, waitfor for better solution * Make ClientActiveObject::addToScene virtual function mandatory to be defined by children to ensure we don't forget to properly define it
Diffstat (limited to 'src/unittest/test_clientactiveobjectmgr.cpp')
-rw-r--r--src/unittest/test_clientactiveobjectmgr.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/unittest/test_clientactiveobjectmgr.cpp b/src/unittest/test_clientactiveobjectmgr.cpp
index 4d2846c8d..a43855c19 100644
--- a/src/unittest/test_clientactiveobjectmgr.cpp
+++ b/src/unittest/test_clientactiveobjectmgr.cpp
@@ -29,6 +29,7 @@ public:
TestClientActiveObject() : ClientActiveObject(0, nullptr, nullptr) {}
~TestClientActiveObject() = default;
ActiveObjectType getType() const { return ACTIVEOBJECT_TYPE_TEST; }
+ virtual void addToScene(ITextureSource *tsrc, irr::scene::ISceneManager *smgr) {}
};
class TestClientActiveObjectMgr : public TestBase