Hide the dice button up in the toolbar. On your map, create an at-start-stack with a piece that indicates ‘click here to roll dice’. Set the piece up with an Action Button, so that when users click on it, it fires a global hotkey to roll the dice. In the piece is a trait called ‘play sound’ where you can load a .mp3 or .wav file.
Check out my Ghost Stories module to see how I do this (the Roll Dice Button at-start-stack to be exact).
I believe that Tim already has an example of triggering dice with a global hotkey in there…at least he’s the one who showed me the example of how to do this in the first place. =P
Dave
On Wed, Jan 28, 2009 at 1:13 PM, Thomas Russ <tar@isi.edu (tar@isi.edu)> wrote:
I dont remember putting that in the wiki. I usually just dump demo mods on the forums as its a lot easier showing how to do something with a simple demo rather than writing down trying to explain it. Perhaps all these Demos floating about in the forums should be linked to the wiki also in a category of Demonstration mods with titles that link to d/l of the example?
I believe that Tim already has an example of triggering dice with a global hotkey in there…at least he’s the one who showed me the example of how to do this in the first place. =P
Dave
On Wed, Jan 28, 2009 at 1:13 PM, Thomas Russ <tar@isi.edu (tar@isi.edu)> wrote:
Great module, Dave. Fantastic. There are too many things that I like it to list here. I have analyzed the mechanism of the three dice, the colors result instead of numbers, the sound of the dice (nice!). Is complex, at least for me.
My module has only one die. I created the piece button for launch the die. When I clic on this piece, I hear the sound of the die (wav, not mp3), but the result of die does not appear below the toolbar. I’m doing something wrong. Would be great the result next to the button, as in the Ghost Stories (numbers instead colors in my case). A little help?