mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-03-13 23:18:16 +00:00
throw an exception when file does not exist
This commit is contained in:
parent
0ae3ab3c9b
commit
e3664c79a3
@ -216,6 +216,7 @@ EX void load_tile(exp_parser& ep, arbi_tiling& c, bool unit) {
|
||||
|
||||
EX void load(const string& fname, bool after_sliding IS(false)) {
|
||||
fhstream f(fname, "rt");
|
||||
if(!f.f) throw hr_parse_exception("file " + fname + " does not exist");
|
||||
string s;
|
||||
while(true) {
|
||||
int c = fgetc(f.f);
|
||||
|
Loading…
x
Reference in New Issue
Block a user