Is there a way to create Hidden Die Rolls?

it works for me. Are you running it properly?

Well, I guess not.

Iā€™m on Win10/VASSAL 3.6.1. When I click the action button with my mouse nothing happens. In my PW module, I can get the mouse click to fire a die roll but it doesnā€™t pass the result to the game piece where it is displayed.

There was an action button fix in 3.6.2. Try that.

Thanks Joel, Iā€™ve installed 3.6.2 and now the Hidden Dice module from above works great. My module is almost there.

When I hit my action button it seems to fire because I get the report that the roll was made. However, it still wonā€™t pass the value to the At-Start stacked counter like it is supposed to. I get this error message:

"Bad Data in Module: Source: followProperty[DiceValue]=1d10_result Error: Strategic Intelligence Roll [Layer - Dicelevel] . Numeric field contains a non-number. "

Iā€™m not sure which Numeric field it is referring to.

Itā€™s trying to monitor the property DiceValue (this is the ā€œNumeric fieldā€ per the error message), but some string is getting stored in it instead of an integer.

Ok, thanks, I will try and follow that through.

Is there some general way find defined properties in a module? (or a list of used hotkeys?)

If youā€™re using 3.6.2 now, the Editor has a search function. Tick ā€œAdvanced Searchā€ and you should be able to find exact property names youā€™re looking for:

Properties might be found at the top level of your module (Global Properties) or scope-limited to a specific map window (also confusingly named Global Properties), or limited to the scope of the piece itself in the form of a Dynamic Property defined in the actual counter you are troubleshooting.

Based on that error message, it looks like you are assigning the literal string "1d10_result" to DiceValue somewhere (either where DiceValue is defined as a Dynamic Property, or in a Set Global Property trait, I would guess). You should just need to remove the quotes "" from around 1d10_result.

1 Like

Thanks so much for your continued help and patience. Iā€™m just stumped. My module is following exactly the Hidden Rolls example linked above. It just refuses to work.

When I tried to use the Advanced Search I generated a bug report (sent in)

Iā€™d like to share my errorlog, is there a better way than just copying/pasting it here?

Pasting the error log here is fine, but if youā€™re not getting error messages, thereā€™s likely nothing in it of use. Better would be to make your module available somewhere so someone can have a look.

ok, here is a sample

``2021-12-14 07:49:30,792 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [17364:NonCelloThread] thumbnail_util_win.cc:45:DecodePng Canā€™t decode PNG: 0x88982F04

2021-12-14 07:49:30,792 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [17364:NonCelloThread] thumbnail_util_win.cc:100:ConvertImageBufferToBitmap Canā€™t decode PNG.

2021-12-14 07:49:30,803 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [17364:NonCelloThread] thumbnail_util_win.cc:45:DecodePng Canā€™t decode PNG: 0x88982F04

2021-12-14 07:49:30,803 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [17364:NonCelloThread] thumbnail_util_win.cc:100:ConvertImageBufferToBitmap Canā€™t decode PNG.

2021-12-14 07:49:47,976 [19544-AWT-EventQueue-0] INFO VASSAL.tools.io.ProcessLauncher - launching C:\Program Files\VASSAL-3.6.2\jre\bin\java -classpath lib\Vengine.jar -Duser.dir=C:\Program Files\VASSAL-3.6.2 VASSAL.launch.ModuleManager --update-module G:\My Drive\PW2 VASSAL\Published\Module\PW2.vmod
2021-12-14 07:50:11,493 [19544-AWT-EventQueue-0] WARN VASSAL.tools.ErrorDialog - Source: followProperty[RevealedValue]=1d10_result Error: Allies S.I. Roll = (Allies S.I. Roll =) [Layer - Avalue0.PNG] . Numeric field contains a non-number. See the errorlog for more details.
2021-12-14 07:53:59,117 [19544-AWT-EventQueue-0] INFO VASSAL.tools.io.ProcessLauncher - launching C:\Program Files\VASSAL-3.6.2\jre\bin\java -classpath lib\Vengine.jar -Duser.dir=C:\Program Files\VASSAL-3.6.2 VASSAL.launch.ModuleManager --update-module G:\My Drive\PW2 VASSAL\Published\Module\PW2.vmod
2021-12-14 08:02:59,191 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [2160:NonCelloThread] thumbnail_util_win.cc:45:DecodePng Canā€™t decode PNG: 0x88982F04

2021-12-14 08:02:59,191 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [2160:NonCelloThread] thumbnail_util_win.cc:100:ConvertImageBufferToBitmap Canā€™t decode PNG.

2021-12-14 08:02:59,202 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [20436:NonCelloThread] thumbnail_util_win.cc:45:DecodePng Canā€™t decode PNG: 0x88982F04

2021-12-14 08:02:59,203 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [20436:NonCelloThread] thumbnail_util_win.cc:100:ConvertImageBufferToBitmap Canā€™t decode PNG.

2021-12-14 08:02:59,214 [18284-ProcessLauncher-2] WARN VASSAL.tools.logging.LoggedOutputStream - [20436:NonCelloThread] thumbnail_util_win.cc:45:DecodePng Canā€™t decode PNG: 0x88982F04

There are many rows of the ā€˜canā€™t decode PNGā€™ message

You have some bad images, it appears. We need to see the module to investigate further.

And just FYI, the faulty PNGs are ancillary to your ā€œpass dice result for displayā€ issue.

try this:

I assume the ā€˜Remove Unused Imagesā€™ tool may help with this?

One potential issue is that the demo module youā€™re trying to mimic uses a standard Dice Button. Your module is using Symbolic Dice Buttons. I notice that the standard Dice Button doc specifically calls out 3 special global properties that get created so you can access results in other parts of the module, whereas the Symbolic Dice Button docs do not mention the same.

1 Like

Interesting, I had that thought too. I just thought the Symbolic Dice Buttons were cool but I could switch back to regular dice buttons.

so adding a normal dice button and deleting the Symbolic ones has helped. The Action button fires, and passes a value but only once. no matter how many times i hit the Action button the displayed value never changes.

Among the things occurring on the piece with the Action Button is a Ctrl+R
(a Global Hotkey which is sending another Ctrl+R out into the void). Iā€™m guessing the Ctrl+R is meant to roll the dice in the Dice Button, but that currently has no hotkey defined in its config, so nothingā€™s out there to handle the Ctrl+R and do anything in response.

Put in Ctrl+R here and you start seeing roll results and the layer activating on the little blue square next to the Action Button.

1 Like

Just to note - the initial demo was built pre 3.3. It does work with 3.2.6 but I have not checked past that. I will say this is a very good trick however I am not qualified to tell you how it should work / why it breaks after 3.2.6. Ppl above appear to be taking up that mantle and figuring it out. Suffice to say - it can be done