High Rollers
There’s a lot of different pieces to build before Pocket Dice Rollers starts to resemble anything close to a game loop. Knowing that the snowboarding section is going to take a pretty serious amount of work, I thought I’d start with the getting the dice game up and running first.
Half the fun of playing dice is watching the dice move and roll! Even though it might end up causing headaches down the road, I decided to implement the dice as actual physical objects. Already it’s clear I’ll have a lot of edge cases to resolve, and there’s going to be lots of value tweaks to make sure the game is fast and snappy and responsive.
Because the dice exist in both 3D world space and 2D UI space, it was crucial to have a data representations for the dice. That way, dice values and textures and representations can be passed along as a group, instead of each system having it’s own way of interpreting the data. This should also make it really simple to include new dice types - whether that means numbers outside or 1 to 6, or wild numbers, or special actions. For this, I have a “DiceFaceData” Scriptable Object, which contains an int for the value, and a texture for the face.
The other dice interactions involved selecting and unselecting dice. For now I’m thinking you’ll tap on the dice you want to keep, putting them up in the UI. Determining the value is a matter of comparing the normals of each face. Whichever face is the most “up” is set as the face.
Pressing the dice in the UI will place it back into the board. To make sure I didn’t place dice on top of one another, I have a really simple sphere cast look over the grid. It adds “valid” positions to a list, then picks a random one. This makes it feel a little more organic, rather than filling the first open slot every time.
A good start...but lots more to do!











