mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-29 08:33:47 +00:00
feat(Core/Threading): replace ace threading (#4821)
This commit is contained in:
@@ -250,7 +250,7 @@ void MotionTransport::UpdatePosition(float x, float y, float z, float o)
|
||||
|
||||
void MotionTransport::AddPassenger(WorldObject* passenger, bool withAll)
|
||||
{
|
||||
ACORE_GUARD(ACE_Thread_Mutex, Lock);
|
||||
std::lock_guard<std::mutex> guard(Lock);
|
||||
if (_passengers.insert(passenger).second)
|
||||
{
|
||||
if (Player* plr = passenger->ToPlayer())
|
||||
@@ -279,7 +279,7 @@ void MotionTransport::AddPassenger(WorldObject* passenger, bool withAll)
|
||||
|
||||
void MotionTransport::RemovePassenger(WorldObject* passenger, bool withAll)
|
||||
{
|
||||
ACORE_GUARD(ACE_Thread_Mutex, Lock);
|
||||
std::lock_guard<std::mutex> guard(Lock);
|
||||
if (_passengers.erase(passenger) || _staticPassengers.erase(passenger))
|
||||
{
|
||||
if (Player* plr = passenger->ToPlayer())
|
||||
|
||||
@@ -91,7 +91,7 @@ private:
|
||||
bool _triggeredDepartureEvent;
|
||||
|
||||
PassengerSet _staticPassengers;
|
||||
mutable ACE_Thread_Mutex Lock;
|
||||
mutable std::mutex Lock;
|
||||
bool _passengersLoaded;
|
||||
bool _delayedTeleport;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user