From 95c7637af0de76fc0136c01be63a27f262a55ba5 Mon Sep 17 00:00:00 2001 From: EpicKnarvik97 Date: Fri, 14 Feb 2020 14:48:29 +0100 Subject: [PATCH] Cleanup --- .classpath | 11 - .gitignore | 5 +- .idea/artifacts/Four_In_A_Row.xml | 11 - .idea/libraries/junit_junit_5_0_SNAPSHOT.xml | 11 - .idea/misc.xml | 13 +- .idea/modules.xml | 11 +- .idea/workspace.xml | 1232 ++++------------- .project | 17 - .settings/org.eclipse.core.resources.prefs | 2 - .settings/org.eclipse.jdt.core.prefs | 12 - .settings/org.eclipse.jdt.ui.prefs | 3 - AUTHORS.md | 3 - Connect_4_Board_and_Box.jpg | Bin 25667 -> 0 bytes Connect_Four.gif | Bin 69313 -> 0 bytes LICENSE | 7 - META-INF/MANIFEST.MF | 2 +- README.md | 61 +- SEM-2.md | 220 --- out/artifacts/Four_In_A_Row/Four-In-A-Row.jar | Bin 31196 -> 0 bytes out/artifacts/Four_In_A_Row/Four-In-A-Row.zip | Bin 28388 -> 0 bytes out/production/Four-In-A-Row/Main$1.class | Bin 669 -> 0 bytes .../Four-In-A-Row/Main$Gamemode.class | Bin 1003 -> 0 bytes out/production/Four-In-A-Row/Main.class | Bin 2344 -> 0 bytes out/production/Four-In-A-Row/Plan.txt | 70 - .../Four-In-A-Row/board/Board.class | Bin 4183 -> 0 bytes out/production/Four-In-A-Row/board/Grid.class | Bin 3117 -> 0 bytes .../Four-In-A-Row/board/IBoard.class | Bin 439 -> 0 bytes .../Four-In-A-Row/board/IGrid.class | Bin 496 -> 0 bytes .../Four-In-A-Row/events/Block.class | Bin 763 -> 0 bytes .../Four-In-A-Row/events/Bomb.class | Bin 2110 -> 0 bytes .../Four-In-A-Row/events/FourInARow.class | Bin 461 -> 0 bytes .../Four-In-A-Row/events/IRandomEvent.class | Bin 192 -> 0 bytes .../Four-In-A-Row/events/IWinCondition.class | Bin 153 -> 0 bytes .../Four-In-A-Row/events/InARow.class | Bin 1115 -> 0 bytes .../Four-In-A-Row/events/RandomEvent.class | Bin 853 -> 0 bytes .../Four-In-A-Row/events/ThreeInARow.class | Bin 464 -> 0 bytes .../interfaces/FourInARowGUI$1.class | Bin 726 -> 0 bytes .../interfaces/FourInARowGUI.class | Bin 5695 -> 0 bytes .../Four-In-A-Row/interfaces/GUI.class | Bin 2857 -> 0 bytes .../interfaces/IGameInterface.class | Bin 198 -> 0 bytes .../interfaces/NInARowGUI$1.class | Bin 708 -> 0 bytes .../Four-In-A-Row/interfaces/NInARowGUI.class | Bin 7029 -> 0 bytes .../interfaces/TicTacToeGUI$1.class | Bin 712 -> 0 bytes .../interfaces/TicTacToeGUI.class | Bin 5925 -> 0 bytes .../Four-In-A-Row/objects/Empty.class | Bin 258 -> 0 bytes .../Four-In-A-Row/objects/GameObject.class | Bin 463 -> 0 bytes .../Four-In-A-Row/objects/Immovable.class | Bin 360 -> 0 bytes .../Four-In-A-Row/objects/Player.class | Bin 1140 -> 0 bytes .../Four-In-A-Row/objects/Token.class | Bin 552 -> 0 bytes out/test/Four-In-A-Row/FourInARowTest.class | Bin 1883 -> 0 bytes out/test/Four-In-A-Row/GridTest.class | Bin 1481 -> 0 bytes out/test/Four-In-A-Row/TicTacToeTest.class | Bin 2100 -> 0 bytes pom.xml | 108 ++ src/Main.java | 47 - src/Plan.txt | 70 - src/events/Block.java | 17 - src/events/FourInARow.java | 10 - src/events/IRandomEvent.java | 8 - src/events/ThreeInARow.java | 10 - src/inf101/v18/sem2/AppInfo.java | 35 - src/interfaces/GUI.java | 61 - src/interfaces/IGameInterface.java | 6 - src/interfaces/NInARowGUI.java | 181 --- .../java/inf101/v18/connectfour/Main.java | 87 ++ .../inf101/v18/connectfour}/board/Board.java | 140 +- .../inf101/v18/connectfour}/board/Grid.java | 66 +- .../inf101/v18/connectfour}/board/IBoard.java | 32 +- .../inf101/v18/connectfour}/board/IGrid.java | 34 +- .../v18/connectfour/board/IVerticalBoard.java | 55 + .../v18/connectfour/board/VerticalBoard.java | 118 ++ .../v18/connectfour/events/random/Block.java | 24 + .../v18/connectfour/events/random}/Bomb.java | 19 +- .../events/random/IRandomEvent.java | 32 + .../events/random}/RandomEvent.java | 30 +- .../events/winning/FourInARow.java | 13 + .../events/winning}/IWinCondition.java | 4 +- .../connectfour/events/winning}/InARow.java | 4 +- .../events/winning/ThreeInARow.java | 13 + .../v18/connectfour/interfaces/CLI.java | 147 ++ .../interfaces/ConnectFourCLI.java | 69 + .../interfaces/ConnectFourClassicGUI.java} | 90 +- .../interfaces/ConnectFourGUI.java | 247 ++++ .../connectfour/interfaces/ConnectGUI.java | 66 + .../v18/connectfour/interfaces/GUI.java | 54 + .../interfaces/IGameInterface.java | 47 + .../interfaces/IVerticalGameInterface.java | 26 + .../connectfour/interfaces/TicTacToeCLI.java | 67 + .../connectfour}/interfaces/TicTacToeGUI.java | 123 +- .../inf101/v18/connectfour/objects/Empty.java | 6 + .../v18/connectfour/objects/GameObject.java | 15 + .../v18/connectfour/objects/IGameObject.java | 16 + .../connectfour/objects/IPlayerObject.java | 10 + .../v18/connectfour}/objects/Immovable.java | 5 +- .../v18/connectfour}/objects/Player.java | 2 +- .../inf101/v18/connectfour/objects/Token.java | 24 + .../inf101/v18/connectfour/player/AI.java | 136 ++ .../inf101/v18/connectfour/player/IAI.java | 25 + .../v18/connectfour/player/IPlayer.java | 22 + .../inf101/v18/connectfour/player/Player.java | 47 + src/objects/Empty.java | 3 - src/objects/GameObject.java | 11 - src/objects/Token.java | 14 - .../java/inf101/v18/connectfour/AITest.java | 90 ++ .../inf101/v18/connectfour/BoardTest.java | 154 +++ .../v18/connectfour/FourInARowTest.java | 71 + .../java/inf101/v18/connectfour/GridTest.java | 90 ++ .../inf101/v18/connectfour/PlayerTest.java | 32 + .../v18/connectfour/RandomEventTest.java | 44 + .../v18/connectfour}/TicTacToeTest.java | 55 +- .../v18/connectfour/VerticalBoardTest.java | 142 ++ test/FourInARowTest.java | 63 - test/GridTest.java | 34 - 112 files changed, 2700 insertions(+), 2262 deletions(-) delete mode 100644 .classpath delete mode 100644 .idea/artifacts/Four_In_A_Row.xml delete mode 100644 .idea/libraries/junit_junit_5_0_SNAPSHOT.xml delete mode 100644 .project delete mode 100644 .settings/org.eclipse.core.resources.prefs delete mode 100644 .settings/org.eclipse.jdt.core.prefs delete mode 100644 .settings/org.eclipse.jdt.ui.prefs delete mode 100644 AUTHORS.md delete mode 100644 Connect_4_Board_and_Box.jpg delete mode 100644 Connect_Four.gif delete mode 100644 SEM-2.md delete mode 100644 out/artifacts/Four_In_A_Row/Four-In-A-Row.jar delete mode 100644 out/artifacts/Four_In_A_Row/Four-In-A-Row.zip delete mode 100644 out/production/Four-In-A-Row/Main$1.class delete mode 100644 out/production/Four-In-A-Row/Main$Gamemode.class delete mode 100644 out/production/Four-In-A-Row/Main.class delete mode 100644 out/production/Four-In-A-Row/Plan.txt delete mode 100644 out/production/Four-In-A-Row/board/Board.class delete mode 100644 out/production/Four-In-A-Row/board/Grid.class delete mode 100644 out/production/Four-In-A-Row/board/IBoard.class delete mode 100644 out/production/Four-In-A-Row/board/IGrid.class delete mode 100644 out/production/Four-In-A-Row/events/Block.class delete mode 100644 out/production/Four-In-A-Row/events/Bomb.class delete mode 100644 out/production/Four-In-A-Row/events/FourInARow.class delete mode 100644 out/production/Four-In-A-Row/events/IRandomEvent.class delete mode 100644 out/production/Four-In-A-Row/events/IWinCondition.class delete mode 100644 out/production/Four-In-A-Row/events/InARow.class delete mode 100644 out/production/Four-In-A-Row/events/RandomEvent.class delete mode 100644 out/production/Four-In-A-Row/events/ThreeInARow.class delete mode 100644 out/production/Four-In-A-Row/interfaces/FourInARowGUI$1.class delete mode 100644 out/production/Four-In-A-Row/interfaces/FourInARowGUI.class delete mode 100644 out/production/Four-In-A-Row/interfaces/GUI.class delete mode 100644 out/production/Four-In-A-Row/interfaces/IGameInterface.class delete mode 100644 out/production/Four-In-A-Row/interfaces/NInARowGUI$1.class delete mode 100644 out/production/Four-In-A-Row/interfaces/NInARowGUI.class delete mode 100644 out/production/Four-In-A-Row/interfaces/TicTacToeGUI$1.class delete mode 100644 out/production/Four-In-A-Row/interfaces/TicTacToeGUI.class delete mode 100644 out/production/Four-In-A-Row/objects/Empty.class delete mode 100644 out/production/Four-In-A-Row/objects/GameObject.class delete mode 100644 out/production/Four-In-A-Row/objects/Immovable.class delete mode 100644 out/production/Four-In-A-Row/objects/Player.class delete mode 100644 out/production/Four-In-A-Row/objects/Token.class delete mode 100644 out/test/Four-In-A-Row/FourInARowTest.class delete mode 100644 out/test/Four-In-A-Row/GridTest.class delete mode 100644 out/test/Four-In-A-Row/TicTacToeTest.class create mode 100644 pom.xml delete mode 100644 src/Main.java delete mode 100644 src/Plan.txt delete mode 100644 src/events/Block.java delete mode 100644 src/events/FourInARow.java delete mode 100644 src/events/IRandomEvent.java delete mode 100644 src/events/ThreeInARow.java delete mode 100644 src/inf101/v18/sem2/AppInfo.java delete mode 100644 src/interfaces/GUI.java delete mode 100644 src/interfaces/IGameInterface.java delete mode 100644 src/interfaces/NInARowGUI.java create mode 100644 src/main/java/inf101/v18/connectfour/Main.java rename src/{ => main/java/inf101/v18/connectfour}/board/Board.java (53%) rename src/{ => main/java/inf101/v18/connectfour}/board/Grid.java (61%) rename src/{ => main/java/inf101/v18/connectfour}/board/IBoard.java (56%) rename src/{ => main/java/inf101/v18/connectfour}/board/IGrid.java (59%) create mode 100644 src/main/java/inf101/v18/connectfour/board/IVerticalBoard.java create mode 100644 src/main/java/inf101/v18/connectfour/board/VerticalBoard.java create mode 100644 src/main/java/inf101/v18/connectfour/events/random/Block.java rename src/{events => main/java/inf101/v18/connectfour/events/random}/Bomb.java (76%) create mode 100644 src/main/java/inf101/v18/connectfour/events/random/IRandomEvent.java rename src/{events => main/java/inf101/v18/connectfour/events/random}/RandomEvent.java (52%) create mode 100644 src/main/java/inf101/v18/connectfour/events/winning/FourInARow.java rename src/{events => main/java/inf101/v18/connectfour/events/winning}/IWinCondition.java (82%) rename src/{events => main/java/inf101/v18/connectfour/events/winning}/InARow.java (95%) create mode 100644 src/main/java/inf101/v18/connectfour/events/winning/ThreeInARow.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/CLI.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/ConnectFourCLI.java rename src/{interfaces/FourInARowGUI.java => main/java/inf101/v18/connectfour/interfaces/ConnectFourClassicGUI.java} (58%) create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/ConnectFourGUI.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/ConnectGUI.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/GUI.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/IGameInterface.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/IVerticalGameInterface.java create mode 100644 src/main/java/inf101/v18/connectfour/interfaces/TicTacToeCLI.java rename src/{ => main/java/inf101/v18/connectfour}/interfaces/TicTacToeGUI.java (56%) create mode 100644 src/main/java/inf101/v18/connectfour/objects/Empty.java create mode 100644 src/main/java/inf101/v18/connectfour/objects/GameObject.java create mode 100644 src/main/java/inf101/v18/connectfour/objects/IGameObject.java create mode 100644 src/main/java/inf101/v18/connectfour/objects/IPlayerObject.java rename src/{ => main/java/inf101/v18/connectfour}/objects/Immovable.java (51%) rename src/{ => main/java/inf101/v18/connectfour}/objects/Player.java (95%) create mode 100644 src/main/java/inf101/v18/connectfour/objects/Token.java create mode 100644 src/main/java/inf101/v18/connectfour/player/AI.java create mode 100644 src/main/java/inf101/v18/connectfour/player/IAI.java create mode 100644 src/main/java/inf101/v18/connectfour/player/IPlayer.java create mode 100644 src/main/java/inf101/v18/connectfour/player/Player.java delete mode 100644 src/objects/Empty.java delete mode 100644 src/objects/GameObject.java delete mode 100644 src/objects/Token.java create mode 100644 src/test/java/inf101/v18/connectfour/AITest.java create mode 100644 src/test/java/inf101/v18/connectfour/BoardTest.java create mode 100644 src/test/java/inf101/v18/connectfour/FourInARowTest.java create mode 100644 src/test/java/inf101/v18/connectfour/GridTest.java create mode 100644 src/test/java/inf101/v18/connectfour/PlayerTest.java create mode 100644 src/test/java/inf101/v18/connectfour/RandomEventTest.java rename {test => src/test/java/inf101/v18/connectfour}/TicTacToeTest.java (58%) create mode 100644 src/test/java/inf101/v18/connectfour/VerticalBoardTest.java delete mode 100644 test/FourInARowTest.java delete mode 100644 test/GridTest.java diff --git a/.classpath b/.classpath deleted file mode 100644 index 2a680ed..0000000 --- a/.classpath +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/.gitignore b/.gitignore index ae3c172..7577d67 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,4 @@ -/bin/ +out +target +.idea +.settings \ No newline at end of file diff --git a/.idea/artifacts/Four_In_A_Row.xml b/.idea/artifacts/Four_In_A_Row.xml deleted file mode 100644 index f273109..0000000 --- a/.idea/artifacts/Four_In_A_Row.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - $PROJECT_DIR$/out/artifacts/Four_In_A_Row - - - - - - - - \ No newline at end of file diff --git a/.idea/libraries/junit_junit_5_0_SNAPSHOT.xml b/.idea/libraries/junit_junit_5_0_SNAPSHOT.xml deleted file mode 100644 index 2eed548..0000000 --- a/.idea/libraries/junit_junit_5_0_SNAPSHOT.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml index 34a6d81..dd6abf3 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,10 +1,11 @@ -<<<<<<< HEAD - - + + -======= - ->>>>>>> e31307eb015ce4a67ca5cbf51755ecb654024a62 + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml index a0b0638..e312d08 100644 --- a/.idea/modules.xml +++ b/.idea/modules.xml @@ -2,14 +2,7 @@ -<<<<<<< HEAD - + - -======= - - - - ->>>>>>> e31307eb015ce4a67ca5cbf51755ecb654024a62 + \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 3685bfb..d360bf6 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -6,163 +6,119 @@ - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - four - checkWin - - - - - - - - - - + @@ -261,115 +154,50 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -