[Question] Problem With "Texture" Frame and SetTexture
Hi Folks,
i started write my first addon some days ago and i'm getting now an real strange problem. I want to use an texture frame to show an "Close" Button. If i use an texture from another addon (for example SetTexture("LuaPad", "close.png")) it works fine. If i copy the image to my addon folder (for testing only :D) and change it to SetTexture("MyAddon", "close.png") or (SetTexture("MyAddon", "Textures/close.png")) the image will not displayed anymore. I have tried the root folder of my addon and an subfolder like "Textures". But nothing works. I'm verry confused now and i have no idea whats the problem. The code can found @ Pastebin here. The complete addon can be found here. I have installed the LuaPad Addon for testing purposes ingame. Can someone help me with that? |
Your addon identifier in RiftAddon.toc is Wrytch_it, but you reference it as a WrytchIt in your addon (:SetTexure()), but Wrytch_It in the Event handlers.
These all need to be consistent. One thing you can do to make life easier. At the very top of your .lua files, put : local addon, shareddata = ... Then, you can refer to the addon using addon.identifier : closeButton:SetTexture(addon.identifier, "Textures/close.png") table.insert(Command.Slash.Register("wrytchit"), {showWrytchIt, addon.identifier, "Slash command"}) |
Thank You!
That was the problem, i would haven't found that :( |
All times are GMT -6. The time now is 01:49 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2022 MMOUI