Browse Source

Merge branch 'TikTakToeGame' into 'main'

Tik tak toe game into main

See merge request fdai7382/fertigjavagamelauncher!1
remotes/origin/textadventure
fdai7431 2 years ago
parent
commit
a15a6e0b3a
  1. 66
      JavaGamelauncher/.classpath
  2. 104
      JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/GamelauncherMain.java
  3. 0
      JavaGamelauncher/src/main/resources/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/Mouse3.gif
  4. 2
      README.md

66
JavaGamelauncher/.classpath

@ -1,33 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" output="target/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" output="target/test-classes" path="src/test/java">
<attributes>
<attribute name="test" value="true"/>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="module" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>
</classpath>
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" output="target/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" output="target/test-classes" path="src/test/java">
<attributes>
<attribute name="test" value="true"/>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="module" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>
</classpath>

104
JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/GamelauncherMain.java

@ -1,9 +1,16 @@
package de.hs_fulda.gruppenprojekt.JavaGamelauncher;
import java.awt.Color;
import java.awt.EventQueue;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
@ -61,7 +68,104 @@ public class GamelauncherMain extends JFrame {//class
setBackground(Color.DARK_GRAY);
contentPane.setForeground(Color.GRAY);
contentPane.setBackground(Color.DARK_GRAY);
JButton btnSnake = new JButton("Snake Starten");
JButton btnMouse = new JButton("Mouse Starten");
JButton btnTikTakToe = new JButton("TikTakToe Starten");
JButton btnTextadventure = new JButton("Textadventure Starten");
btnSnake.setBackground(Color.PINK);
btnMouse.setBackground(Color.PINK);
btnTikTakToe.setBackground(Color.PINK);
btnTextadventure.setBackground(Color.PINK);
btnSnake.setFont(new Font("Consolas", Font.PLAIN, 12));
btnMouse.setFont(new Font("Consolas", Font.PLAIN, 12));
btnTikTakToe.setFont(new Font("Consolas", Font.PLAIN, 12));
btnTextadventure.setFont(new Font("Consolas", Font.PLAIN, 12));
btnSnake.setBounds(10, 500, 300, 25);
btnTikTakToe.setBounds(630, 500, 300, 25);
btnMouse.setBounds(320, 500, 300, 25);
btnTextadventure.setBounds(940, 500, 300, 25);
contentPane.add(btnSnake);
contentPane.add(btnMouse);
contentPane.add(btnTikTakToe);
contentPane.add(btnTextadventure);
btnSnake.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// TODO Auto-generated method stub
//SnakeGame frameSnake = new SnakeGame();
//frameSnake.setVisible(true);
}
});
btnMouse.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// TODO Auto-generated method stub
MouseGame frameMouse = new MouseGame();
//frameMouse.setVisible(true);
}
});
btnTikTakToe.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// TODO Auto-generated method stub
//TikTakToeGame frameTikTakToe = new TikTakToeGame();
//frameTikTakToe.setVisible(true);
}
});
btnTextadventure.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
// TODO Auto-generated method stub
//TextadventureGame frameTextadventure = new TextadventureGame();
//frameTextadventure.setVisible(true);
}
});
JLabel AdSnake = new JLabel("");
JLabel AdMouse = new JLabel("");
JLabel AdTikTakToe = new JLabel("");
JLabel AdTextadventure = new JLabel("");
AdSnake.setForeground(Color.GRAY);
AdSnake.setBackground(Color.DARK_GRAY);
AdMouse.setForeground(Color.GRAY);
AdMouse.setBackground(Color.DARK_GRAY);
AdTikTakToe.setForeground(Color.GRAY);
AdTikTakToe.setBackground(Color.DARK_GRAY);
AdTextadventure.setBackground(Color.DARK_GRAY);
AdTextadventure.setForeground(Color.GRAY);
AdSnake.setBounds(10, 10, 300, 400);
AdMouse.setBounds(320, 10, 300, 400);
AdTikTakToe.setBounds(630, 10, 300, 400);
AdTextadventure.setBounds(940, 10, 300, 400);
AdSnake.setIcon(new ImageIcon(GamelauncherMain.class.getResource("/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/Snake3.gif")));
AdMouse.setIcon(new ImageIcon(GamelauncherMain.class.getResource("/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/Mouse3.gif")));
AdTikTakToe.setIcon(new ImageIcon(GamelauncherMain.class.getResource("/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/TikTakToe3.gif")));
AdTextadventure.setIcon(new ImageIcon(GamelauncherMain.class.getResource("/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/Textadventure3.gif")));
contentPane.add(AdSnake);
contentPane.add(AdMouse);
contentPane.add(AdTikTakToe);
contentPane.add(AdTextadventure);
}//end standardkonstruktor
}//end class

0
JavaGamelauncher/src/main/resources/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/maze.gif → JavaGamelauncher/src/main/resources/de/hs_fulda/gruppenprojekt/JavaGamelauncher/media/Mouse3.gif

Before

Width: 310  |  Height: 311  |  Size: 82 KiB

After

Width: 310  |  Height: 311  |  Size: 82 KiB

2
README.md

@ -15,7 +15,7 @@
### Bewertung:
- Noice Doice
- Noicer Doicer
#### Verlauf:

Loading…
Cancel
Save