private void flood_fill_points(char[][] map_copy, Character[] tiles, int w, int h, 
      char color, Stack<Point> tolook) {
    while (!tolook.isEmpty()) {
      Point p = tolook.pop();
      int x = p.x, y = p.y;

      if (!(x > -1 && x < w && y > -1 && y < h)) {
	// out of map bounds
	continue;
      }
      LinkedList<Character> m_tile = new LinkedList<Character>(); //Added by Kinshuk
      for(int i=0;i<tiles.length;i++)				  //	
	m_tile.add(tiles[i]);					  //	
	
      if (/*Arrays.binarySearch(tiles, map_copy[x][y]) >= 0*/m_tile.contains(map_copy[x][y])) {
	map_copy[x][y] = color;
	tolook.push(new Point(x+1, y));
	tolook.push(new Point(x+1, y+1));
	tolook.push(new Point(x+1, y-1));
	tolook.push(new Point(x-1, y));
	tolook.push(new Point(x-1, y+1));
	tolook.push(new Point(x-1, y-1));
	tolook.push(new Point(x, y+1));
	tolook.push(new Point(x, y-1));
      }
    }
  }