diff options
author | Shauren <shauren.trinity@gmail.com> | 2011-04-21 21:13:47 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2011-04-21 21:13:47 +0200 |
commit | cb3e6dbce325290fd649ce469adc253fee54f844 (patch) | |
tree | 62d7b07e34fde6b98a6638720fb1f0face236595 /src | |
parent | 03852e14e597b4bf8581e7904e6ce82de3a8f7e7 (diff) |
Core/Spells: Fixed players getting stuck in shapeshift forms after too quick shifting
Diffstat (limited to 'src')
-rwxr-xr-x | src/server/game/Entities/Unit/Unit.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index 536d9c0ff18..6a6cd82af15 100755 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -1769,7 +1769,15 @@ class Unit : public WorldObject uint64 m_ObjectSlot[4]; ShapeshiftForm GetShapeshiftForm() const { return ShapeshiftForm(GetByteValue(UNIT_FIELD_BYTES_2, 3)); } - void SetShapeshiftForm(ShapeshiftForm form) { SetByteValue(UNIT_FIELD_BYTES_2, 3, form); } + void SetShapeshiftForm(ShapeshiftForm form) + { + SetByteValue(UNIT_FIELD_BYTES_2, 3, form); + + // force update as too quick shapeshifting and back + // causes the value to stay the same serverside + // causes issues clientside (player gets stuck) + ForceValuesUpdateAtIndex(UNIT_FIELD_BYTES_2); + } inline bool IsInFeralForm() const { |