View Single Post
04-19-21, 09:13 AM   #8
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,323
Originally Posted by samueldcorbin View Post
That actually doesn't seem to work in combat either - "Interaction failed because of an AddOn" (even run from /run with all addons disabled).
Running /click MiniMapWorldMapButton is still working fine for me (it's a chat command, not a Lua script). If you're trying to call MiniMapWorldMapButton:Click(), it won't work from a tainted execution path. While the function itself isn't protected, it doesn't magically cleanse the execution path.

Note: /run forces insecure mode and taints execution.



Originally Posted by samueldcorbin View Post
Poking around a bit more, it appears that WorldMapFrame isn't actually protected. You can call Show on it during combat
Strange. It was giving me a fit trying to call WorldMapFrame:Show() directly with addons disabled.



Originally Posted by samueldcorbin View Post
Protected frames can't be manipulated by addon code during combat, but isn't the whole point of things like SecureStateDriver to allow them to be manipulated during combat?
The SecureStateDriver basically assigns a value to a specified frame-oriented variable called an attribute by constantly evaluating macro conditionals. Setting a special attribute using it can show/hide a frame. It's a glorified unit watcher. Not what you're looking for.



Originally Posted by samueldcorbin View Post
If I'm understanding correctly, it seems like the problem is ultimately just that there's no real way to have a slash command interact with something similar to a SecureHandlerClickTemplate - presumably because there's no option to write a slash command handler that executes in a restricted environment.
Correct, though the Restricted Environment wouldn't have been much help either due to its limited access.
Note: No access to ShowUIPanel().

The SecureHandlerTemplates only works off mouse events, OnShow/OnHide, and attribute changes (see SecureStateDriver above).
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)

Last edited by SDPhantom : 04-19-21 at 09:17 AM.
  Reply With Quote