mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-25 06:36:24 +00:00
refactor(Core): rename namespaces and macros to acore (#2454)
This commit is contained in:
@@ -4,8 +4,8 @@
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*/
|
||||
|
||||
#ifndef TRINITY_PACKETLOG_H
|
||||
#define TRINITY_PACKETLOG_H
|
||||
#ifndef ACORE_PACKETLOG_H
|
||||
#define ACORE_PACKETLOG_H
|
||||
|
||||
#include "Common.h"
|
||||
#include <ace/Singleton.h>
|
||||
|
||||
@@ -192,7 +192,7 @@ void WorldSession::SendPacket(WorldPacket const* packet)
|
||||
if (!m_Socket)
|
||||
return;
|
||||
|
||||
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) && defined(TRINITY_DEBUG)
|
||||
#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) && defined(ACORE_DEBUG)
|
||||
// Code for network use statistic
|
||||
static uint64 sendPacketCount = 0;
|
||||
static uint64 sendPacketBytes = 0;
|
||||
@@ -226,7 +226,7 @@ void WorldSession::SendPacket(WorldPacket const* packet)
|
||||
sendLastPacketCount = 1;
|
||||
sendLastPacketBytes = packet->wpos(); // wpos is real written size
|
||||
}
|
||||
#endif // !TRINITY_DEBUG
|
||||
#endif // !ACORE_DEBUG
|
||||
|
||||
sScriptMgr->OnPacketSend(this, *packet);
|
||||
|
||||
@@ -639,7 +639,7 @@ void WorldSession::SendNotification(const char *format, ...)
|
||||
|
||||
void WorldSession::SendNotification(uint32 string_id, ...)
|
||||
{
|
||||
char const* format = GetTrinityString(string_id);
|
||||
char const* format = GetAcoreString(string_id);
|
||||
if (format)
|
||||
{
|
||||
va_list ap;
|
||||
@@ -655,9 +655,9 @@ void WorldSession::SendNotification(uint32 string_id, ...)
|
||||
}
|
||||
}
|
||||
|
||||
char const* WorldSession::GetTrinityString(uint32 entry) const
|
||||
char const* WorldSession::GetAcoreString(uint32 entry) const
|
||||
{
|
||||
return sObjectMgr->GetTrinityString(entry, GetSessionDbLocaleIndex());
|
||||
return sObjectMgr->GetAcoreString(entry, GetSessionDbLocaleIndex());
|
||||
}
|
||||
|
||||
void WorldSession::Handle_NULL(WorldPacket& recvPacket)
|
||||
@@ -855,7 +855,7 @@ void WorldSession::ReadMovementInfo(WorldPacket &data, MovementInfo* mi)
|
||||
|
||||
//! Anti-cheat checks. Please keep them in seperate if() blocks to maintain a clear overview.
|
||||
//! Might be subject to latency, so just remove improper flags.
|
||||
#ifdef TRINITY_DEBUG
|
||||
#ifdef ACORE_DEBUG
|
||||
#define REMOVE_VIOLATING_FLAGS(check, maskToRemove) \
|
||||
{ \
|
||||
if (check) \
|
||||
|
||||
@@ -342,7 +342,7 @@ class WorldSession
|
||||
// Locales
|
||||
LocaleConstant GetSessionDbcLocale() const { return m_sessionDbcLocale; }
|
||||
LocaleConstant GetSessionDbLocaleIndex() const { return m_sessionDbLocaleIndex; }
|
||||
char const* GetTrinityString(uint32 entry) const;
|
||||
char const* GetAcoreString(uint32 entry) const;
|
||||
|
||||
uint32 GetLatency() const { return m_latency; }
|
||||
void SetLatency(uint32 latency) { m_latency = latency; }
|
||||
|
||||
@@ -97,7 +97,7 @@ class ReactorRunnable : protected ACE_Task_Base
|
||||
|
||||
int AddSocket (WorldSocket* sock)
|
||||
{
|
||||
TRINITY_GUARD(ACE_Thread_Mutex, m_NewSockets_Lock);
|
||||
ACORE_GUARD(ACE_Thread_Mutex, m_NewSockets_Lock);
|
||||
|
||||
++m_Connections;
|
||||
sock->AddReference();
|
||||
@@ -118,7 +118,7 @@ class ReactorRunnable : protected ACE_Task_Base
|
||||
|
||||
void AddNewSockets()
|
||||
{
|
||||
TRINITY_GUARD(ACE_Thread_Mutex, m_NewSockets_Lock);
|
||||
ACORE_GUARD(ACE_Thread_Mutex, m_NewSockets_Lock);
|
||||
|
||||
if (m_NewSockets.empty())
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user