MENUDEF - Positioning every menu in the bottom right corner

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

MENUDEF - Positioning every menu in the bottom right corner

Postby FFFFRRRR » Wed Mar 31, 2021 5:24 am

Hello.

I am currently working on menus for my project, including main-, episode- and skill-menus.
I would like all of them to be positioned in the bottom right corner of the screen, as I believe it fits the aesthetic very well. This works easily with the main menu.

Code: Select allExpand view
LISTMENU "MainMenu"
{
   Size 450,450
   Font "bigfont","green","olive"
   Position 420, 305
   
   Selector "mmnu_s",10,10
   
   //triangle
   StaticPatch 340, 220, "MMNU_1"

   TextItem "New Game",   "n",   "PlayerclassMenu"
   TextItem "Load one",   "l",   "LoadGameMenu"
   TextItem "Save one",   "s",   "SaveGameMenu"
   TextItem "Settings",   "o",   "OptionsMenu"
   TextItem "Quit it",      "q",   "QuitMenu"
}


Looks like I want it to.

Spoiler:


However, the skill- and episode-menus are giving me a bit of trouble. I know that their contents depend on ZMAPINFO, and that the program automatically fills it.
The positioning seems to work differently with this. My menudef on the episodemenu:

Code: Select allExpand view
ListMenu "EpisodeMenu"
{
   Size 450,450
   Font "bigfont","green","olive"
   Selector "mmnu_s",10,10
   StaticPatch 340, 220, "MMNU_1"
   Position 420, 305
}


What it looks like:
Spoiler:


It seems like the positioning works very differently, as the static triangle is in a different position when using the same coordinates. Maybe it is hardcoded, and cant be changed in this way.
I would like to know if there is a way to position all menus in the bottom right corner, or if this is not possible due to the way they are made.
Thank you in advance!
User avatar
FFFFRRRR
🍋🍋🍋🍋
 
Joined: 04 Nov 2017

Return to Scripting

Who is online

Users browsing this forum: No registered users and 2 guests