Closed napolitanod closed 2 years ago
Edited to indicate that I also tried await canvas.hud.bubbles.say(game.user.targets.first(), 'hi', {emote:{language: 'dwarvish'}}) and await canvas.hud.bubbles.say(game.user.targets.first(), 'hi', {emote:{language: 'orc'}}). I believe following the wiki instruction this is the proper way.
The example on the Wiki had some mistakes: it lacked the "function" declaration for foo() and result
wasn't declared when it should've been a string.
{emote:{language: 'dwarvish'}}
is the correct way.
game.user.targets.first()
requires you to be targetting a token, not just selecting it. If you try to make a bubble without a token, Foundry just ignores it. If you were targeting a token, it works correctly. You should've just use token
instead.
Thank you. I am targeting the token when using game.user.targets.first()
and I am seeing the chat bubble I just can't get the polyglot to encode the chat into the provided language on my DM session or in the player's session. I'll keep trying things out.
Oh, I see the error now. It assumes there is a message for the scrambling and it throws errors.
Even with that fixed, I don't see a Chat Bubble being reproduced on other player's screens, and I'm not sure about that one.
Oh nice! The chat bubble on another player's screen requires a socket call, which I am also doing. When available, I'll see if the fix makes it show in the other language via the socket call.
Oh, okay, I was worried something else was broken with the bubbles.
I just pushed a update. It should work for you now.
Yes, that did it. Thank you!!!
Describe the bug Hello! If I recall correctly, this worked at a point in time in the past, maybe before R9? I am attempting to follow the guide found here: https://github.com/League-of-Foundry-Developers/fvtt-module-polyglot/wiki/Macros for generating a chat bubble that is altered by Polyglot. Note that I am following the instruction just for the chat bubble - I don't want the chat message to generate. I am not seeing the polyglot transform the chat bubble text. It is highly likely I am doing it wrong :(
To Reproduce Steps to reproduce the behavior:
Expected behavior I expected the text in the chat bubble to be translated to dwarvish. When sent over sockets I also expected the same. I also tried orc.
Additional context