Thread Tools Display Modes
10-24-06, 06:12 AM   #1
Zeksie
A Fallenroot Satyr
AddOn Author - Click to view addons
Join Date: Aug 2006
Posts: 24
Event registration filter

Would speed things up no end if we could do something like:

this:RegisterEvent("SOME_EVENT", "player")
this:RegisterEvent("SOME_PET_EVENT", "pet")
this:RegisterEvent("SOME_UNIT_EVENT", "party")
this:RegisterEvent("SOME_UNIT_EVENT", "raid")
this:RegisterEvent("SOME_OTHER_EVENT", "target")

Not regexp matches as that would slow things down, just something simple to say 'I want this event, but only when it's this type of unit'.

This would allow us to remove from the LUA level a lot of identical string comparisons.

Could even make it more generic, and call the filter an arg1 filter. So that it could work for anything, although special case would need to be made to get it to work on filter names. Perhaps simply match the length of the filter with the arg1 string, so "raid" would filter in "raid1", "raid40", "raid21pet", but filter out anything that doesn't start with "raid".

Last edited by Zeksie : 10-24-06 at 06:14 AM.
  Reply With Quote

WoWInterface » Developer Discussions » Wish List » Event registration filter


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off