diff --git a/src/main/java/MenuPanel.java b/src/main/java/MenuPanel.java index c685056..f8fdf9c 100644 --- a/src/main/java/MenuPanel.java +++ b/src/main/java/MenuPanel.java @@ -1,3 +1,4 @@ +import BattleShip.BShip; import PingPong.GamePanel; @@ -36,13 +37,16 @@ public class MenuPanel extends JPanel { public void keyPressed(KeyEvent e) { if (e.getKeyCode() == KeyEvent.VK_1) { - new GameFrame(); - + new PingPong.GamePanel(); } + if (e.getKeyCode() == KeyEvent.VK_2) { + BShip game = new BShip(); + game.startGame(); + } + if (e.getKeyCode() == KeyEvent.VK_3) { + new Snake.Game(); -} - } - - private class GameFrame { + } + } } } \ No newline at end of file diff --git a/target/classes/MenuPanel$AL.class b/target/classes/MenuPanel$AL.class index 7046c06..d12278c 100644 Binary files a/target/classes/MenuPanel$AL.class and b/target/classes/MenuPanel$AL.class differ diff --git a/target/classes/MenuPanel$GameFrame.class b/target/classes/MenuPanel$GameFrame.class deleted file mode 100644 index a8279a0..0000000 Binary files a/target/classes/MenuPanel$GameFrame.class and /dev/null differ diff --git a/target/classes/MenuPanel.class b/target/classes/MenuPanel.class index 2fbc45a..6d15d8a 100644 Binary files a/target/classes/MenuPanel.class and b/target/classes/MenuPanel.class differ