diff options
author | megamage <none@none> | 2009-05-01 21:04:02 -0500 |
---|---|---|
committer | megamage <none@none> | 2009-05-01 21:04:02 -0500 |
commit | a102098eb2f76ab1e49497c5ebbb8e6359c8b964 (patch) | |
tree | 87706926d1189d683e436e559d1c35dc3b02d2ae /src/game/Unit.cpp | |
parent | c9cd3b07f9e69030a86bcd9f06055f4247732d1d (diff) |
*Send stop packet iff necessary. Hope this can fix the bug that cannot immediatly remove confuse movement and face wrong direction after charging.
--HG--
branch : trunk
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r-- | src/game/Unit.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index d4503c0f55c..b87ba3c19fc 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -364,6 +364,8 @@ void Unit::SendMonsterStop() data << getMSTime(); data << uint8(1); SendMessageToSet(&data, true); + + clearUnitState(UNIT_STAT_MOVE); } void Unit::SendMonsterMove(float NewPosX, float NewPosY, float NewPosZ, uint32 Time, Player* player) @@ -385,6 +387,8 @@ void Unit::SendMonsterMove(float NewPosX, float NewPosY, float NewPosZ, uint32 T player->GetSession()->SendPacket(&data); else SendMessageToSet( &data, true ); + + addUnitState(UNIT_STAT_MOVE); } /*void Unit::SendMonsterMove(float NewPosX, float NewPosY, float NewPosZ, uint8 type, uint32 MovementFlags, uint32 Time, Player* player) @@ -450,6 +454,8 @@ void Unit::SendMonsterMoveByPath(Path const& path, uint32 start, uint32 end) //WPAssert( data.size() == 37 + pathnodes.Size( ) * 4 * 3 ); SendMessageToSet(&data, true); + + addUnitState(UNIT_STAT_MOVE); } void Unit::resetAttackTimer(WeaponAttackType type) |