WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   AddOn Search/Requests (https://www.wowinterface.com/forums/forumdisplay.php?f=6)
-   -   How to hide the "Not ready yet" error? (https://www.wowinterface.com/forums/showthread.php?t=59748)

Rienwe 01-01-24 12:39 PM

How to hide the "Not ready yet" error?
 
Hi all, I would like to hide the error text "not ready yet" that appears on the screen when I use the following macro:

#showtooltip Feign Death
/use Wisp in a Bottle
/cast Feign Death

I added /run UIErrorsFrame:Hide() at the beggining of the macro but that disable all error messages. Is there a way to just hide the "Not ready yet" error text and keep all other error messages? Can an addon hide only that specific error text?

SDPhantom 01-01-24 04:34 PM

These functions exist, but don't have any slash command strings registered for them.
Lua Code:
  1. SlashCmdList["UI_ERRORS_OFF"] = function(msg)
  2.     UIErrorsFrame:UnregisterEvent("UI_ERROR_MESSAGE");
  3.     SetCVar("Sound_EnableSFX", "0");
  4. end
  5.  
  6. SlashCmdList["UI_ERRORS_ON"] = function(msg)
  7.     UIErrorsFrame:RegisterEvent("UI_ERROR_MESSAGE");
  8.     SetCVar("Sound_EnableSFX", "1");
  9. end
FrameXML\ChatFrame.lua:2379

You can call them using these commands.
Code:

/run SlashCmdList.UI_ERRORS_OFF()
/run SlashCmdList.UI_ERRORS_ON()

Note: msg is the string of arguments after the slash commands, usually an empty string for commands that don't use them. These functions don't even reference the variable so it's safe to omit it entirely.

Dridzt 01-03-24 05:46 AM

If it wasn't clear SDPhantom is suggesting you sandwich your /use and /cast between those 2.

Rienwe 01-03-24 09:37 AM

Oh ok I think i got it now, thanks :)


All times are GMT -6. The time now is 02:11 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI