From 2b975e65a77cf36dea8045a4b8c9859936ee9f48 Mon Sep 17 00:00:00 2001 From: Maximilian Fricke Date: Sun, 10 Feb 2019 19:52:12 +0100 Subject: [PATCH] unit: Fix bug in unit movement animation Do not tag unit appearance as changed when calling set_facing() and the unit facing did not actually change --- src/units/unit.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/units/unit.cpp b/src/units/unit.cpp index ab19ed89f42..a207544261f 100644 --- a/src/units/unit.cpp +++ b/src/units/unit.cpp @@ -1573,7 +1573,7 @@ void unit::write(config& cfg, bool write_all) const void unit::set_facing(map_location::DIRECTION dir) const { - if(dir != map_location::NDIRECTIONS) { + if(dir != map_location::NDIRECTIONS && dir != facing_) { appearance_changed_ = true; facing_ = dir; }