Waterfall detection changed

develop
PatrikLundell 2019-07-01 13:29:07 +02:00
parent 242f6fbc38
commit fae5e894ae
1 changed files with 20 additions and 7 deletions

@ -39,7 +39,7 @@ namespace embark_assist {
aquifer, aquifer,
min_river, min_river,
max_river, max_river,
waterfall, min_waterfall,
flatness, flatness,
clay, clay,
sand, sand,
@ -452,7 +452,21 @@ namespace embark_assist {
break; break;
case fields::waterfall: case fields::min_waterfall:
for (int16_t k = -1; k <= 9; k++) {
if (k == -1) {
element->list.push_back({ "N/A", k });
}
else if (k == 0) {
element->list.push_back({ "Absent", k });
}
else {
element->list.push_back({ std::to_string(k), k });
}
}
break;
case fields::blood_rain: case fields::blood_rain:
{ {
embark_assist::defs::yes_no_ranges k = embark_assist::defs::yes_no_ranges::NA; embark_assist::defs::yes_no_ranges k = embark_assist::defs::yes_no_ranges::NA;
@ -986,8 +1000,8 @@ namespace embark_assist {
state->finder_list.push_back({ "Max River", static_cast<int8_t>(i) }); state->finder_list.push_back({ "Max River", static_cast<int8_t>(i) });
break; break;
case fields::waterfall: case fields::min_waterfall:
state->finder_list.push_back({ "Waterfall", static_cast<int8_t>(i) }); state->finder_list.push_back({ "Min Waterfall Drop", static_cast<int8_t>(i) });
break; break;
case fields::flatness: case fields::flatness:
@ -1215,9 +1229,8 @@ namespace embark_assist {
static_cast<embark_assist::defs::river_ranges>(state->ui[static_cast<uint8_t>(i)]->current_value); static_cast<embark_assist::defs::river_ranges>(state->ui[static_cast<uint8_t>(i)]->current_value);
break; break;
case fields::waterfall: case fields::min_waterfall:
finder.waterfall = finder.min_waterfall = state->ui[static_cast<uint8_t>(i)]->current_value;
static_cast<embark_assist::defs::yes_no_ranges>(state->ui[static_cast<uint8_t>(i)]->current_value);
break; break;
case fields::flatness: case fields::flatness: