AZEROTHCORE compatibility (#271)

* Done Compatible AZEROTHCORE.

* Fix TC build

* Try fix whitespace (trailing and tabs2spaces)

* Remove undefs and TC_LOG defines

* Revert indentation change

* Indentation and style change

* Add more possible SQL types to query

* change bg hooks OnBGEnd parameter type.
This commit is contained in:
ayase
2018-06-06 23:42:46 +08:00
committed by Rochet2
parent 2cedb8c5af
commit 9b5499db9c
31 changed files with 869 additions and 510 deletions

View File

@@ -22,10 +22,10 @@ namespace LuaGameObject
{
uint32 questId = Eluna::CHECKVAL<uint32>(L, 2);
#ifndef TRINITY
Eluna::Push(L, go->HasQuest(questId));
#else
#if defined TRINITY || AZEROTHCORE
Eluna::Push(L, go->hasQuest(questId));
#else
Eluna::Push(L, go->HasQuest(questId));
#endif
return 1;
}
@@ -145,7 +145,7 @@ namespace LuaGameObject
*/
int GetLootRecipientGroup(lua_State* L, GameObject* go)
{
#ifdef TRINITY
#if defined TRINITY || AZEROTHCORE
Eluna::Push(L, go->GetLootRecipientGroup());
#else
Eluna::Push(L, go->GetGroupLootRecipient());
@@ -162,6 +162,8 @@ namespace LuaGameObject
{
#ifdef TRINITY
Eluna::Push(L, go->GetSpawnId());
#elif AZEROTHCORE
Eluna::Push(L, go->GetDBTableGUIDLow());
#else
// on mangos based this is same as lowguid
Eluna::Push(L, go->GetGUIDLow());
@@ -251,7 +253,7 @@ namespace LuaGameObject
bool deldb = Eluna::CHECKVAL<bool>(L, 2, false);
// cs_gobject.cpp copy paste
#ifdef TRINITY
#if defined TRINITY || AZEROTHCORE
ObjectGuid ownerGuid = go->GetOwnerGUID();
#else
ObjectGuid ownerGuid = go->GetOwnerGuid();