Dice with Random Layer Option

I am creating a module that roll a lot of diferent dice and I am using some cards with a layer random that can use as dice.

Does anyone have experience using this method and can confirm if the rolls will be balanced? Or it would be better to use normal dice.

Joke: I already have a lot of complaints about vassal dice… hahaha… but that’s another topic!

Thanks in advance.

This is the code for rolling a die, from DiceButton.java:

final int rawRoll = ran.nextInt(nSides) + 1;

This is the code for selecting a random layer, from Embellishment.java:

final int val = GameModule.getGameModule().getRNG().nextInt(nValues) + 1;

Both call the nextInt() function of the random number generator with a limit value and add one. They’ll behave the same way if the limit value is the same.

I.e., you are sampling from the same distribution whether you have a die with six sides or a card with six layers.

Uckelman, thanks for your fast answer.

I see my knowledge about vassal is very down you explication and I can not understand it. Sorry. I am learning but I see I am in a basic level.

I try to solve the problem with a more basical solucion is use a layer with RANDOMIZED option selected. It works, my doubt is if it is not very balanced or it is ok and similar to the normal dice of vassal. When active the layer, the card show me a result, and aparently it is ok for me… what are your opinion about this solution???

Sorry, I don’t know what you’re trying to achieve. What do you mean by “my doubt is if it is not very balanced”?

Ummm… I see my vassal knowledg and my English language are at same level… hahaha…

Sorry I try to explain to you (thanks for your patient):
I want use a card with a layer RANDOMIZED as dice. It will be the result will be totally random or will have a bias??

That’s what I was explaining in my first reply: Rolling a die and selecting a random layer will be have in the same way.