summaryrefslogtreecommitdiffstats
path: root/src/jrummikub/JRummikub.java
blob: 9c22dc6aaaf1221f54eab920e3143cc50f981078 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package jrummikub;

import java.awt.Color;

import javax.swing.UIManager;

import jrummikub.control.GameControl;
import jrummikub.model.GameSettings;
import jrummikub.model.PlayerSettings;
import jrummikub.view.impl.View;

/**
 * The main class
 */
public class JRummikub {

	/**
	 * The main method
	 * 
	 * @param args
	 *          command line arguments
	 */
	public static void main(String[] args) {
		String nativeLF = UIManager.getSystemLookAndFeelClassName();

		try {
			UIManager.setLookAndFeel(nativeLF);
		} catch (Exception e) {
		}

		GameSettings gameSettings = new GameSettings();
		gameSettings.getPlayerList().add(new PlayerSettings("Ida", Color.RED));
		gameSettings.getPlayerList().add(
				new PlayerSettings("Matthias", Color.YELLOW));
		gameSettings.getPlayerList().add(new PlayerSettings("Jannis", Color.GREEN));
		gameSettings.getPlayerList().add(new PlayerSettings("Bennet", Color.BLACK));

		View view = new View();

		GameControl gameControl = new GameControl(gameSettings, view);
		gameControl.startGame();

	}

}