1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-09-01 02:07:57 +00:00

custom modes manager now lists modes which have recorded scores

This commit is contained in:
Zeno Rogue
2024-06-02 12:27:48 +02:00
parent c9b7e0ac1d
commit 5877690cce
2 changed files with 95 additions and 2 deletions

View File

@@ -490,6 +490,8 @@ EX void show_custom() {
gamescreen();
dialog::init(XLAT("custom mode"));
list_saved_custom_modes();
dialog::addBreak(100);
if(custom_welcome != "") {
dialog::addInfo("custom welcome message:");
dialog::addInfo(custom_welcome);
@@ -502,7 +504,7 @@ EX void show_custom() {
dialog::edit_string(custom_welcome, "custom welcome message", "");
});
dialog::addBreak(100);
dialog::addItem("save custom mode", 's');
dialog::addItem("save custom mode", 'S');
dialog::add_action([] {
dialog::openFileDialog(customfile, XLAT("file to save:"), ".hrm", [] () {
try {
@@ -516,7 +518,7 @@ EX void show_custom() {
}
});
});
dialog::addItem("load custom mode", 'l');
dialog::addItem("load custom mode", 'L');
dialog::add_action([] {
dialog::openFileDialog(customfile, XLAT("file to load:"), ".hrm", [] () {
try {
@@ -1259,6 +1261,9 @@ int read_menu_args() {
else if(argis("-d:mode")) {
PHASEFROM(2); launch_dialog(showChangeMode);
}
else if(argis("-d:custom")) {
PHASEFROM(2); launch_dialog(show_custom);
}
else if(argis("-d:history")) {
PHASEFROM(2); launch_dialog(history::history_menu);
}