diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2024-01-15 13:46:16 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-01-15 13:46:16 +0100 |
commit | a5acc700d6a3a9b050864cf78a0f9f2305babdff (patch) | |
tree | ed3c0a02b51e19b14f92535b9640673cae84f8ac /src/object.cpp | |
parent | e850be48828ce9cf4767b88707495257c98e88b0 (diff) |
b
Diffstat (limited to 'src/object.cpp')
-rw-r--r-- | src/object.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/object.cpp b/src/object.cpp index 9d5aec5a..0139362c 100644 --- a/src/object.cpp +++ b/src/object.cpp @@ -7,6 +7,7 @@ #include "shaders/shader.hpp" #include <cmath> #include <algorithm> +#include <Corrade/Containers/GrowableArray.h> #include <Corrade/Containers/StructuredBindings.h> #include <Corrade/Containers/Pair.h> #include <Magnum/Math/Functions.h> @@ -257,7 +258,7 @@ void object::move_to(size_t& i, Vector2i delta, rotation new_r) const_cast<rotation&>(r) = new_r; const_cast<struct chunk*&>(c) = &c2; i = (size_t)std::distance(es.cbegin(), it); - es.insert(it, std::move(e_)); + arrayInsert(es, i, std::move(e_)); } } |