aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormegamage <none@none>2009-08-30 18:32:55 -0500
committermegamage <none@none>2009-08-30 18:32:55 -0500
commitc07707ba47d75b18b84b5602aa5224078e1b40e3 (patch)
tree981ae8b8c06b67f01dfa377bc781608eedc66f9d
parent6f2abca19b04e8d773e7f27fa276d6663efcd7fb (diff)
*Fix a crash caused by movementinform. Thanks to new001.
--HG-- branch : trunk
-rw-r--r--src/game/PointMovementGenerator.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/game/PointMovementGenerator.cpp b/src/game/PointMovementGenerator.cpp
index 035c046b26a..23012f7e170 100644
--- a/src/game/PointMovementGenerator.cpp
+++ b/src/game/PointMovementGenerator.cpp
@@ -68,7 +68,8 @@ void PointMovementGenerator<T>:: Finalize(T &unit)
{
if(unit.hasUnitState(UNIT_STAT_CHARGING))
unit.clearUnitState(UNIT_STAT_CHARGING | UNIT_STAT_JUMPING);
- MovementInform(unit);
+ if(arrived) // without this crash!
+ MovementInform(unit);
}
template<class T>