nclude <iostream>#include <fstream>#include <string>#include "helper.h"using std::cin, std::cout, std::endl, std::string, std::ifstream;/*** Creates internal representation of dungeon map.* @param fileName File name of dungeon map representation.* @param width Width of dungeon map.* @param height Height of dungeon map.* @param currX Player's starting x-position on dungeon map.* @param currY Player
...[Show More]
nclude <iostream>
#include <fstream>
#include <string>
#include "helper.h"
using std::cin, std::cout, std::endl, std::string, std::ifstream;
/**
* Creates internal representation of dungeon map.
* @param fileName File name of dungeon map representation.
* @param width Width of dungeon map.
* @param height Height of dungeon map.
* @param currX Player's starting x-position on dungeon map.
* @param currY Player's starting y-position on dungeon map.
* @return 2D dynamic array representation of dungeon map with player's
location.
*/
// STEP 1: Write code for createMap(...) function here.
int** createMap(const string fileName, int& width, int& height, int& currX, int&
currY){
ifstream ifs(fileName);
if(!ifs.is_open()){
cout << "ERROR: unable to open: " << fileName << endl;
[Show Less]