diff --git a/library/include/dfhack/modules/Maps.h b/library/include/dfhack/modules/Maps.h index fcadecc92..a9ce94a06 100644 --- a/library/include/dfhack/modules/Maps.h +++ b/library/include/dfhack/modules/Maps.h @@ -148,7 +148,7 @@ namespace DFHack liquid_water, liquid_magma }; - + /* enum e_liquidcharacter { liquid_fresh, @@ -156,7 +156,7 @@ namespace DFHack liquid_salt, liquid_unk2, }; - + */ struct naked_designation { unsigned int flow_size : 3; // how much liquid is here? @@ -196,14 +196,9 @@ namespace DFHack unsigned int feature_local : 1; /// this tile is a part of a global feature. can be combined with 'featstone' tiles unsigned int feature_global : 1; - /** - * water characteristics - * fresh=0 - * ?=1 - * salt=2 - * ?=3 - */ - e_liquidcharacter liquid_character : 2; + unsigned int water_stagnant : 1; + unsigned int water_salt : 1; + // e_liquidcharacter liquid_character : 2; }; union t_designation diff --git a/tools/playground/hellhole.cpp b/tools/playground/hellhole.cpp index a57b815a1..cc12554be 100644 --- a/tools/playground/hellhole.cpp +++ b/tools/playground/hellhole.cpp @@ -1004,7 +1004,8 @@ int main (void) if (fillmagma || fillwater) { d->bits.flow_size=7; - d->bits.liquid_character = liquid_fresh; + d->bits.water_stagnant = false; + d->bits.water_salt = false; if (fillmagma) { d->bits.liquid_type=liquid_magma; @@ -1018,7 +1019,8 @@ int main (void) { //Otherwise, remove all liquids. d->bits.flow_size=0; - d->bits.liquid_character = liquid_fresh; + d->bits.water_stagnant = false; + d->bits.water_salt = false; d->bits.liquid_type = liquid_water; } @@ -1087,7 +1089,8 @@ int main (void) //Erase any liquids, as they cause problems. d->bits.flow_size=0; - d->bits.liquid_character = liquid_fresh; + d->bits.water_stagnant = false; + d->bits.water_salt = false; d->bits.liquid_type=liquid_water; //Placing an aquifer? @@ -1121,7 +1124,8 @@ int main (void) //Erase any liquids, as they cause problems. d->bits.flow_size=0; - d->bits.liquid_character = liquid_fresh; + d->bits.water_stagnant = false; + d->bits.water_salt = false; d->bits.liquid_type=liquid_water; break; default: diff --git a/tools/supported/veinlook.cpp b/tools/supported/veinlook.cpp index 7eaa2419f..90e2f9c29 100644 --- a/tools/supported/veinlook.cpp +++ b/tools/supported/veinlook.cpp @@ -620,7 +620,9 @@ main(int argc, char *argv[]) { TEMP_NO, TEMP_1, - TEMP_2 + TEMP_2, + WATER_SALT, + WATER_STAGNANT }; e_tempmode temperature = TEMP_NO; @@ -691,6 +693,12 @@ main(int argc, char *argv[]) case 'm': temperature = TEMP_2; break; + case 'c': + temperature = WATER_SALT; + break; + case 'v': + temperature = WATER_STAGNANT; + break; case 27: // escape key DF->Detach(); return 0; @@ -940,6 +948,30 @@ main(int argc, char *argv[]) } } } + else if(temperature == WATER_SALT) + { + for(int x = 0; x < 16; x++) for(int y = 0; y < 16; y++) + { + if(Block->designation[x][y].bits.water_salt) + { + putch(x + 16,y + 16,'@',COLOR_WHITE); + } + } + gotoxy (50,8); + cprintf ("Salt water"); + } + else if(temperature == WATER_STAGNANT) + { + for(int x = 0; x < 16; x++) for(int y = 0; y < 16; y++) + { + if(Block->designation[x][y].bits.water_stagnant) + { + putch(x + 16,y + 16,'@',COLOR_WHITE); + } + } + gotoxy (50,8); + cprintf ("Stagnant water"); + } else { if(temperature == TEMP_1)