diff --git a/rogueviz/ru/globals.cpp b/rogueviz/ru/globals.cpp index 8d3f4d7a..8cb34f2c 100644 --- a/rogueviz/ru/globals.cpp +++ b/rogueviz/ru/globals.cpp @@ -59,7 +59,7 @@ enum eWall { wAir, wWall, wBouncy, wSpike, wWater, wFrozen, wDoor, wSmashedDoor, wLockedDoor, wFountain, wBluePortal, wOrangePortal, wPlatform, wStaircase, wColumn, wForge, wWoodWall, wShopDoor, wSecretPassage, wSign, wWallSign, wTimeDoor, - wBottomSpike, wGUARD }; + wBottomSpike, wRogueWallHidden, wRogueWall, wGUARD }; flagtype W_BLOCK = 1; flagtype W_TRANS = 2; @@ -98,6 +98,8 @@ ruwall walls[qwall] = { {"wall sign", "X", 0xFFFFC0FF, W_BLOCK, "You need to wait close to this sign to read it."}, {"time door", "#", 0x8080FFFF, W_BLOCK | W_STABLE, "A powerful door, opened by a mechanism."}, {"bottom spike", "v", 0xC08080FF, W_TRANS | W_PAIN | W_BLOCKBIRD | W_DOWNWARD, "A downward-pointing spike. You can fall from above through it safely, but otherwise, it is very dangerous."}, + {"wall", "#", 0xFFFFFFFF, W_BLOCK | W_STABLE, "These kinds of tough walls can never be destroyed."}, + {"fake wall", "#", 0x404080FF, W_PLATFORM | W_STABLE | W_BLOCKBIRD, "Your rogueish senses have discovered that this wall is fake."}, }; int sel = 1; diff --git a/rogueviz/ru/render.cpp b/rogueviz/ru/render.cpp index 6b7ea457..b1a84eba 100644 --- a/rogueviz/ru/render.cpp +++ b/rogueviz/ru/render.cpp @@ -283,9 +283,16 @@ void man::draw() { int cx = int(h.x / block_x); int cy = int(h.y / block_y); if(cx < 0 || cy < 0 || cx >= room_x || cy >= room_y) break; - if(!(walls[current_room->at(cx, cy)].flags & W_TRANS)) break; + auto what = current_room->at(cx, cy); + if(what == wRogueWallHidden) { + current_room->replace_block_frev(cx, cy, wRogueWall); + addMessage("You discover a secret door!"); + } + if(!(walls[what].flags & W_TRANS)) break; } + vid.linewidth *= 3; queuecurve(scrm, 0x800080, 0, PPR::LINE); + vid.linewidth /= 3; } } diff --git a/rogueviz/ru/save.cpp b/rogueviz/ru/save.cpp index 62b36703..6aa1570b 100644 --- a/rogueviz/ru/save.cpp +++ b/rogueviz/ru/save.cpp @@ -39,6 +39,7 @@ void save_map(string fname) { for(int y=0; y> 3; + if(i == int(wRogueWallHidden)) i = int(wRogueWall); auto& c = code_for[i]; if(c == 0 && !code_used.count(walls[i].glyph[0])) c = walls[i].glyph[0]; if(c == 0) c = next_code++; @@ -52,6 +53,7 @@ void save_map(string fname) { for(int y=0; y>3])); } println(f); @@ -106,6 +108,8 @@ void load_room(fhstream& f, cell *c) { string t = s.substr(2); if(s.size() < 3 || s[1] != ' ') err("load codes", s); for(int i=0; i