]> granicus.if.org Git - nethack/commitdiff
Fix Fort Ludios room type
authorPasi Kallinen <paxed@alt.org>
Sun, 1 Mar 2020 08:13:50 +0000 (10:13 +0200)
committerPasi Kallinen <paxed@alt.org>
Sun, 1 Mar 2020 08:13:53 +0000 (10:13 +0200)
... and add an impossible when lua tries to create unknown room type.

dat/knox.lua
src/sp_lev.c

index cc38b6a44d8d3525333b10e94257e7ea6a92a27f..87832a3a2c66870823a30b653373125e89759134 100644 (file)
@@ -65,7 +65,7 @@ function treasure_spot(x,y)
    end
 end
 
-des.region({ region={21,08,35,11}, lit=1, type="orginary" })
+des.region({ region={21,08,35,11}, lit=1, type="ordinary" })
 local treasury = selection.area(21,08,35,11);
 treasury:iterate(treasure_spot);
 
index a17abfdcd4b5a91af16cc5768a7eb66a98cde4ea..aed5a08e827d48eb3a15c6f58ebeae2b54cce6d2 100755 (executable)
@@ -3496,6 +3496,8 @@ int defval;
                 res = room_types[i].type;
                 break;
             }
+        if (!room_types[i].name)
+            impossible("Unknown room type '%s'", roomstr);
     }
     Free(roomstr);
     return res;