diff --git a/LuaFunctions.cpp b/LuaFunctions.cpp index d11e8cb..4bc3121 100644 --- a/LuaFunctions.cpp +++ b/LuaFunctions.cpp @@ -728,6 +728,7 @@ ElunaRegister PlayerMethods[] = { "SendTabardVendorActivate", &LuaPlayer::SendTabardVendorActivate }, { "SendSpiritResurrect", &LuaPlayer::SendSpiritResurrect }, { "SendTaxiMenu", &LuaPlayer::SendTaxiMenu }, + { "SendUpdateWorldState", &LuaPlayer::SendUpdateWorldState }, { "RewardQuest", &LuaPlayer::RewardQuest }, { "SendAuctionMenu", &LuaPlayer::SendAuctionMenu }, { "SendShowMailBox", &LuaPlayer::SendShowMailBox }, diff --git a/PlayerMethods.h b/PlayerMethods.h index 8ff39b1..4e8f8f0 100644 --- a/PlayerMethods.h +++ b/PlayerMethods.h @@ -1400,6 +1400,7 @@ namespace LuaPlayer /** * Returns the database textID of the [WorldObject]'s gossip header text for the [Player] * + * @param WorldObject object * @return uint32 textId : key to npc_text database table */ int GetGossipTextId(lua_State* L, Player* player) @@ -2389,6 +2390,21 @@ namespace LuaPlayer return 0; } + /** + * Sends an update for the world state to the [Player] + * + * @param uint32 field + * @param uint32 value + */ + int SendUpdateWorldState(lua_State* L, Player* player) + { + uint32 field = Eluna::CHECKVAL(L, 2); + uint32 value = Eluna::CHECKVAL(L, 3); + + player->SendUpdateWorldState(field, value); + return 0; + } + /** * Forces the [Player] to log out *