Exception in thread “main” java.lang.ClassCastException: model.GameEngineCallbackImpl cannot be cast to model.ServerSideGameEngineCallback
at model.GameEngineImpl.calculateResult(GameEngineImpl.java:116)
at view.Client.main(Client.java:44)
added player: The Roller
Player: The Roller, intermediate result = Dice 1: 1, Dice 2: 3 .. Total: 4
Player: The Roller, intermediate result = Dice 1: 3, Dice 2: 1 .. Total: 4
Player: The Roller, intermediate result = Dice 1: 6, Dice 2: 4 .. Total: 10
Player: The Roller, intermediate result = Dice 1: 2, Dice 2: 2 .. Total: 4
Player: The Roller, intermediate result = Dice 1: 4, Dice 2: 4 .. Total: 8
Player: The Roller, final result = Dice 1: 6, Dice 2: 6 .. Total: 12
added player: The Loser
Player: The Loser, intermediate result = Dice 1: 4, Dice 2: 1 .. Total: 5
Player: The Loser, intermediate result = Dice 1: 4, Dice 2: 2 .. Total: 6
Player: The Loser, intermediate result = Dice 1: 4, Dice 2: 5 .. Total: 9
Player: The Loser, intermediate result = Dice 1: 6, Dice 2: 4 .. Total: 10
Player: The Loser, intermediate result = Dice 1: 5, Dice 2: 2 .. Total: 7
Player: The Loser, final result = Dice 1: 4, Dice 2: 1 .. Total: 5
The above screenshot shows that the output of DiceGame.