From 7af2b8d295bc46c214dd7d1133230ed3f83c7874 Mon Sep 17 00:00:00 2001 From: "s.eser" Date: Tue, 7 May 2024 10:47:05 +0200 Subject: [PATCH] Last fixes (Error Handling) --- bin/domain/Box.class | Bin 13154 -> 13154 bytes bin/domain/Dice.class | Bin 1028 -> 1028 bytes bin/domain/Hand.class | Bin 2926 -> 2926 bytes bin/domain/Player.class | Bin 705 -> 705 bytes bin/facade/YahtzeeGame.class | Bin 11629 -> 11707 bytes bin/ui/TUI$1.class | Bin 373 -> 373 bytes bin/ui/TUI.class | Bin 5825 -> 5987 bytes src/facade/YahtzeeGame.java | 15 ++++++++------- src/ui/TUI.java | 20 +++++++++++++++----- 9 files changed, 23 insertions(+), 12 deletions(-) diff --git a/bin/domain/Box.class b/bin/domain/Box.class index 56c84e3a091564e356f356daeabcb93a5ee73b45..6cdd89b64d62ac63162bb715ab0f3bc93c1d70c8 100644 GIT binary patch delta 17 ZcmaEq_9%_x)W2Q(7#J8FH*!Q70{~D72VejI delta 17 ZcmaEq_9%_x)W2Q(7#J9AH*!Q70{~C;2V4LE diff --git a/bin/domain/Dice.class b/bin/domain/Dice.class index 596a7edc5aa1ff4673106d85751fef860b79377e..e07cc5a12acfa06f59c18bd295e82413779cf7bd 100644 GIT binary patch delta 17 YcmZqSXyM>E^>5cc1_lPljU0cN0XkU*S^xk5 delta 17 YcmZqSXyM>E^>5cc1_lP(jU0cN0XjtnRsaA1 diff --git a/bin/domain/Hand.class b/bin/domain/Hand.class index 986e04a5714b5814169d9f3e0a42351c33eaf03a..e8f03e99396fc3b41b43620fccddc69b169261a7 100644 GIT binary patch delta 17 ZcmaDS_D+oB)W2Q(7#J8FH*%zL0{}=F2D|_O delta 17 ZcmaDS_D+oB)W2Q(7#J9AH*%zL0{}<`2DktK diff --git a/bin/domain/Player.class b/bin/domain/Player.class index e97c8034e7633a7df7a7201685418f157a34f967..dc8b686b87f79694c69b1fb7ad659e3949d6b96b 100644 GIT binary patch delta 17 ZcmX@edXSal)W2Q(7#J8FH*)M`0sui628sXx delta 17 ZcmX@edXSal)W2Q(7#J9AH*)M`0suh-28I9t diff --git a/bin/facade/YahtzeeGame.class b/bin/facade/YahtzeeGame.class index 7a11635f00eb59bda1737d3b39b77f9130677309..85e7b0ee59f09434edb3a157cc542e26d1992b6e 100644 GIT binary patch literal 11707 zcmdT~3w%`7ng71~m^%y?2m=X*5DD)j1fmf^NWk(C2!;R#gFq37#NmTt0GzjTOHe4l@^1A+G;JfwY9oxsa9+2YrD0(^|iJZMfU%lduK8;8O8l=clWoy zz`f^w=bZ0+@9#V3%;O&&_#qL^=9onqQ*eE#E!6JRt_*c1FL0a%p-qlO22;_7(B@EW zBoytaU9xV2)0SlF-xUdMbK-Mj-BEmTBa`Jq5=_NSYJ7Jx9I2fhkB7E3g%inorhYBq zj%X;^9e0?<7aG&h)E?Uu3P)>~D&+OEFlj&{wApDFQZ~ifF)`>)RK&C-$IL)D(_7&E1>UIq~J8 zbrH2(tSuC24aLLq?E#HsXBd1AZR#s85Hm30BwYsDT z!BBfURG2-})p>o@Dkd}PQZ}RjVK9R*=xRxZ+BPl@b$PNHkl|IB63mTNeQ6L1PPJ(& zO#=m((Px}TLqBjg-KH62L(4)7bnn_7OcHYMwUZnUJVO!N@ONOAYfAm%u}EZIxXnoj z+SxYEp}9cY8Hz#z1Jbs*5TEq{I)fHiG#{&Yau={or_(^D!610Hi^;VesP2Ren|<71 z(#Lc)WQnCQnshpxI6OdBZn9}1EoK^4>4~ln&LBvbA9oz##-l+dF14vyCYGSPDb}{p zX>W|?4Qa7ynG7k;8!~%Sukkhtt`#;drwRxl0z@tv@Hwoqv4AO5wfbqbXebtiAFiRb z7M+_DMqGv1bRLBOch2t)MG}o2(OBG>8%iiE$r46dd#i+uHk;0&(XhmJQ5;-0)SZk8 zZyA!r-PF)dn;e2k!nq`v{CUGjV%T(9-OI5;AbQF zIGaO}?oiT!x|eh%!?CC`orFzE>c&FrVq1YVZ8>vdTcN%!w9O)b1D@dkYSRV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ho`K(aD46+IoU^M|;4_qPTUIfC8l+&>C+G^E z$Ms}dSJ4IBfL6fzCiU`n>S|ZyR6MGML^RdptB{-aOHos3LJbpsSd$jXi zvgD&uKDK)ws%KMn&)V#srh%UMs#(etCYIKC&509B%Lkw#uUR%x_Ta`5nq%<<{O3vD z<_GUUKg3svO3;lTmgR4Wr~^`$vyd@*LoW{f%cu77f}JZ(XdF6mE0`%l3^&8Ujzl^?b;Dm4g4d*PTf6=nku&hav*hb zO@(o;P*Z{Ue~=fu=TS8-!~kST4n*?8X)Z+0tRy8on0s2K4%7J8`0eFya4Y;gh51GN zp7D1ymtVp!m!79p{71!&dvew4+bgwt7ZE{3cK76J1f8ll%sROW%gGh4Ja}mV8SjTQ z z8=cH=(PDm^PUCkJPwolNQje!F%~p1gOHRxZyLZpaaZq@e=DIdzf|o|R8Cpd3Ot*o4 zQPbS1I(Ezrc=GA$*s#2ODvk{Qasy09-VJ!7N1Ym~%c|eilpo|K!jF0ULqnJ3!}x9L z5wc-<#rQGs7)_%}O{XdNo~cO+_74!}dL#$v1YWL;%Ek{pR;V-0;W%&>;4};*DIRc=eerAK|R~mb0c?xOSwmn@@C#b GW&Z$(?x|}4 diff --git a/bin/ui/TUI$1.class b/bin/ui/TUI$1.class index 33b5c280cd9a188392f933926e4cb286068b17a4..ea68ac52978a0eac518f5e597ba324e912b485c7 100644 GIT binary patch delta 23 fcmey$^p%O@)W2Q(7#J8FH*)APGKx+%XS4$Va0dr} delta 23 fcmey$^p%O@)W2Q(7#J9AH*)APGKx$#XS4$VZ`KET diff --git a/bin/ui/TUI.class b/bin/ui/TUI.class index 2043ee4666d1eec95ddccd3ec106a0eba2373bb2..cf65bfda79cf2f9ff259249ac9275a28300c5f16 100644 GIT binary patch delta 3108 zcmZ8j33yc175>kAlbOkzmxT#K7{W5_*~7jJBoYdQ$b`fsl%*()$;$%6OqiL3hHa{V zAgG|vf{C)kYEvq{o-Irl98Irp6N z-hD6UUCLL^-snCBpqNUID(_0wR@_Oj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{ - - } + private int playerCount; + private ArrayList players = new ArrayList<>(); + private String savedGamemode; public void setPlayercount(int playerCount) { this.playerCount = playerCount; } + public int getPlayercount(){ + return this.playerCount; + + } + public void setPlayerNames(String... names) { for (int i = 0; i < this.playerCount; i++) { diff --git a/src/ui/TUI.java b/src/ui/TUI.java index ecddf82..797ebfa 100644 --- a/src/ui/TUI.java +++ b/src/ui/TUI.java @@ -10,6 +10,7 @@ public class TUI { public static void main(String[] args) throws IOException { String choice = ""; + boolean notFound = false; Scanner sc = new Scanner(System.in); System.out.println("\nYahtzee Star Wars Special!"); @@ -19,6 +20,7 @@ public class TUI { try { YahtzeeGame game = new YahtzeeGame() { }; + notFound = false; System.out.println("\nMain menu:"); System.out.println(">Play"); System.out.println(">Highscores"); @@ -30,12 +32,20 @@ public class TUI { System.out.println("\nChoose your gamemode:"); System.out.println(">Normal"); System.out.println(">Special8"); - System.out.println("\n" + game.showHighscores(sc.nextLine())); + choice = sc.nextLine(); + if(choice.equalsIgnoreCase("Special8")) + game.setGamemode("Special8"); + else + game.setGamemode("Normal"); + System.out.println("\n" + game.showHighscores(choice)); } catch (FileNotFoundException e) { System.out.println("\nHighscore file not found!\n"); + notFound = true; } + System.out.println("\n>Return"); - System.out.println(">Delete"); + if(!notFound) + System.out.println(">Delete"); choice = sc.nextLine(); if (choice.equalsIgnoreCase("Return")) { } @@ -69,9 +79,9 @@ public class TUI { System.out.println("\nType in the player names, lock in each name with Enter: "); System.out.println(">ex. Lucas [Enter] William [Enter] Lena [Enter]"); - String playerNames[] = new String[game.playerCount]; + String playerNames[] = new String[game.getPlayercount()]; - for (int i = 0; i < game.playerCount; i++) { + for (int i = 0; i < game.getPlayercount(); i++) { playerNames[i] = sc.nextLine(); } @@ -79,7 +89,7 @@ public class TUI { while (!game.gameOverAll()) { - for (int i = 0; i < game.playerCount; i++) { + for (int i = 0; i < game.getPlayercount(); i++) { if (game.gameOver(i)) continue;