ElunaLuaEngine / Eluna

Eluna Lua Engine © for WoW Emulators
https://elunaluaengine.github.io
GNU General Public License v3.0
372 stars 356 forks source link

Removed additional indirection when pushing 64 bit integers, ObjectGuids, query results and WorldPackets #472

Closed Shauren closed 6 months ago

Shauren commented 6 months ago

Extracted from my other pull request

Simple test showing that query results are still freed properly (/lol then .reload eluna to force gc)

local function OnTextEmote(event, player, textEmote, emoteNum, guid)
    for k, v in pairs(CharDBQuery("SELECT 1 as dummy"):GetRow()) do
        player:SendBroadcastMessage(k.." = "..v)
    end
end

RegisterPlayerEvent(24, OnTextEmote)

obraz