code: private void updateTile(Collection<Tile> resolved,
                              Collection<Tile> toResolve,
                              Tile tile,
                              Tile neighbor,
                              Transition transition)
      {
          final Iterator<TileRef> iterator = getTiles(transition).iterator();
          if (iterator.hasNext())
          {
              final TileRef ref = iterator.next();
              final Tile newTile = map.createTile(ref.getSheet(), ref.getNumber(), neighbor.getX(), neighbor.getY());
              map.setTile(newTile);
              resolved.add(newTile);
          }
          else
          {
              final Tile newTile = map.createTile(tile.getSheet(), tile.getNumber(), neighbor.getX(), neighbor.getY());
              final String groupA = mapGroup.getGroup(tile);
              final String groupB = mapGroup.getGroup(neighbor);
  
              // Used to fix transitions not found
              if (!neighbor.equals(newTile)
                  && (!isCenter(neighbor)
                      || groupA.equals(groupB)
                      || groupLinks.contains(new GroupTransition(groupA, groupB))))
              {
                  map.setTile(newTile);
                  toResolve.add(newTile);
              }
              resolved.add(newTile);
          }
      }
docs: Update tile.
  
  @param resolved The resolved tiles.
  @param toResolve Tiles to resolve after.
  @param tile The tile placed.
  @param neighbor The tile to update.
  @param transition The transition to set.