Thread: KGPanels script
View Single Post
11-10-14, 12:28 AM   #26
Choonstertwo
A Chromatic Dragonspawn
 
Choonstertwo's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2011
Posts: 194
Originally Posted by suicidalkatt View Post
You want to check that the event passed is equal to the name of the event:
You're initialising the oEvents table as an array of strings (i.e. strings are values), but you're using it as if it were a hashset (i.e. strings are keys).

You should be initialising it like this:
lua Code:
  1. local oEvents = { -- These are events that we can check for
  2.     GOSSIP_SHOW = true,
  3.     BANKFRAME_OPENED = true,
  4.     GUILDBANKFRAME_OPENED = true
  5. }
  Reply With Quote