Core/Unit: Fix movement hiccups in water

Port From (https://github.com/TrinityCore/TrinityCore/commit/6b242eee130f1ac405187a03cefaf595d857ad99)
This commit is contained in:
hondacrx
2022-05-24 18:20:46 -04:00
parent 5b76bfe10d
commit a89977ad99
7 changed files with 52 additions and 5 deletions
+4
View File
@@ -417,6 +417,10 @@ namespace Game.Entities
AddUnitState(UnitState.Charmed);
Creature creature = ToCreature();
if (creature != null)
creature.RefreshSwimmingFlag();
if (!IsPlayer() || !charmer.IsPlayer())
{
// AI will schedule its own change if appropriate