Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: is there a way to "unreveal"  (Read 533 times)

toast

  • Bay Watcher
    • View Profile
is there a way to "unreveal"
« on: October 21, 2008, 07:35:11 pm »

i just used reveal for the first time...accidentally over wrote my save. Is there a way to get it back to normal? i know what i want to know now :p
Logged
-Toast-_

Dr_Dungeon

  • Bay Watcher
    • View Profile
Re: is there a way to "unreveal"
« Reply #1 on: October 22, 2008, 02:05:56 am »

you need For Each Tile module for Gibbed's Dwarf Fortress Tweak - you can find it here:
http://dwarf.lendemaindeveille.com/index.php/User:Exponent/For_Each_Tile

Create new operation set:

Condition:
Code: [Select]
(x > 0) and (x < map_width) and
(y > 0) and (y < map_height) and
is_wall and not
(
 (
  (is_floor(x - 1, y - 1, z)) or
  (is_floor(x - 1, y    , z)) or
  (is_floor(x - 1, y + 1, z)) or
  (is_floor(x    , y - 1, z)) or
  (is_floor(x    , y + 1, z)) or
  (is_floor(x + 1, y - 1, z)) or
  (is_floor(x + 1, y    , z)) or
  (is_floor(x + 1, y + 1, z))
 )
 or
 (
  (is_stair(x - 1, y - 1, z)) or
  (is_stair(x - 1, y    , z)) or
  (is_stair(x - 1, y + 1, z)) or
  (is_stair(x    , y - 1, z)) or
  (is_stair(x    , y + 1, z)) or
  (is_stair(x + 1, y - 1, z)) or
  (is_stair(x + 1, y    , z)) or
  (is_stair(x + 1, y + 1, z))
 )
 or
 (
  (is_ramp(x - 1, y - 1, z)) or
  (is_ramp(x - 1, y    , z)) or
  (is_ramp(x - 1, y + 1, z)) or
  (is_ramp(x    , y - 1, z)) or
  (is_ramp(x    , y + 1, z)) or
  (is_ramp(x + 1, y - 1, z)) or
  (is_ramp(x + 1, y    , z)) or
  (is_ramp(x + 1, y + 1, z))
 )
 or
 ( 
  (is_chasm(x - 1, y - 1, z)) or
  (is_chasm(x - 1, y    , z)) or
  (is_chasm(x - 1, y + 1, z)) or
  (is_chasm(x    , y - 1, z)) or
  (is_chasm(x    , y + 1, z)) or
  (is_chasm(x + 1, y - 1, z)) or
  (is_chasm(x + 1, y    , z)) or
  (is_chasm(x + 1, y + 1, z))
 )
 or
 (
  (is_water(x - 1, y - 1, z)) or
  (is_water(x - 1, y    , z)) or
  (is_water(x - 1, y + 1, z)) or
  (is_water(x    , y - 1, z)) or
  (is_water(x    , y + 1, z)) or
  (is_water(x + 1, y - 1, z)) or
  (is_water(x + 1, y    , z)) or
  (is_water(x + 1, y + 1, z))
 )
 or
 (
  (is_magma(x - 1, y - 1, z)) or
  (is_magma(x - 1, y    , z)) or
  (is_magma(x - 1, y + 1, z)) or
  (is_magma(x    , y - 1, z)) or
  (is_magma(x    , y + 1, z)) or
  (is_magma(x + 1, y - 1, z)) or
  (is_magma(x + 1, y    , z)) or
  (is_magma(x + 1, y + 1, z))
 )
 or
 (
  (is_air(x - 1, y - 1, z)) or
  (is_air(x - 1, y    , z)) or
  (is_air(x - 1, y + 1, z)) or
  (is_air(x    , y - 1, z)) or
  (is_air(x    , y + 1, z)) or
  (is_air(x + 1, y - 1, z)) or
  (is_air(x + 1, y    , z)) or
  (is_air(x + 1, y + 1, z))
 )
)

Operations:
Code: [Select]
hide;
I am sure that it can be done in more elegant way - but even as it is it should work.
Logged
- Dis is turnink into vun of DOSE plans... Hyu know - de kind vere ve keel everybody dot notices dot ve's killin'people. And how do dose alvays end?
- De dirigible iz in flames, everyboddyz dead an'ive lost my hat.
- Dot's right. Und any plan vere you lose your hat iz?
- A bad plan?
- Right again!