public void loadConfig(AlpineRescue rescue, String gridFile, String mapFile, Map<String,String> searcherConfig, String direction) {
		try {
			FileReader reader = new FileReader(gridFile);
			@SuppressWarnings("resource")
			Scanner scan = new Scanner(reader);
			String line;
			String[] splitLine;
			
			line = scan.nextLine();
			splitLine = line.split(",");
			try {
				numRows = Integer.parseInt(splitLine[0]);
				numColumns = Integer.parseInt(splitLine[1]);
			} catch (NumberFormatException e) {
				throw new BadConfigFormatException();
			}
		
			int index = 0;
			int numSearchers = 1;
			
			while(scan.hasNextLine()) {
				line = scan.nextLine();
				splitLine = line.split(",");
				if (splitLine.length > numColumns) throw new BadConfigFormatException();
				for (String s : splitLine) {
					GridCell cell = cells.get(index);
					if (searcherConfig.containsKey(s)) {
						rescue.addSearcher("Searcher" + numSearchers, searcherConfig.get(s), direction, cell.getRow(), cell.getColumn());
						numSearchers++;
						cell.setOccupied(true);
					}
					else{
						cell.setOccupied(false);
					}
					index++;
				}
				
			}
		
			scan.close();
		} catch (FileNotFoundException e) {
			e.printStackTrace();
			System.out.println(e.getMessage());
		}
		
	}