From 2006616a428c805cea7f8557d4672bbafde84123 Mon Sep 17 00:00:00 2001 From: Nathan Stoddard Date: Thu, 31 Aug 2023 06:28:52 -0700 Subject: [PATCH] Make levers indestructible via shattering and tunneling (#591) This prevents shattering and tunneling from making some vaults impossible to open. --- changes/shattering-lever.md | 1 + src/brogue/Globals.c | 12 ++++++------ 2 files changed, 7 insertions(+), 6 deletions(-) create mode 100644 changes/shattering-lever.md diff --git a/changes/shattering-lever.md b/changes/shattering-lever.md new file mode 100644 index 00000000..df357025 --- /dev/null +++ b/changes/shattering-lever.md @@ -0,0 +1 @@ +Make levers indestructible via shattering and tunneling, which would leave some vaults impossible to open. diff --git a/src/brogue/Globals.c b/src/brogue/Globals.c index 4d92fd49..f7ad9c23 100644 --- a/src/brogue/Globals.c +++ b/src/brogue/Globals.c @@ -1252,7 +1252,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {{4, AMULET_LEVEL}, {1, 1}, 8, 3, 0, (BP_VESTIBULE), { {0, WORM_TUNNEL_OUTER_WALL,DUNGEON,{1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_AT_ORIGIN | MF_PERMIT_BLOCKING | MF_IMPREGNABLE | MF_ALTERNATIVE)}, {0, PORTCULLIS_CLOSED,DUNGEON, {1,1}, 1, 0, 0, 0, 3, 0, 0, (MF_BUILD_AT_ORIGIN | MF_PERMIT_BLOCKING | MF_IMPREGNABLE | MF_ALTERNATIVE)}, - {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL)}}}, + {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_IMPREGNABLE)}}}, // Flammable barricade in the doorway -- burn the wooden barricade to enter {{1, 6}, {1, 1}, 10, 3, 0, (BP_VESTIBULE), { {0, WOODEN_BARRICADE,DUNGEON, {1,1}, 1, 0, 0, 0, 1, 0, 0, (MF_PERMIT_BLOCKING | MF_BUILD_AT_ORIGIN)}, @@ -1356,7 +1356,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {DF_ADD_DORMANT_CHASM_HALO, CHASM,LIQUID,{120, 120},1, 0, -1, 0, 1, 0, 0, (MF_TREAT_AS_BLOCKING | MF_REPEAT_UNTIL_NO_PROGRESS)}, {DF_ADD_DORMANT_CHASM_HALO, CHASM_WITH_HIDDEN_BRIDGE,LIQUID,{1,1},1,0, 0, 0, 1, 0, 0, (MF_PERMIT_BLOCKING | MF_EVERYWHERE)}, {0, 0, 0, {1,1}, 1, POTION, POTION_LEVITATION, 0, 1, 0, 0, (MF_GENERATE_ITEM | MF_BUILD_ANYWHERE_ON_LEVEL | MF_NOT_IN_HALLWAY | MF_ALTERNATIVE)}, - {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_ALTERNATIVE)}}}, + {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_ALTERNATIVE | MF_IMPREGNABLE)}}}, // Web climbing -- key on an altar, room filled with pit, spider at altar to shoot webs, bridge appears when you grab the key {{7, AMULET_LEVEL}, {55, 90}, 10, 7, 0, (BP_ROOM | BP_ADOPT_ITEM | BP_PURGE_INTERIOR | BP_OPEN_INTERIOR | BP_SURROUND_WITH_WALLS), { {0, ALTAR_SWITCH,DUNGEON, {1,1}, 1, 0, -1, MK_SPIDER, 3, 0, 0, (MF_ADOPT_ITEM | MF_FAR_FROM_ORIGIN | MF_TREAT_AS_BLOCKING | MF_IN_VIEW_OF_ORIGIN)}, @@ -1372,7 +1372,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {DF_LAVA_RETRACTABLE, LAVA_RETRACTABLE, LIQUID, {1,1}, 1, 0, 0, 0, 1, 0, 0, (MF_PERMIT_BLOCKING | MF_EVERYWHERE)}, {0, 0, 0, {1,1}, 1, POTION, POTION_LEVITATION, 0, 1, 0, 0, (MF_GENERATE_ITEM | MF_BUILD_ANYWHERE_ON_LEVEL | MF_NOT_IN_HALLWAY | MF_ALTERNATIVE)}, {0, 0, 0, {1,1}, 1, POTION, POTION_FIRE_IMMUNITY, 0, 1, 0, 0, (MF_GENERATE_ITEM | MF_BUILD_ANYWHERE_ON_LEVEL | MF_NOT_IN_HALLWAY | MF_ALTERNATIVE)}, - {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_ALTERNATIVE)}}}, + {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_ALTERNATIVE | MF_IMPREGNABLE)}}}, // Lava moat area -- key on an altar, surrounded with lava, levitation/fire immunity elsewhere on level, lava retracts when you grab the key {{3, 13}, {40, 60}, 3, 5, 0, (BP_ADOPT_ITEM | BP_PURGE_INTERIOR | BP_OPEN_INTERIOR | BP_TREAT_AS_BLOCKING), { {0, ALTAR_SWITCH,DUNGEON, {1,1}, 1, 0, -1, 0, 2, 0, 0, (MF_ADOPT_ITEM | MF_BUILD_AT_ORIGIN | MF_TREAT_AS_BLOCKING)}, @@ -1387,7 +1387,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {0, TRAP_DOOR_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 2, 0, 0, MF_ALTERNATIVE}, {0, 0, 0, {1,1}, 1, SCROLL, SCROLL_TELEPORT, 0, 2, 0, 0, (MF_GENERATE_ITEM | MF_NOT_IN_HALLWAY | MF_ALTERNATIVE)}, {0, 0, 0, {1,1}, 1, POTION, POTION_DESCENT, 0, 2, 0, 0, (MF_GENERATE_ITEM | MF_NOT_IN_HALLWAY | MF_ALTERNATIVE)}, - {0, WALL_LEVER_HIDDEN_DORMANT,DUNGEON,{1,1},1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS)}, + {0, WALL_LEVER_HIDDEN_DORMANT,DUNGEON,{1,1},1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IMPREGNABLE)}, {0, PORTCULLIS_DORMANT,DUNGEON,{1,1}, 1, 0, 0, 0, 1, 0, 0, (MF_BUILD_AT_ORIGIN | MF_PERMIT_BLOCKING)}}}, // Explosive situation -- key on an altar; take key to cause a methane gas vent to appear and a pilot light to ignite {{7, AMULET_LEVEL}, {80, 90}, 10, 5, 0, (BP_ROOM | BP_PURGE_LIQUIDS | BP_SURROUND_WITH_WALLS | BP_ADOPT_ITEM), { @@ -1464,7 +1464,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {0, ELECTRIC_CRYSTAL_OFF,DUNGEON,{3,4}, 3, 0, -1, 0, 3, 0, 0, (MF_NOT_IN_HALLWAY | MF_IMPREGNABLE)}, {0, SACRED_GLYPH, DUNGEON, {1, 1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_AT_ORIGIN)}, {0, ALTAR_CAGE_RETRACTABLE,DUNGEON,{1,1}, 1, 0, -1, 0, 3, 0, 0, (MF_ADOPT_ITEM | MF_IMPREGNABLE | MF_NOT_IN_HALLWAY | MF_FAR_FROM_ORIGIN)}, - {0, TURRET_LEVER, DUNGEON, {7,9}, 4, 0, -1, MK_SPARK_TURRET,3, 0, 0, (MF_BUILD_IN_WALLS | MF_MONSTERS_DORMANT)}}}, + {0, TURRET_LEVER, DUNGEON, {7,9}, 4, 0, -1, MK_SPARK_TURRET,3, 0, 0, (MF_BUILD_IN_WALLS | MF_MONSTERS_DORMANT | MF_IMPREGNABLE)}}}, // Zombie crypt -- key on an altar; coffins scattered around; brazier in the room; take key to cause zombies to burst out of all of the coffins {{12, AMULET_LEVEL},{60, 90}, 10, 8, 0, (BP_ROOM | BP_ADOPT_ITEM | BP_SURROUND_WITH_WALLS | BP_PURGE_INTERIOR), { {0, DOOR, DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_AT_ORIGIN)}, @@ -1488,7 +1488,7 @@ const blueprint blueprintCatalog[NUMBER_BLUEPRINTS] = { {0, GRANITE, DUNGEON, {150,150}, 1, 0, -1, 0, 1, 0, 0, (MF_TREAT_AS_BLOCKING | MF_REPEAT_UNTIL_NO_PROGRESS)}, {DF_WORM_TUNNEL_MARKER_DORMANT,GRANITE,DUNGEON,{0,0},0, 0, -1, 0, 0, 0, 0, (MF_EVERYWHERE | MF_PERMIT_BLOCKING)}, {DF_TUNNELIZE,WORM_TUNNEL_OUTER_WALL,DUNGEON,{1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_AT_ORIGIN | MF_PERMIT_BLOCKING)}, - {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL)}}}, + {0, WALL_LEVER_HIDDEN,DUNGEON, {1,1}, 1, 0, -1, 0, 1, 0, 0, (MF_BUILD_IN_WALLS | MF_IN_PASSABLE_VIEW_OF_ORIGIN | MF_BUILD_ANYWHERE_ON_LEVEL | MF_IMPREGNABLE)}}}, // Gauntlet -- key on an altar; take key to cause turrets to emerge {{5, 24}, {35, 90}, 10, 2, 0, (BP_ADOPT_ITEM | BP_NO_INTERIOR_FLAG), { {0, ALTAR_SWITCH,DUNGEON, {1,1}, 1, 0, -1, 0, 2, 0, 0, (MF_ADOPT_ITEM | MF_NEAR_ORIGIN | MF_NOT_IN_HALLWAY | MF_TREAT_AS_BLOCKING)},