Thanks for the pointers, Slakah!
I've been looking at the global environment as an option, but hadn't tried implementing it yet (still learning the ins and outs of Lua)
In any case, I only want to hide the frames while in combat. I need to be able to switch out their OnShow, and run their IsShown, Show, and Hide functions so my questions are:
1. How can I store global frames in a table in such a way as to run its methods?
-- that is what I was trying to do in my code sample
2. Is there a way to copy a method to a local using the global environment?
or can I simply use
Code:
function ORIG_OnShow = g["ChatFrame"..i].OnShow
to save it and
Code:
g["ChatFrame"..i]:OnShow()
to run it?