mirror of
https://github.com/liyunfan1223/mod-playerbots.git
synced 2026-06-20 15:39:25 +02:00
refactor(Core/Movement): Drop unused lastMoveTo* fields + std::future scratch
This commit is contained in:
parent
990e2f2016
commit
3bbe51c232
@ -14,10 +14,6 @@ LastMovement::LastMovement(LastMovement& other)
|
|||||||
taxiMaster(other.taxiMaster),
|
taxiMaster(other.taxiMaster),
|
||||||
lastFollow(other.lastFollow),
|
lastFollow(other.lastFollow),
|
||||||
lastAreaTrigger(other.lastAreaTrigger),
|
lastAreaTrigger(other.lastAreaTrigger),
|
||||||
lastMoveToX(other.lastMoveToX),
|
|
||||||
lastMoveToY(other.lastMoveToY),
|
|
||||||
lastMoveToZ(other.lastMoveToZ),
|
|
||||||
lastMoveToOri(other.lastMoveToOri),
|
|
||||||
lastFlee(other.lastFlee)
|
lastFlee(other.lastFlee)
|
||||||
{
|
{
|
||||||
lastMoveShort = other.lastMoveShort;
|
lastMoveShort = other.lastMoveShort;
|
||||||
@ -31,11 +27,6 @@ void LastMovement::clear()
|
|||||||
{
|
{
|
||||||
lastMoveShort = WorldPosition();
|
lastMoveShort = WorldPosition();
|
||||||
lastPath.clear();
|
lastPath.clear();
|
||||||
lastMoveToMapId = 0;
|
|
||||||
lastMoveToX = 0;
|
|
||||||
lastMoveToY = 0;
|
|
||||||
lastMoveToZ = 0;
|
|
||||||
lastMoveToOri = 0;
|
|
||||||
lastFollow = nullptr;
|
lastFollow = nullptr;
|
||||||
lastAreaTrigger = 0;
|
lastAreaTrigger = 0;
|
||||||
lastFlee = 0;
|
lastFlee = 0;
|
||||||
@ -55,11 +46,6 @@ void LastMovement::Set(Unit* follow)
|
|||||||
|
|
||||||
void LastMovement::Set(uint32 mapId, float x, float y, float z, float ori, float delayTime, MovementPriority pri)
|
void LastMovement::Set(uint32 mapId, float x, float y, float z, float ori, float delayTime, MovementPriority pri)
|
||||||
{
|
{
|
||||||
lastMoveToMapId = mapId;
|
|
||||||
lastMoveToX = x;
|
|
||||||
lastMoveToY = y;
|
|
||||||
lastMoveToZ = z;
|
|
||||||
lastMoveToOri = ori;
|
|
||||||
lastFollow = nullptr;
|
lastFollow = nullptr;
|
||||||
lastMoveShort = WorldPosition(mapId, x, y, z, ori);
|
lastMoveShort = WorldPosition(mapId, x, y, z, ori);
|
||||||
msTime = getMSTime();
|
msTime = getMSTime();
|
||||||
|
|||||||
@ -56,11 +56,6 @@ public:
|
|||||||
Unit* lastFollow;
|
Unit* lastFollow;
|
||||||
uint32 lastAreaTrigger;
|
uint32 lastAreaTrigger;
|
||||||
time_t lastFlee;
|
time_t lastFlee;
|
||||||
uint32 lastMoveToMapId;
|
|
||||||
float lastMoveToX;
|
|
||||||
float lastMoveToY;
|
|
||||||
float lastMoveToZ;
|
|
||||||
float lastMoveToOri;
|
|
||||||
WorldPosition lastMoveShort;
|
WorldPosition lastMoveShort;
|
||||||
uint32 msTime;
|
uint32 msTime;
|
||||||
MovementPriority priority;
|
MovementPriority priority;
|
||||||
@ -70,7 +65,6 @@ public:
|
|||||||
// used by WaitForTransport to resume a transport segment if the
|
// used by WaitForTransport to resume a transport segment if the
|
||||||
// bot is still on it next tick (e.g. boat in motion). 0 = none.
|
// bot is still on it next tick (e.g. boat in motion). 0 = none.
|
||||||
uint32 lastTransportEntry{0};
|
uint32 lastTransportEntry{0};
|
||||||
std::future<TravelPath> future;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class LastMovementValue : public ManualSetValue<LastMovement&>
|
class LastMovementValue : public ManualSetValue<LastMovement&>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user