Using one AddOn to change another AddOn's variables?
Hello again,
The GW2UI addon has the following variables Lua Code:
Is it possible to use my own addon to change those variables without having to edit the GW2_UI code? If so, what are the steps I should take? I imagine it's something along the lines of handling the player_login event, and then...? just re-defining the variable? |
Only if the GW variable is not defined local. Otherwise none of those variables are accessible outside of the addon.
But I suspect GW is the variable they use as their addon wide variable so that any file in their addon can access it but not other addons. If it is possible, you would handle ADDON_LOADED event and watch for the addon to be loaded and utilise any accessible elements after that point. |
The GW table is indeed their local addon table. This is at the top of their core/consts.lua file (where OP's code is)
local _, GW = ... GW is not accessible outside of the addon. |
All times are GMT -6. The time now is 04:08 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI