1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-12-24 17:10:36 +00:00

fixed crash happening sometimes when loading a different geometry

This commit is contained in:
Zeno Rogue 2017-11-07 14:39:54 +01:00
parent f5a8b2a0c2
commit 908d581c15

View File

@ -166,6 +166,7 @@ namespace mapstream {
bool loadMap(const char *fname) {
f = fopen(fname, "rb");
if(!f) return false;
clearMemory();
int vernum = loadInt();
printf("vernum = %d\n", vernum);
if(vernum >= 7400) load(mapeditor::whichPattern);
@ -191,7 +192,6 @@ namespace mapstream {
resetGeometry();
clearMemory();
initcells();
if(shmup::on) shmup::init();