diff options
author | rtk0c <[email protected]> | 2022-05-07 17:27:01 -0700 |
---|---|---|
committer | rtk0c <[email protected]> | 2022-05-07 17:27:01 -0700 |
commit | 9fcdfe312fd9809a1cd52c08e7d8d7bd991a9fb3 (patch) | |
tree | c9820ea29a0d38c2adb7464386233415bfcccc10 /source/App.hpp | |
parent | f348347f205f51800d0628021f193e63f5833f8d (diff) |
Changeset: 25 Reduce dependency between editor headers and main game headers
Diffstat (limited to 'source/App.hpp')
-rw-r--r-- | source/App.hpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/source/App.hpp b/source/App.hpp index 54e1fb5..c73c5a1 100644 --- a/source/App.hpp +++ b/source/App.hpp @@ -17,14 +17,11 @@ using KeyCaptureCallback = std::function<bool(int, int)>; -// TODO how should we split responsibilities between App and Editor? class App { - friend class EditorInstance; - private: std::deque<KeyCaptureCallback> mKeyCaptureCallbacks; PodVector<Player*> mPlayers; - std::unique_ptr<EditorInstance> mEditor; + std::unique_ptr<IEditor> mEditor; GameWorld mWorld; Renderer mWorldRenderer; Camera mMainCamera; @@ -37,8 +34,9 @@ public: App(); ~App(); - EditorInstance* GetEditor() { return mEditor.get(); } + IEditor* GetEditor() { return mEditor.get(); } GameWorld* GetWorld() { return &mWorld; } + Renderer* GetWorldRenderer() { return &mWorldRenderer; } Camera* GetActiveCamera() const; void BindActiveCamera(Camera* camera); |