forked from jaildesigner-jailgames/jaildoctors_dilemma
Ya guarda y lee la configuracion
This commit is contained in:
@@ -114,7 +114,8 @@ bool Room::load(std::string file_path)
|
||||
std::getline(file, line);
|
||||
if (line.find(".tmx") != std::string::npos)
|
||||
{
|
||||
std::ifstream file2(asset->get(line)); // Abre el fichero tmx
|
||||
std::string filename2 = line;
|
||||
std::ifstream file2(asset->get(filename2)); // Abre el fichero tmx
|
||||
if (file2.good())
|
||||
{
|
||||
bool data_read = false;
|
||||
@@ -145,6 +146,10 @@ bool Room::load(std::string file_path)
|
||||
} while (line != "</data>");
|
||||
}
|
||||
}
|
||||
|
||||
// Cierra el fichero
|
||||
printf("Closing file %s\n\n", filename2.c_str());
|
||||
file2.close();
|
||||
}
|
||||
}
|
||||
} while (line != "[/tilemap]");
|
||||
@@ -275,7 +280,6 @@ bool Room::setVars(std::string var, std::string value)
|
||||
}
|
||||
|
||||
return success;
|
||||
|
||||
}
|
||||
|
||||
// Asigna variables a una estructura enemy_t
|
||||
|
||||
Reference in New Issue
Block a user