# Simple Dice

• Sharebar

A while ago, my PhD supervisor Professor Nason was watching me using VRMath2 Editor. He saw that I could create a cube easily by clicking on the cube icon in the Shapebar, and I could apply a texture on the cube easily by clicking on the cube (select it) and then click on an image texture in the Texture Chooser in Property Inspector Window. However, when he asked me to create a dice, I could not do it quickly because an image texture will be applied to all the six faces of the built-in cube.

There are a couple of ways to create a dice. A basic one is to create 6 faces and apply an image texture on each of the 6 faces.

In VRMath2 Editor, there is a 2D primitive object called RECTANGLE, which will create a 2 x 2 square (a square is a rectangle) in the 3D space. Then I can apply an image texture by using the SETIT or SETIMAGETEXTURE command, or simply click on one image texture in the Texture Chooser (texture set 10, see the image below).

Below is a simple dice in 3D space, you can rotate it to check on the six faces. And by the way, do you notice how the six faces of the dice are arranged? There is a simple rule, or convention maybe, for the dice. For example, you probably cannot find a dice that has one and six be adjacent. Why? Leave me a comment if you know.

 Here are some quizzes about dice: 1. If you rotate a dice, the maximum number of faces you can see will be 3. Can you see 1, 3 and 5? 2. What about 2, 3 and 4? 3. Make a list of all the 3-face combinations you can see in this simple dice (you can check with this virtual dice after you have made the list). 4. Do you think the arrangement of numbers on the six faces are the same for all dice? 5. If you change the arrangement of the numbers, will you change the probability of each number being rolled?

And of course you can write a Logo program to create this simple dice. I have the following example program for you to check, see if you can follow my thinking and do your mental rotations and movements.

Below I also include a video to show how I create this simple dice in VRMath2 Editor.