Skip to content

Commit

Permalink
Naming fixes
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
thehabbos007 committed Jan 20, 2019
2 parents 2e16efc + f2f0308 commit 8ff1c60
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
9 changes: 4 additions & 5 deletions src/main/java/Controller/GameController.java
@@ -1,6 +1,5 @@
package Controller;

import Model.Fields.PropertyField;
import Model.Game;
import Model.GameBoard;
import Model.Player;
Expand Down Expand Up @@ -32,12 +31,12 @@ public GameController(GameBoard board, GameView view){
this.diceController = new DiceController(this);
this.endTurnController = new EndTurnController(this);

initalizeGame();
initializeGame();
currentController = diceController;
testPlayTurn(game.getActivePlayer());
playTurn(game.getActivePlayer());
}

private void initalizeGame(){
private void initializeGame(){
// pga. abstrakt klasse, har vi polymorfi, og kan kalde "getantalspillere" for ethvert view
int playerAmount = this.view.getPlayerCount();
String[] playerNames = new String[playerAmount];
Expand All @@ -51,7 +50,7 @@ private void initalizeGame(){
this.view.resetBoard();
}

private void testPlayTurn(Player player){
private void playTurn(Player player){
Player activePlayer = player;
while (!this.game.isEnded()){
resetControllers();
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/Model/Game.java
Expand Up @@ -42,7 +42,8 @@ public Game(GameBoard gameboard, String[] playerNames){

createPlayers(playerNames);

dice = new DemoDice();
dice = new Dice();
// dice = new DemoDice();

activePlayer = players[0];

Expand Down

0 comments on commit 8ff1c60

Please sign in to comment.