File tree Expand file tree Collapse file tree
src/main/java/it/polimi/ingsw/client/gui Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -241,19 +241,24 @@ public GUIController getControllerFromName(String name) {
241241 */
242242 public void errorHandling (GameError error ) {
243243 switch (error .getError ()) {
244- case WORKERBLOCKED -> Platform .runLater (() -> {
245- errorDialog ("The worker you have selected is blocked, please choose another one!" );
246- selectWorker ();
247- });
248- case INVALIDINPUT -> Platform .runLater (() -> {
249- errorDialog ("Invalid input, please try again!" );
250- });
251- case CELLOCCUPIED -> Platform .runLater (() -> {
252- errorDialog ("Cell already occupied!" );
253- });
254- default -> Platform .runLater (() -> {
255- errorDialog ("Generic Error!" );
256- });
244+ case WORKERBLOCKED ->
245+ Platform .runLater (() -> {
246+ errorDialog ("The worker you have selected is blocked, please choose another one!" );
247+ selectWorker ();
248+ });
249+ case INVALIDINPUT ->
250+ Platform .runLater (() -> {
251+ errorDialog ("Invalid input, please try again!" );
252+ });
253+ case CELLOCCUPIED ->
254+ Platform .runLater (() -> {
255+ errorDialog ("Cell already occupied!" );
256+ });
257+ default -> {
258+ Platform .runLater (() -> {
259+ errorDialog ("Generic Error!" );
260+ });
261+ }
257262 }
258263 }
259264
You can’t perform that action at this time.
0 commit comments