1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-23 21:07:17 +00:00

split the projection menu into two screens

This commit is contained in:
Zeno Rogue 2019-08-14 08:32:05 +02:00
parent 10a8b8660b
commit 3d813e83b9

View File

@ -316,18 +316,17 @@ EX namespace models {
}
};
}
EX void model_menu() {
EX void model_list() {
cmode = sm::SIDE | sm::MAYDARK | sm::CENTER;
gamescreen(0);
dialog::init(XLAT("models & projections"));
string chars = "0123456789!@#$%^&*()][{}'\"";
int cpos = 0;
for(int i=0; i<mdGUARD; i++) {
eModel m = eModel(i);
if(m == mdFormula && ISMOBILE) continue;
if(model_available(m)) {
dialog::addBoolItem(get_model_name(m), pmodel == m, chars[cpos++]);
dialog::addBoolItem(get_model_name(m), pmodel == m, (i < 26 ? 'a'+i : 'A'+i-26));
dialog::add_action([m] () {
if(m == mdFormula) {
edit_formula();
@ -344,7 +343,16 @@ EX namespace models {
}
}
dialog::addBreak(100);
dialog::display();
}
EX void model_menu() {
cmode = sm::SIDE | sm::MAYDARK | sm::CENTER;
gamescreen(0);
dialog::init(XLAT("models & projections"));
dialog::addSelItem(XLAT("projection type"), get_model_name(pmodel), 'm');
dialog::add_action_push(model_list);
if(nonisotropic)
dialog::addBoolItem_action(XLAT("geodesic movement in Sol/Nil"), nisot::geodesic_movement, 'G');