summaryrefslogtreecommitdiffhomepage
path: root/editor
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-24 11:45:06 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-24 11:45:06 +0200
commitb17629cb9c85776c728a25b675be5a7cf420dbdc (patch)
tree47a8ee2fbec39be097151e1332818f6ec1c89837 /editor
parent45f285f3e31e3755bb77d48e0631b505860657c3 (diff)
a
Diffstat (limited to 'editor')
-rw-r--r--editor/app.cpp4
-rw-r--r--editor/camera.cpp4
2 files changed, 5 insertions, 3 deletions
diff --git a/editor/app.cpp b/editor/app.cpp
index 80f7600c..699d3abc 100644
--- a/editor/app.cpp
+++ b/editor/app.cpp
@@ -16,7 +16,7 @@ app::app() :
{
}
-app::~app()
+app::~app() // NOLINT(modernize-use-equals-default)
{
}
@@ -85,9 +85,11 @@ int app::run_from_argv(const int argc, const char* const* const argv)
}
int ret;
+ Pointer<floormat_main> ptr;
{
app application;
ret = application.exec();
+ ptr = std::move(application.M);
}
loader_::destroy();
return ret;
diff --git a/editor/camera.cpp b/editor/camera.cpp
index e37bd84d..ecbeafc1 100644
--- a/editor/camera.cpp
+++ b/editor/camera.cpp
@@ -34,8 +34,8 @@ void app::do_camera(float dt)
const auto max_camera_offset = Vector2d(sz * 10);
camera_offset -= dir.normalized() * (double)dt * pixels_per_second;
- camera_offset[0] = std::clamp(camera_offset[0], -max_camera_offset[0], max_camera_offset[0]);
- camera_offset[1] = std::clamp(camera_offset[1], -max_camera_offset[1], max_camera_offset[1]);
+ //camera_offset[0] = std::clamp(camera_offset[0], -max_camera_offset[0], max_camera_offset[0]);
+ //camera_offset[1] = std::clamp(camera_offset[1], -max_camera_offset[1], max_camera_offset[1]);
shader.set_camera_offset(camera_offset);
}