WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   console command into addon (https://www.wowinterface.com/forums/showthread.php?t=59013)

jlrm365 01-02-22 08:37 PM

console command into addon
 
Hello. I hope the title was clear.

I'm attempting to put a console command into a basic addon, to fire when logging in, transitioning into an instance, etc.

I diligently report LUA errors, but I'd still like to play without them. To that end, I use
/console scriptErrors 0

I found this handy little wowpedia article: PLAYER_ENTERING_WORLD


I've since tried about a dozen ways to put the console command into the lua, but haven't been successful.
Could anyone do it and then possibly explain why it has to be that way (the way you did it)?

Thanks!
:cool:

Fizzlemizz 01-02-22 11:10 PM

Code:

SetCVar("scriptErrors", 0)
/console is just macro for SetCVar.

But errors should really be fixed rather than ignored.

jlrm365 01-02-22 11:13 PM

Quote:

Originally Posted by Fizzlemizz (Post 340167)
Code:

SetCVar("scriptErrors", 0)
/console is just macro for SetCVar.

But errors should really be fixed rather than ignored.

I'm aware of handling errors, which is why they're reported.

I thought it might be, the console / setcvar connection, but I was still unsure of how to put it together. It's like knowing the words in another language, but not the combinations.

I'll try to remember that.

Thanks!


EDIT:


Could you put more than one SetCVar line into a space, one after the other?
Thanks.

Dridzt 01-03-22 05:35 AM

Most proper error reporting addons have ways to make errors less intrusive (no popups etc)

So my suggestion would be to use BugGrabber & BugSack / Bugger, or any of the dedicated error catching addons, then look through their options to mute their output.

Fizzlemizz 01-03-22 10:15 AM

Quote:

Originally Posted by jlrm365 (Post 340168)
EDIT:


Could you put more than one SetCVar line into a space, one after the other?
Thanks.

Yes........

jlrm365 01-03-22 12:30 PM

Quote:

Originally Posted by Dridzt (Post 340169)
Most proper error reporting addons have ways to make errors less intrusive (no popups etc)

So my suggestion would be to use BugGrabber & BugSack / Bugger, or any of the dedicated error catching addons, then look through their options to mute their output.

I was aware and I do report, but thanks for those.

jlrm365 01-03-22 12:30 PM

Quote:

Originally Posted by Fizzlemizz (Post 340170)
Yes........

Thanks.
That's the thread answered.
Much appreciated.
:cool:


All times are GMT -6. The time now is 12:42 AM.

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