Add GetDBTableGuid method

This commit is contained in:
Rochet2
2015-07-05 10:03:05 +03:00
parent 447021e849
commit 02c7a06410
3 changed files with 35 additions and 1 deletions

View File

@@ -146,6 +146,22 @@ namespace LuaGameObject
return 1;
}
/**
* Returns the guid of the [GameObject] that is used as the ID in the database
*
* @return uint32 dbguid
*/
int GetDBTableGUIDLow(Eluna* /*E*/, lua_State* L, GameObject* go)
{
#ifdef TRINITY
Eluna::Push(L, go->GetDBTableGUIDLow());
#else
// on mangos based this is same as lowguid
Eluna::Push(L, go->GetGUIDLow());
#endif
return 1;
}
/**
* Sets the state of a [GameObject]
*