Total RP 3: Extended

Total RP 3: Extended

903k Downloads

Script effect with access to WoW API functions

Solanya opened this issue ยท 2 comments

commented

Long-awaited feature for some players, allowing a script effect to access WoW API functions (as long as they can't be used in a harmful way) could be added.
Kruithne sent a link to the whitelist of API and Lua functions used by GHI for their own script environment. The list is 1.5 years old, and I can't tell if we have the right to use this list for Extended.

commented

While doing #46, I figured out most of what is needed to add access to the API functions, all that's left is to decide if that is something that should be done or not.

commented

After a lengthy discussion with Kaji this morning, here are some thoughts:

  • It would be great if we could present a manifest of the API functions used. The manifest will show to the end user which functions will be called by the creation in the security prompt and indicates which ones are whitelisted, greylisted or blacklisted. To get this manifest we could parse the script (look how syntax highlighting was done in the Wowlua addon) and build the list, but also let the creator of the script add functions to the list manually, for when the function call is build via a string (_G["MyFunc]()).
  • The end user can decide to accept blacklisted functions for this item only or for the creator (like secured effects)
  • Only the functions present in the manifest and that are not blacklisted will be loaded in the secure environment when the script is executed.