Hello, long time lurker and module builder, although I doubt I can release it because of copywrite issues.
Be that as it may, I’ve got a bunch of symbolic dice buttons and would like a sound played when clicked. I’ve got it working on the normal dice rollers using a multi action button and I can play the sound if I use a hotkey to roll the symbolic dice… But I can’t work out how to get a sound when clicking on the symbolic dice on the menu using your mouse.
Is it possible? How so?
Also, I’ve been playing around with triggering a global based on range with some odd results. Where is the range measured from? the to right corner or the centre of a tile? Is it in grid squares or pixels?
if you have this working for a normal die roller ir should be the same. Make the normal Symbolic Dice roller button invisible by setting no icon and no button name. Do the same for the action button that fires off the sound. Then use a multi-action button to fire off the Symbolic die and the action button.
I tried this and could only get it to display the symbolic dice results when using the display results in a window option, not in the button which is what I’ve setup because it makes for a cleaner UI. without display in a new window it does roll the dice and show the result in the text buffer but you don’t get to see the dice at all.
It’s nothing to do with Multi-action buttons or adding sounds, it is a straight bug in the Symbolc Dice Button. When you select the ‘Show Results in button’ option to display the die in the toolbar button, the toolbar button dissappears, never to be seen again.
I have added bug:
Bug 4762 -Symbolic Dice Button ‘Show Results in Button’ option causes button to dissappear
and will look into it for 3.1.21 and next 3.2 beta.
It’s not actually a bug. I thought I was going mad for a moment while I was investigating this!
The problem is caused by the interaction between the Multi-Action button and the Symbolic Die button. When you use a Multi-action button, it hides the toolbar buttons that it is is activating, but the Symbolic Die button is trying to show the results of the roll in the toolbar button, so it doesn’t work.
Instead of using a Multi-Action button to initiate the roll and sound by button name, use a Do Action button and initiate the roll and sound via Hot keys.
The Do Action button does not do any toolbar hiding. You will need to hide the Play Sound button youself by not specifying a fbutton text or icon.
I’m pretty sure what you’re describing is what I’ve already done. Maybe I’m not explaining it right but in essence I do have the roll and sound playing together when using a hotkey from the keyboard. I was trying to get the roll and sound playing when clicking the dice on the toolbar with the mouse as well. I think I’ve exhausted the possibilities on achieving that so will let that lie.
I did find a work around by setting up a random layer on select game piece. Difference is the dice are now on the board. I might go with that, will see what my opponent prefers.
Is it possible to use a global key command on a game piece (or something similar) to fire a hotkey on the toolbar? So you click a game piece on the board and it rolls the symbolic dice on the toolbar? I couldn’t figure that out.
Thanks very much for taking the time to provide advice
No, that’s not going to be possible to get a sound playing as well using the same toolbar button that shows the dice. You can only get it to work by having a separate button that rolls the dice and plays the sound.
Yes, you use a Global Hotkey trait in the counter. This will send the specified Hotkey to all of the module and map level components.