I try to load a file with fstream. The code looks like this
file.open("../levels/level0.lvl");
if (file.is_open()) {
while (!file.eof()) {
std::getline(file, Str);
list = ReadLine(Str, list);
}
}
But it loads nothing. Yes only if the path is absolute. How can I make the path relative?
The folder "levels" is hosted in the debug folder. same folder as the exe.