summaryrefslogtreecommitdiffhomepage
path: root/src/character.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2023-03-19 03:09:18 +0100
committerStanislaw Halik <sthalik@misaki.pl>2023-03-19 03:09:18 +0100
commit02e32261880cfd90c300907c01e2e87e59dc7343 (patch)
treee306672eaf8bc99d6ee135b947d55e8f73d9bf46 /src/character.cpp
parent67f029d1192f7baf881f6c1afd0bb2c301165ae9 (diff)
src/entity: short-circuit in can_rotate()
Diffstat (limited to 'src/character.cpp')
-rw-r--r--src/character.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/character.cpp b/src/character.cpp
index f63b35e9..31376925 100644
--- a/src/character.cpp
+++ b/src/character.cpp
@@ -125,7 +125,7 @@ bool character::update(size_t i, float dt)
offset_frac = Vector2s(Vector2(std::fmod(offset_[0], 1.f), std::fmod(offset_[1], 1.f)) * frac);
auto off_i = Vector2i(offset_);
if (can_move_to(off_i))
- i = move(i, off_i, new_r);
+ i = move_to(i, off_i, new_r);
++frame %= atlas->info().nframes;
}
//Debug{} << "pos" << Vector2i(pos.local());