mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 22:37:03 +00:00
[8077] Resolve mixed store and use 2 different flags values types in single field.
* Create new monster move field in Creature class and use it in all cases when expected use MONSTER_MOVE_* flags. * Store and use MOVEMENTFLAG_* values in field in MovementInfo structure of Player class. * Cleanups and fix related code. NOTE: DB in creature_addon store values similar MONSTER_MOVE_* flags, scritps also expected set only this flags.
This commit is contained in:
parent
00fc1d7593
commit
21a6a26386
24 changed files with 215 additions and 201 deletions
|
|
@ -27,7 +27,7 @@
|
|||
void
|
||||
HomeMovementGenerator<Creature>::Initialize(Creature & owner)
|
||||
{
|
||||
owner.RemoveUnitMovementFlag(MONSTER_MOVE_WALK);
|
||||
owner.RemoveMonsterMoveFlag(MONSTER_MOVE_WALK);
|
||||
_setTargetLocation(owner);
|
||||
}
|
||||
|
||||
|
|
@ -63,7 +63,7 @@ HomeMovementGenerator<Creature>::Update(Creature &owner, const uint32& time_diff
|
|||
|
||||
if (time_diff > i_travel_timer)
|
||||
{
|
||||
owner.AddUnitMovementFlag(MONSTER_MOVE_WALK);
|
||||
owner.AddMonsterMoveFlag(MONSTER_MOVE_WALK);
|
||||
|
||||
// restore orientation of not moving creature at returning to home
|
||||
if(owner.GetDefaultMovementType()==IDLE_MOTION_TYPE)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue