- Added documentation to controllers

tags : #story[1245]
This commit is contained in:
Alistair McIntyre
2017-09-12 16:54:40 +12:00
parent 9dad88e56a
commit 7e9e96c091
13 changed files with 82 additions and 120 deletions
@@ -3,11 +3,9 @@ package seng302.visualiser.controllers.cells;
import javafx.fxml.FXML;
import javafx.scene.Group;
import javafx.scene.control.Label;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.GridPane;
import javafx.scene.layout.Pane;
import javafx.scene.paint.Color;
import seng302.utilities.Sounds;
import seng302.visualiser.fxObjects.assets_3D.BoatMeshType;
import seng302.visualiser.fxObjects.assets_3D.BoatModel;
import seng302.visualiser.fxObjects.assets_3D.ModelFactory;
@@ -34,12 +32,13 @@ public class PlayerCell {
}
public void initialize() {
// Set Player Name
playerName.setText(name);
// Add Rotating Boat to Player Cell with players color on it.
Group group = new Group();
boatPane.getChildren().add(group);
BoatModel bo = ModelFactory.boatIconView(BoatMeshType.DINGHY, this.boatColor);
group.getChildren().add(bo.getAssets());
}
public Integer getPlayerId() {
@@ -53,8 +52,4 @@ public class PlayerCell {
public Color getBoatColor() {
return boatColor;
}
public void playButtonHoverSound(MouseEvent mouseEvent) {
Sounds.playHoverSound();
}
}
}