mirror of
				https://athene2.informatik.unibw-muenchen.de/progproj/gruppen-ht24/Gruppe-02.git
				synced 2025-10-31 01:31:52 +01:00 
			
		
		
		
	fixed jailState
This commit is contained in:
		| @@ -11,6 +11,8 @@ import java.util.ArrayList; | |||||||
| import java.util.List; | import java.util.List; | ||||||
| import java.util.Random; | import java.util.Random; | ||||||
|  |  | ||||||
|  | import javax.swing.JInternalFrame; | ||||||
|  |  | ||||||
| import com.jme3.network.serializing.Serializable; | import com.jme3.network.serializing.Serializable; | ||||||
|  |  | ||||||
| import pp.monopoly.message.server.BuyPropertyRequest; | import pp.monopoly.message.server.BuyPropertyRequest; | ||||||
| @@ -336,7 +338,6 @@ public class Player implements FieldVisitor<Void>{ | |||||||
|  |  | ||||||
|     @Override |     @Override | ||||||
|     public Void visit(GulagField field) { |     public Void visit(GulagField field) { | ||||||
|         state = new JailState(); |  | ||||||
|         return null; |         return null; | ||||||
|     } |     } | ||||||
|  |  | ||||||
| @@ -358,6 +359,7 @@ public class Player implements FieldVisitor<Void>{ | |||||||
|     @Override |     @Override | ||||||
|     public Void visit(WacheField field) { |     public Void visit(WacheField field) { | ||||||
|         setPosition(10); |         setPosition(10); | ||||||
|  |         jail(); | ||||||
|         return null; |         return null; | ||||||
|     } |     } | ||||||
|  |  | ||||||
| @@ -386,6 +388,10 @@ public class Player implements FieldVisitor<Void>{ | |||||||
|         return properties; |         return properties; | ||||||
|     } |     } | ||||||
|  |  | ||||||
|  |     public void jail() { | ||||||
|  |         state = new JailState(); | ||||||
|  |     } | ||||||
|  |  | ||||||
|     /** |     /** | ||||||
|      * Return the number of Properties of the speciefied fild type |      * Return the number of Properties of the speciefied fild type | ||||||
|      * @param field the type of field to search for |      * @param field the type of field to search for | ||||||
|   | |||||||
| @@ -243,10 +243,12 @@ public class DeckHelper{ | |||||||
|      |      | ||||||
|         private void schimmelGulak(Player player) { |         private void schimmelGulak(Player player) { | ||||||
|             player.setPosition(10); |             player.setPosition(10); | ||||||
|  |             player.jail(); | ||||||
|         } |         } | ||||||
|      |      | ||||||
|         private void partynachtGulak(Player player) { |         private void partynachtGulak(Player player) { | ||||||
|             player.setPosition(10); |             player.setPosition(10); | ||||||
|  |             player.jail(); | ||||||
|         } |         } | ||||||
|      |      | ||||||
|         private void jahresabschlussantreten(Player player) { |         private void jahresabschlussantreten(Player player) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user