defineFunction () and Chat Output

Discuss macro implementations, ask for macro help (to share your creations, see User Creations, probably either Campaign Frameworks or Drop-in Resources).

Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice

Post Reply
ladyathena
Cave Troll
Posts: 78
Joined: Wed Jun 03, 2009 6:38 pm
Contact:

defineFunction () and Chat Output

Post by ladyathena »

I'm sure you'll be seeing a lot more of me on here over the next few months so I'll apologize in advance: I'll have noob questions. :P

Here's my first:
I'm just creating macro buttons that change the player visibility on the selected token. Handy. :)

Code: Select all

[setVisible(0)]
and

Code: Select all

[setVisible(1)]
These do the trick, obviously, but I want to stop the chat output. I've read that defineFunction() might do this.

Code: Select all

defineFunction("visibility", "setVisible(0)", "ignoreOutput=true")
This is the best I could come up with on my own and it's not working. Where am I going wrong?

I'm thinking it might be with the function name of "visibility" because *cringe* I just slapped it in there. It's not related to anything else other than that's what I chose to put in there. I couldn't figure out anything else to do about it.

User avatar
CoveredInFish
Demigod
Posts: 3104
Joined: Mon Jun 29, 2009 10:37 am
Location: Germany
Contact:

Re: defineFunction () and Chat Output

Post by CoveredInFish »

If i understand you right, you might be looking for

Code: Select all

[h:setVisible()]
The H-Roll Option disables the output.

ladyathena
Cave Troll
Posts: 78
Joined: Wed Jun 03, 2009 6:38 pm
Contact:

Re: defineFunction () and Chat Output

Post by ladyathena »

Ah, I did try that but then the token icon still pops up in the chat window, there's just nothing that gets said. So, yes, it hides the 1 or the 0 but the token is popping up like it's being impersonated in chat, sans a message.

User avatar
Rumble
Deity
Posts: 6235
Joined: Tue Jul 01, 2008 7:48 pm

Re: defineFunction () and Chat Output

Post by Rumble »

At the end of the macro, put:

Code: Select all

[h:abort(0)]
 
That will abort further processing and suppress output (it will, however, flip the visibility before it aborts).

ladyathena
Cave Troll
Posts: 78
Joined: Wed Jun 03, 2009 6:38 pm
Contact:

Re: defineFunction () and Chat Output

Post by ladyathena »

Rumble wrote:

Code: Select all

[h:abort(0)]
 
Cha-ching! :!: Did the trick. Thanks. :)

Post Reply

Return to “Macros”