# Lottery Simulation help

Hello,

I just got a full time job as a game programmer in Unity,but suddenly my boss decided that i shall do it in Unreal Engine 4.
I never even touched Unreal Engine 4 but i had lots of experience with UDK , but as i can see a lot has changed.
I have been asked to make a lottery simulation using cubes
I chose the first person shooter blueprint and removed the gun and the shooting ability(correct me if i’m wrong).
More game details :
1.A cube has six sides, we can attach to any side a picture or a number which can be seen outside the cube
2.In our case we hide one of the cube’s side so you can see the images of five sides and one side is concealed
3.We create a three-dimensional room
4.Assume for simplicity that the sides of the cube numbers from 1-6 without repetitions
5.Early in the game,the dices fall from the sky physically until they fall to the floor.
6.When they reach the ground they will work out a matrix structure with the hidden side facing the ground
7.We look at the cubes we notice the di corners with three walls visible (the rest walls are hidden by other blocks)
8.Possible to move in three dimensions in all directions and see the matrix blocks on each side except the bottom (floor)

There is more for it,but i feel like i’m asking for too much.
If anyone could take just 10 minutes of off his time and just try and simulate this one,and maybe upload it to Youtube, or just give me tips on where to begin i would be so grateful.
This is my first day of work and i have about 2-3 days before he would like to see progress.
I created the cubes using Blender,so don’t worry about that.
Again,thank you so much.

Just an idea…but read up on some programming of throwing dice I’m sure alot of the math would be very similar.

This video tutorial covers alot of what you want to do, except using colored cows instead of dice!

Hey,
thanks for your quick replies. It really did help, i am now able to successfully spawn my cubes, but i’m now stuck with a different problem.
How do i add text to my cube,from the engine? I want to have on each face of the cube numbers 1 to 6 without any repetitions and i want it to be random on each cube.
Thanks for you help.
Oh and BladeandChalice i couldn’t find any programming of throwing dice online,if you know where i can find it i would appreciate if you could redirect me to it.

You create an Actor and add 6 Text Render Compontents, Place them the way you want and then you access them from the actor blueprint and set the numbers with the Random Integer in Range function.

Click here and check includes most of what you wish to accomplish, with the exception of utilising colored calves in whilst rolls.