Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/CMakeLists.txt
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/CMakeLists.txt	(revision 10120)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/CMakeLists.txt	(revision 10121)
@@ -1,4 +1,5 @@
 SET_SOURCE_FILES(Mini4Dgame_SRC_FILES
   Mini4Dgame.cc
+  Mini4DgameAI.cc
   Mini4DgameCenterpoint.cc
 )
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.cc
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.cc	(revision 10120)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.cc	(revision 10121)
@@ -170,18 +170,3 @@
 
 
-    /**
-    @brief
-        Get the player.
-    @return
-        Returns a pointer to the player. If there is no player, NULL is returned.
-    */
-    //TODO: colors
-    PlayerInfo* Mini4Dgame::getPlayer(int color) const
-    {
-        return players[color].info_;
-    	//for(int i=0;i<NUMBEROFPLAYERS;i++)
-        	//if(color == this->mini4DgamePlayers[i].color)
-        		//return this->mini4DgamePlayers[i].info;
-    }
-
 }
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.h
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.h	(revision 10120)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4Dgame.h	(revision 10121)
@@ -57,5 +57,12 @@
 	};
 
-
+	struct Mini4DgameWinner
+	{
+		int winningRow[4];
+		int winningColumn[4];
+		int winningHeight[4];
+		int winningNumber[4];
+		mini4DgamePlayerColor::color color_;
+	};
     /**
     @brief
@@ -78,9 +85,5 @@
             	{ this->center_ = center; }
 
-//TODO: enum colors
-            PlayerInfo* getPlayer(int color) const; //!< Get the player with the specified color.
-
-
-            //bool isValidMove(Vector4* move, const Mini4DgameBoard* board);//!< Checks if the move is valid
+            void win(Mini4DgameWinner winner);
 
         protected:
@@ -91,9 +94,7 @@
             void cleanup(void); //!< Cleans up the Gametype by destroying the ball and the bats.
 
-          Mini4DgamePlayer players[2];
+            Mini4DgamePlayer players[2];
 
             WeakPtr<Mini4DgameCenterpoint> center_; //!< The playing field.
-
-            //TODO: Board is missing up to now
     };
 }
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.cc
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.cc	(revision 10121)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.cc	(revision 10121)
@@ -0,0 +1,126 @@
+/*
+ *   ORXONOX - the hottest 3D action shooter ever to exist
+ *                    > www.orxonox.net <
+ *
+ *
+ *   License notice:
+ *
+ *   This program is free software; you can redistribute it and/or
+ *   modify it under the terms of the GNU General Public License
+ *   as published by the Free Software Foundation; either version 2
+ *   of the License, or (at your option) any later version.
+ *
+ *   This program is distributed in the hope that it will be useful,
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *   GNU General Public License for more details.
+ *
+ *   You should have received a copy of the GNU General Public License
+ *   along with this program; if not, write to the Free Software
+ *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ *
+ *   Author:
+ *      Fabian 'x3n' Landau
+ *   Co-authors:
+ *      ...
+ *
+ */
+
+/**
+    @file Mini4DgameAI.cc
+    @brief Implementation of the Mini4DgameAI class.
+*/
+
+#include "Mini4DgameAI.h"
+
+#include "core/CoreIncludes.h"
+#include "core/config/ConfigValueIncludes.h"
+#include "core/command/Executor.h"
+#include "tools/Timer.h"
+
+#include <list>
+
+#include "worldentities/ControllableEntity.h"
+
+#include "Mini4DgameCenterpoint.h"
+
+namespace orxonox
+{
+    RegisterUnloadableClass(Mini4DgameAI);
+
+    //const static float MAX_REACTION_TIME = 0.4f;
+
+    /**
+    @brief
+        Constructor. Registers and initializes the object.
+    */
+    Mini4DgameAI::Mini4DgameAI(Context* context) : Controller(context)
+    {
+        RegisterObject(Mini4DgameAI);
+
+        this->setConfigValues();
+        this->center_ = 0;
+    }
+
+    /**
+    @brief
+        Destructor. Cleans up the list fo reaction timers.
+    */
+    Mini4DgameAI::~Mini4DgameAI()
+    {
+
+    }
+
+    Vector4 Mini4DgameAI::makeMove(float timeout)
+    {
+    	this->copyBoard();
+    	std::list<Vector4> possibleMoves = this->getPossibleMoves();
+
+    	//TODO: alphabeta ueber possibleMoves
+
+    	//when timeout
+    	Vector4 move = possibleMoves.front();
+    	return move;
+    }
+
+    void Mini4DgameAI::copyBoard()
+    {
+		for(int i=0;i<4;i++){
+			for(int j=0;j<4;j++){
+				for(int k=0;k<4;k++){
+					for(int l=0;l<4;l++){
+						this->board_[i][j][k][l]=this->center_->board[i][j][k][l];
+					}
+				}
+			}
+		}
+    }
+
+    std::list<Vector4> Mini4DgameAI::getPossibleMoves()
+    {
+    	std::list<Vector4> possibleMoves = new std::list<Vector4>;
+    	for(int i=0;i<4;i++){
+			for(int j=0;j<4;j++){
+				for(int k=0;k<4;k++){
+					for(int l=0;l<4;l++){
+						if (this->board_[i][j][k][l]==mini4DgamePlayerColor::none)
+							possibleMoves.push_back(Vector4(i,j,k,l));
+					}
+				}
+			}
+		}
+    	return possibleMoves;
+    }
+
+    /**
+    @brief
+        Is called each tick.
+        Implements the behavior of the PongAI (i.e. its intelligence).
+    @param dt
+        The time that has elapsed since the last tick.
+    */
+    void Mini4DgameAI::tick(float dt)
+    {
+
+    }
+}
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.h
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.h	(revision 10121)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameAI.h	(revision 10121)
@@ -0,0 +1,94 @@
+/*
+ *   ORXONOX - the hottest 3D action shooter ever to exist
+ *                    > www.orxonox.net <
+ *
+ *
+ *   License notice:
+ *
+ *   This program is free software; you can redistribute it and/or
+ *   modify it under the terms of the GNU General Public License
+ *   as published by the Free Software Foundation; either version 2
+ *   of the License, or (at your option) any later version.
+ *
+ *   This program is distributed in the hope that it will be useful,
+ *   but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *   GNU General Public License for more details.
+ *
+ *   You should have received a copy of the GNU General Public License
+ *   along with this program; if not, write to the Free Software
+ *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ *
+ *   Author:
+ *      Fabian 'x3n' Landau
+ *   Co-authors:
+ *      ...
+ *
+ */
+
+/**
+    @file Mini4DgameAI.h
+    @brief Declaration of the Mini4DgameAI class.
+*/
+
+#ifndef _Mini4DgameAI_H__
+#define _Mini4DgameAI_H__
+
+#include "mini4Dgame/Mini4DgamePrereqs.h"
+
+#include <list>
+
+#include "tools/interfaces/Tickable.h"
+
+#include "controllers/Controller.h"
+#include "Mini4DgameCenterpoint.h"
+#include "Mini4Dgame.h"
+
+namespace orxonox
+{
+
+    /**
+    @brief
+        The Mini4DgameAI is an artificial intelligence for the @ref orxonox::Mini4Dgame "Mini4Dgame" gametype.
+
+    @author
+        Oliver Richter
+    */
+    class _Mini4DgameExport Mini4DgameAI : public Controller, public Tickable
+    {
+        public:
+    		Mini4DgameAI(Context* context); //!< Constructor. Registers and initializes the object.
+            virtual ~Mini4DgameAI();
+
+            //void setConfigValues();
+
+            /**
+                @brief
+                    starts the AI to make a move. implements the intelligence of the AI
+                @param timeout
+                    The time the AI has to decide on a move. (Sets the strength of the AI)
+                @return move
+                	The move that the AI decided to make.
+            */
+            Vector4 Mini4DgameAI::makeMove(float timeout);
+
+
+            virtual void tick(float dt);
+
+            void setCenterpoint(Mini4DgameCenterpoint* center)
+                        	{ this->center_ = center; }
+
+        protected:
+
+            std::list<std::pair<Timer*, char> > reactionTimers_; //!< A list of reaction timers and the directions that take effect when their timer expires.
+            Mini4DgameCenterpoint* center_;
+
+        private:
+
+            std::list<Vector4> Mini4DgameAI::getPossibleMoves();
+            void Mini4DgameAI::copyBoard();
+            mini4DgamePlayerColor::color board_[4][4][4][4];
+    };
+}
+
+#endif /* _Mini4DgameAI_H__ */
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.cc
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.cc	(revision 10120)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.cc	(revision 10121)
@@ -122,6 +122,6 @@
     	{
     		this->board[(int)move.x][(int)move.y][(int)move.z][(int)move.w] = playerColor;
-    		mini4DgamePlayerColor::color winner = this->getWinner();
-    		if(winner != mini4DgamePlayerColor::none)
+    		Mini4DgameWinner winner = this->getWinner();
+    		if(winner.color_ != mini4DgamePlayerColor::none)
     		{
     			Mini4Dgame->win(winner);
@@ -130,6 +130,9 @@
     }
 
-    mini4DgamePlayerColor::color Mini4DgameCenterpoint::getWinner()
+    Mini4DgameWinner Mini4DgameCenterpoint::getWinner()
     {
+    	Mini4DgameWinner winner;
+		winner.color_ = mini4DgamePlayerColor::none;
+
     	//check diagonals rows-columns-height-numbers
 		for(int i=1; i<4; i++)
@@ -138,5 +141,14 @@
 				break;
 			if(i==3)
-				return this->board[0][0][0][0];
+			{
+				winner.color_ = this->board[0][0][0][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -145,5 +157,14 @@
 				break;
 			if(i==3)
-				return this->board[3][0][0][0];
+			{
+				winner.color_ = this->board[3][0][0][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = 3-x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -152,5 +173,14 @@
 				break;
 			if(i==3)
-				return this->board[0][3][0][0];
+			{
+				winner.color_ = this->board[0][3][0][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = x;
+					winner.winningColumn[x] = 3-x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -159,5 +189,14 @@
 				break;
 			if(i==3)
-				return this->board[0][0][3][0];
+			{
+				winner.color_ = this->board[0][0][3][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = 3-x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -166,5 +205,14 @@
 				break;
 			if(i==3)
-				return this->board[0][0][0][3];
+			{
+				winner.color_ = this->board[0][0][0][3];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = 3-x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -173,5 +221,14 @@
 				break;
 			if(i==3)
-				return this->board[3][3][0][0];
+			{
+				winner.color_ = this->board[3][3][0][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = 3-x;
+					winner.winningColumn[x] = 3-x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -180,5 +237,14 @@
 				break;
 			if(i==3)
-				return this->board[3][0][3][0];
+			{
+				winner.color_ = this->board[3][0][3][0];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = 3-x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = 3-x;
+					winner.winningNumber[x] = x;
+				}
+				return winner;
+			}
 		}
 		for(int i=1; i<4; i++)
@@ -187,5 +253,14 @@
 				break;
 			if(i==3)
-				return this->board[3][0][0][3];
+			{
+				winner.color_ = this->board[3][0][0][3];
+				for(int x=0; x<4; x++){
+					winner.winningRow[x] = 3-x;
+					winner.winningColumn[x] = x;
+					winner.winningHeight[x] = x;
+					winner.winningNumber[x] = 3-x;
+				}
+				return winner;
+			}
 		}
 
@@ -198,5 +273,14 @@
 					break;
 				if(i==3)
-					return this->board[0][0][0][l];
+				{
+					winner.color_ = this->board[0][0][0][l];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = l;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -205,5 +289,14 @@
 					break;
 				if(i==3)
-					return this->board[3][0][0][l];
+				{
+					winner.color_ = this->board[3][0][0][l];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = 3-x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = l;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -212,5 +305,14 @@
 					break;
 				if(i==3)
-					return this->board[0][3][0][l];
+				{
+					winner.color_ = this->board[0][3][0][l];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = 3-x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = l;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -219,5 +321,14 @@
 					break;
 				if(i==3)
-					return this->board[0][0][3][l];
+				{
+					winner.color_ = this->board[0][0][3][l];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = 3-x;
+						winner.winningNumber[x] = l;
+					}
+					return winner;
+				}
 			}
 		}
@@ -231,5 +342,14 @@
 					break;
 				if(i==3)
-					return this->board[0][0][l][0];
+				{
+					winner.color_ = this->board[0][0][l][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = l;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -238,5 +358,14 @@
 					break;
 				if(i==3)
-					return this->board[3][0][l][0];
+				{
+					winner.color_ = this->board[3][0][l][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = 3-x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = l;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -245,5 +374,14 @@
 					break;
 				if(i==3)
-					return this->board[0][3][l][0];
+				{
+					winner.color_ = this->board[0][3][l][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = 3-x;
+						winner.winningHeight[x] = l;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -252,5 +390,14 @@
 					break;
 				if(i==3)
-					return this->board[0][0][l][3];
+				{
+					winner.color_ = this->board[0][0][l][3];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = l;
+						winner.winningNumber[x] = 3-x;
+					}
+					return winner;
+				}
 			}
 		}
@@ -264,5 +411,14 @@
 					break;
 				if(i==3)
-					return this->board[0][l][0][0];
+				{
+					winner.color_ = this->board[0][l][0][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = l;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -271,5 +427,14 @@
 					break;
 				if(i==3)
-					return this->board[3][l][0][0];
+				{
+					winner.color_ = this->board[3][l][0][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = 3-x;
+						winner.winningColumn[x] = l;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -278,5 +443,14 @@
 					break;
 				if(i==3)
-					return this->board[0][l][3][0];
+				{
+					winner.color_ = this->board[0][l][3][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = l;
+						winner.winningHeight[x] = 3-x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -285,5 +459,14 @@
 					break;
 				if(i==3)
-					return this->board[0][l][0][3];
+				{
+					winner.color_ = this->board[0][l][0][3];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = x;
+						winner.winningColumn[x] = l;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = 3-x;
+					}
+					return winner;
+				}
 			}
 		}
@@ -297,5 +480,14 @@
 					break;
 				if(i==3)
-					return this->board[l][0][0][0];
+				{
+					winner.color_ = this->board[l][0][0][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = l;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -304,5 +496,14 @@
 					break;
 				if(i==3)
-					return this->board[l][3][0][0];
+				{
+					winner.color_ = this->board[l][3][0][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = l;
+						winner.winningColumn[x] = 3-x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -311,5 +512,14 @@
 					break;
 				if(i==3)
-					return this->board[l][0][3][0];
+				{
+					winner.color_ = this->board[l][0][3][0];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = l;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = 3-x;
+						winner.winningNumber[x] = x;
+					}
+					return winner;
+				}
 			}
 			for(int i=1; i<4; i++)
@@ -318,19 +528,220 @@
 					break;
 				if(i==3)
-					return this->board[l][0][0][3];
-			}
-		}
-
-		//check diagonals rows-columns
+				{
+					winner.color_ = this->board[l][0][0][3];
+					for(int x=0; x<4; x++){
+						winner.winningRow[x] = l;
+						winner.winningColumn[x] = x;
+						winner.winningHeight[x] = x;
+						winner.winningNumber[x] = 3-x;
+					}
+					return winner;
+				}
+			}
+		}
+
+		//check 2d diagonals
 		for(int k=0;k<4;k++){
     		for(int l=0;l<4;l++){
+    			//rows-columns
     			for(int i=1; i<4; i++)
 				{
-					if(this->board[i][i][k][l]==mini4DgamePlayerColor::none || this->board[0][0][l][0] != this->board[i][i][l][i])
+					if(this->board[i][i][k][l]==mini4DgamePlayerColor::none || this->board[0][0][k][l] != this->board[i][i][k][l])
 						break;
 					if(i==3)
-						return this->board[0][0][l][0];
-				}}}
-    	//-------------------------------------------------------------------------------------------------------
+					{
+						winner.color_ = this->board[0][0][k][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = x;
+							winner.winningColumn[x] = x;
+							winner.winningHeight[x] = k;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+				{
+					if(this->board[3-i][i][k][l]==mini4DgamePlayerColor::none || this->board[3][0][k][l] != this->board[3-i][i][k][l])
+						break;
+					if(i==3)
+					{
+						winner.color_ = this->board[3][0][k][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = 3-x;
+							winner.winningColumn[x] = x;
+							winner.winningHeight[x] = k;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				//rows-height
+    			for(int i=1; i<4; i++)
+    			{
+    				if(this->board[i][k][i][l]==mini4DgamePlayerColor::none || this->board[0][k][0][l] != this->board[i][k][i][l])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[0][k][0][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = x;
+							winner.winningColumn[x] = k;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[3-i][k][i][l]==mini4DgamePlayerColor::none || this->board[3][k][0][l] != this->board[3-i][k][i][l])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[3][k][0][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = 3-x;
+							winner.winningColumn[x] = k;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				//rows-numbers
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[i][k][l][i]==mini4DgamePlayerColor::none || this->board[0][k][l][0] != this->board[i][k][l][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[0][k][l][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = x;
+							winner.winningColumn[x] = k;
+							winner.winningHeight[x] = l;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[3-i][k][l][i]==mini4DgamePlayerColor::none || this->board[3][k][l][0] != this->board[3-i][k][l][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[3][k][l][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = 3-x;
+							winner.winningColumn[x] = k;
+							winner.winningHeight[x] = l;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+				//column-height
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][i][i][l]==mini4DgamePlayerColor::none || this->board[k][0][0][l] != this->board[k][i][i][l])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][0][0][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = x;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][3-i][i][l]==mini4DgamePlayerColor::none || this->board[k][3][0][l] != this->board[k][3-i][i][l])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][3][0][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = 3-x;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
+					}
+				}
+				//column-numbers
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][i][l][i]==mini4DgamePlayerColor::none || this->board[k][0][l][0] != this->board[k][i][l][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][0][l][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = x;
+							winner.winningHeight[x] = l;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][3-i][l][i]==mini4DgamePlayerColor::none || this->board[k][3][l][0] != this->board[k][3-i][l][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][3][l][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = 3-x;
+							winner.winningHeight[x] = l;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+				//height-numbers
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][l][i][i]==mini4DgamePlayerColor::none || this->board[k][l][0][0] != this->board[k][l][i][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][l][0][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = l;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+				for(int i=1; i<4; i++)
+    			{
+    				if(this->board[k][l][3-i][i]==mini4DgamePlayerColor::none || this->board[k][l][3][0] != this->board[k][l][3-i][i])
+    					break;
+    				if(i==3)
+    				{
+						winner.color_ = this->board[k][l][3][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = k;
+							winner.winningColumn[x] = l;
+							winner.winningHeight[x] = 3-x;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
+					}
+				}
+    		}
+    	}
 
     	//check rows
@@ -343,5 +754,12 @@
     				   && this->board[2][j][k][l]==this->board[3][j][k][l])
     				{
-    					return this->board[0][j][k][l];
+    					winner.color_ = this->board[0][j][k][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = x;
+							winner.winningColumn[x] = j;
+							winner.winningHeight[x] = k;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
     				}
     			}
@@ -358,5 +776,12 @@
     	    				   && this->board[i][2][k][l]==this->board[i][3][k][l])
     				{
-    	    			return this->board[i][0][k][l];
+    	    			winner.color_ = this->board[i][0][k][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = i;
+							winner.winningColumn[x] = x;
+							winner.winningHeight[x] = k;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
     				}
     			}
@@ -373,5 +798,12 @@
     	    	    				   && this->board[i][j][2][l]==this->board[i][j][3][l])
     				{
-    					return this->board[i][j][0][l];
+    					winner.color_ = this->board[i][j][0][l];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = i;
+							winner.winningColumn[x] = j;
+							winner.winningHeight[x] = x;
+							winner.winningNumber[x] = l;
+						}
+						return winner;
     				}
     			}
@@ -388,12 +820,17 @@
     	    	    				   && this->board[i][j][k][2]==this->board[i][j][k][3])
     				{
-    					return this->board[i][j][k][0];
+    					winner.color_ = this->board[i][j][k][0];
+						for(int x=0; x<4; x++){
+							winner.winningRow[x] = i;
+							winner.winningColumn[x] = j;
+							winner.winningHeight[x] = k;
+							winner.winningNumber[x] = x;
+						}
+						return winner;
     				}
     			}
     		}
     	}
-
-
-    	return mini4DgamePlayerColor::none;
+    	return winner;
     }
 }
Index: /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.h
===================================================================
--- /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.h	(revision 10120)
+++ /code/branches/minigame4DHS14/src/modules/mini4Dgame/Mini4DgameCenterpoint.h	(revision 10121)
@@ -41,4 +41,5 @@
 #include "worldentities/StaticEntity.h"
 #include "mini4Dgame/Mini4DgamePrereqs.h"
+#include "mini4Dgame/Mini4Dgame.h"
 
 namespace orxonox
@@ -109,5 +110,5 @@
                     @param the position where to put the stone plus the player who makes the move
             */
-            bool isValidMove(const Vector4 move,const int playerColor);
+            bool isValidMove(const Vector4 move);
 
             /**
@@ -115,11 +116,11 @@
            	   @param the position where to put the stone plus the player who makes the move
              */
-            void makeMove(const Vector4 move, const int player);
+            void makeMove(const Vector4 move, const mini4DgamePlayerColor::color playerColor);
 
             /**
-                @brief searches the board if somebody has won
-				@return the winner if somebody has won or mini4DgamePlayerColor::none if nobody has won so far
-             */
-            mini4DgamePlayerColor::color Mini4DgameCenterpoint::getWinner()
+               @brief checks if somebody has won
+               @return the winner with the winning fields or a winner with winner.color_ == mini4DgamePlayerColor::none if nobody has won so far.
+            */
+            Mini4DgameWinner Mini4DgameCenterpoint::getWinner();
 
         private:
