public void moveRandom()
    {		
		if(getTimeStamp() == 0)		// If clock is reset..
		{		
			setTimeStamp(TimeHandler.getTime());		// Set clock
			setActionTime(random.nextInt(1500) + 500);	// Set a random duration (500-2000 ms) to move/stay										
			switch(random.nextInt(4))  					// Randomize a direction			
				{
				case 0:
					moveY(-1);
					break;
				case 1:
					moveY(1);
					break;
				case 2:
					moveX(1);
					break;
				case 3:
					moveX(-1);
					break;
				}		
		}
				
		if( !TimeHandler.timePassed(getTimeStamp(), getActionTime()) )	// If time hasn't expired, move or stand still..
		{
			if(isMoving())
			{
				move();			
			}
			else resetDirection();
		}
		else											// ..else reset clock and invert isMoving state
		{						
			setMoving();
			setTimeStamp(0);
		}
	}