View Single Post
03-14-10, 05:02 PM   #10
Akryn
A Firelord
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 479
Originally Posted by Haleth View Post
Well, the CreateBG is used to both make a background as well as a border (hence the offset) for frames, for example unitframes. The background doesn't show up with the code you posted. My Lua knowledge is very basic, so I don't really know why.
Oh, based on your OP it sounded like it was just being applied to the minimap. If you're using it for multiple frames you're certainly correct that you don't want to use that code. However the same problem is still true. If you want to modify a texture you've already created, you should save a reference to it and actually modify the texture, rather than creating a new one. It's only a bit more complicated if you're applying the same function to multiple frames, just save a table in place of my single variables.
  Reply With Quote