Issue with select() and IsInInstance()
View Single Post
04-15-13, 03:36 AM
A Pyroguard Emberseer
Join Date: Mar 2010
Originally Posted by
Because the server tells the client that someone capped the base, just like the server tells the client that the spell you just cast crit for X damage. However, that's completely irrelevant, because addons are not aware of the server at all. As far as addons are concerned, the base wasn't capped until the client learned about it and fired the relevant event.
Anyway, this is a really idiotic turn for this discussion to take, since nothing mentioned in this thread has anything whatsoever to do with server querying.
gets info from the client, not the server, and
is a Lua language function and thus completely unrelated to either the client or the server.
99% of functions get info directly from the client. Even for functions like
where you can ask the client for information it doesn't have, and the client will ask the server for it, addons aren't aware of the server querying process -- as far as your addon is concerned, the item you asked about just doesn't exist at that time. Since
know about the server, you can program your addon to wait 5 seconds and ask the client again, but your addon can't automatically go "oh, the client doesn't have this info, it's getting it from the server, let me wait 5 seconds". Latency is a network issue; it has absolutely nothing to do with the speed of calling a function vs looking up a table value.
My point is about which function can read thoose information faster, lets see if i want to check an event like capped a base with: "CHAT_MSG_BG_SYSTEM_ALLIANCE" or "CHAT_MSG_BG_SYSTEM_HORDE" or "CHAT_MSG_RAID_BOSS_EMOTE", which events gets triggered by another "events". And if i use:
local textureIndex = select(3, GetMapLandmarkInfo(i)) if textureIndex == 128 then end
Then i used "slow function", and i still get the information faster then before the actual event triggers.
View Public Profile
Send a private message to Resike
Find More Posts by Resike