Devlog3. Dice Rolling and Board Movement
In Dice & Domination, players roll a physical-looking dice and move across a looping board made of tiles.
System Structure
- DiceSide.cs : Check which side of the dice is facing up after rolling.
- DiceManager.cs : Rolls the dice, detects the final value, and synchronizes the result over the network.
- TilesRoute.cs: Holds the ordered list of tiles that players move across.
- BoardPlayer.cs: Moves the player according to dice results and triggers landing events.
Implementation
DiceSide:
The DiceSide class detects which face of the dice is touching the ground after it finishes rolling. Each side collider checks if it is resting on a surface tagged as "BattleGround". If a side touches the ground, it updates its onGround status and used later to determine which number was rolled.
As part of the setup, each dice side's Side Value matches the number of dots shown, and the opposite sides are matched logically (1 is opposite 6, 2 is opposite 5, 3 is opposite 4).

Six colliders on the dice surface
Set Side Value "1" on the surface 6
DiceManager:
This class handles rolling the dice and syncing the roll across all players in a multiplayer session. When the player clicks the "Roll Dice" button, it triggers a roll only if the dice hasn’t already been thrown. It applies a random torque to the dice, making it spin physically. It also sends the torque values to other players using Photon RPC, so all players see the same roll. ‘
In Update() , it monitors when the dice stops moving using Rigidbody.IsSleeping(). When the dice has landed, it freezes its physics, checks each dice side and finds which number is facing up

TilesRoute:
The TilesRoute class organizes the path players move along.It automatically gathers all child tiles into a list called childTileList.
BoardPlayer:
The BoardPlayer class controls each player’s movement across the board after rolling the dice. When a dice roll is completed, it listens to the OnDiceRolled event and starts moving.
In MoveOnBoard(), the player advances one tile at a time for each number rolled. In the while loop, it keeps track of the player's current tile index RoutePosition, and after each step, it updates the position based on the board’s tile list. If the player’s movement wraps around the board (meaning the player passes the start tile at index 0), the game detects this by comparing the previous tile index and the new one. When this happens, it rewards the player with extra money. The MoveToNextTile() method moves the player’s position toward the next tile.
After finishing the move, it checks which tile the player landed on and shows the tile information UI or triggers events like battles or purchasement.

Design Pattern
- Observer: DiceManager uses events like OnDiceRolled and OnDiceLanded to notify other systems when a dice roll finishes.
- Command: Dice rolling action like RollDice and ResetDice is encapsulated and triggered by player input
- Composite:Treats a group of tile GameObjects as a collection that the player can move across sequentially.
- Mediator: BoardPlayer communicates with the tile system (through TileVisualizer) without tightly binding those classes.
Gameplay Demonstration
Initial setup of dice rolling and route movement
Final effect of dice rolling and route movement
Dice & Domination
A high-stakes multiplayer strategy game with domination and combat
Status | In development |
Author | Angir |
Genre | Strategy |
Tags | 3D, Board Game, monopoly, Multiplayer, Top down shooter |
Languages | English |
More posts
- Devlog5. Turn Management1 day ago
- Devlog4. Board Game Data Structure3 days ago
- Devlog2. Programming Architecture29 days ago
- Devlog1. Game Design of Dice&Domination38 days ago
Leave a comment
Log in with itch.io to leave a comment.