From 8c2e4a7d594028207f0bbf48890710856445c2b8 Mon Sep 17 00:00:00 2001 From: Ida Massow Date: Thu, 9 Jun 2011 00:11:26 +0200 Subject: Man kann den Timer einstellen git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@391 72836036-5685-4462-b002-a69064685172 --- src/jrummikub/model/GameSettings.java | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) (limited to 'src/jrummikub/model') diff --git a/src/jrummikub/model/GameSettings.java b/src/jrummikub/model/GameSettings.java index 671b57c..42f76a6 100644 --- a/src/jrummikub/model/GameSettings.java +++ b/src/jrummikub/model/GameSettings.java @@ -23,6 +23,7 @@ public class GameSettings implements Serializable { private int highestValue; private int stoneSetNumber; private int numberOfStonesDealt; + private int time; private boolean noLimits; private HashSet stoneColors; @@ -36,9 +37,10 @@ public class GameSettings implements Serializable { highestValue = 13; stoneSetNumber = 2; numberOfStonesDealt = 14; + time = 60; noLimits = false; - stoneColors = new HashSet(Arrays.asList(BLACK, BLUE, ORANGE, - RED)); + stoneColors = new HashSet(Arrays.asList(BLACK, BLUE, + ORANGE, RED)); } /** @@ -54,7 +56,7 @@ public class GameSettings implements Serializable { * Sets the initial meld threshold * * @param value - * the value to set + * the value to set */ public void setInitialMeldThreshold(int value) { initialMeldThreshold = value; @@ -73,7 +75,7 @@ public class GameSettings implements Serializable { * Sets the points counted for a joker * * @param value - * the value to set + * the value to set */ public void setJokerPoints(int value) { jokerPoints = value; @@ -92,7 +94,7 @@ public class GameSettings implements Serializable { * Sets the number of jokers in game * * @param value - * how many jokers will be used + * how many jokers will be used */ public void setJokerNumber(int value) { jokerNumber = value; @@ -120,7 +122,7 @@ public class GameSettings implements Serializable { * Set the highest stone value in use * * @param highestValue - * highest stone value + * highest stone value */ public void setHighestValue(int highestValue) { this.highestValue = highestValue; @@ -139,12 +141,20 @@ public class GameSettings implements Serializable { * Set the number of sets of stones in use * * @param stoneSets - * sets of stones in use + * sets of stones in use */ public void setStoneSetNumber(int stoneSets) { this.stoneSetNumber = stoneSets; } + public int getTime() { + return time; + } + + public void setTime(int time) { + this.time = time; + } + /** * Use "No-Limits" rules * @@ -158,7 +168,7 @@ public class GameSettings implements Serializable { * Set whether "No-Limits" rules are used * * @param noLimits - * use no limit rules + * use no limit rules */ public void setNoLimits(boolean noLimits) { this.noLimits = noLimits; @@ -177,7 +187,7 @@ public class GameSettings implements Serializable { * Set stone colors used * * @param stoneColors - * used stone colors + * used stone colors */ public void setStoneColors(Set stoneColors) { this.stoneColors = new HashSet(stoneColors); @@ -196,7 +206,7 @@ public class GameSettings implements Serializable { * Set number of stones dealt at game start * * @param number - * how many Stones will be dealt initially + * how many Stones will be dealt initially */ public void setNumberOfStonesDealt(int number) { numberOfStonesDealt = number; -- cgit v1.2.3