Quit / save to main menu
issueid=1348 11-17-2012 10:00 PM
bde bde is offline
Junior Member
Number of reported issues by bde: 1
Quit / save to main menu
Allow the option of quitting and saving to the main menu

With the GUI versions of ADOM, it's sometimes a hassle to have the program close when quitting or saving (for instance, if you want to play a different character, or if you died and want to roll a new character, you have to open the program again). It would be nice to have the option to quit / save to the main menu first, and from there, be able to quit ADOM itself.
Issue Details
Issue Number 1348
Issue Type Feature
Project ADOM (Ancient Domains Of Mystery)
Category All
Status Implemented
Priority 8
Suggested Version ADOM 1.2.0 pre 6
Implemented Version ADOM 1.2.0 pre 17
Milestone (none)
Votes for this feature 6
Votes against this feature 0
Assigned Users (none)
Tags (none)




11-17-2012 10:07 PM
jt jt is offline
Administrator
Thanks to the iOS version this should be easy to add: ADOM kept a lot of "global" variables and structures so that loading/creating a new character was impossible because the old values would modify the new character. Since ADOM on iOS has no "quit" option, there now is a routine that resets ADOM to the initial state.

02-17-2013 05:01 PM
Senior Member
Irrespective of what default behavior would be present if this feature is implemented, I'd like to be able to customize this on adom.cfg. For example, I'd like to keep the current behavior on save (exit) but the new one on quit (go to main menu) and also have one or the other option available in the case of dying.

09-27-2013 08:36 PM
jt jt is offline
Administrator
Added two configuration parameters: Quit_After_Death and Quit_After_Save

The default value for both is "false"; if you set them both to "true" you get the current/old ADOM behavior back.

09-28-2013 09:51 PM
Senior Member
Is it possible to implement a third parameter for deaths by 'Q'uitting as opposed to deaths by other means?

09-28-2013 10:30 PM
jt jt is offline
Administrator
Sure... how about "Quit_After_Leaving"?

09-28-2013 10:51 PM
Senior Member
Sounds good to me, though "quit_after_quitting" would be a little more intuitive, if not very elegant sounding. But it doesn't necessarily need to have an intuitive name as long as its effects are explained in appendix B of the manual.

09-29-2013 10:38 AM
jt jt is offline
Administrator
You are right, "quitting" is more fitting.

09-29-2013 03:44 PM
jt jt is offline
Administrator
Implementing this was a little more complicate than expected. A simple "loop" around around the main menu was not enough since some of the global data is modified during the game (e.g. item rarity). We have to store a backup of this data and restore it before the player starts/loads a new game. Additionally a lot of global variables needed to be reset to their original value.

09-29-2013 04:14 PM
Ancient Member
To avoid the strange "Quit after quitting" name, I would call them:

Exit_After_Death
Exit_After_Save
Exit_After_Quitting

09-29-2013 05:22 PM
jt jt is offline
Administrator
Good idea, done.

09-29-2013 06:33 PM
Senior Member
Quote Originally Posted by jt
Implementing this was a little more complicate than expected. A simple "loop" around around the main menu was not enough since some of the global data is modified during the game (e.g. item rarity). We have to store a backup of this data and restore it before the player starts/loads a new game. Additionally a lot of global variables needed to be reset to their original value.
tl;dr: expect possible strange behaviors after returning to the main menu and starting a new character?

09-30-2013 09:10 PM
jt jt is offline
Administrator
We just found another side effect during testing, but I hope we find all problems before the next Prerelease. :)

+ Reply