A very clear and succinct answer if ever I saw one...(thank you for that) Strangely enough, it turns out those 2 variables are coming up differently on my system (1440 for ctypes... and 1152 for g_y_physical_screen both taken after the program is up and running)Why am I annoyed? I am not annyoed, nor did I act annoyed.
The problem is that everyone seems to think he/she knows something and is mixing everything up, stuff that has absolutely nothing to do with one another.
This is what my preferences screen looks like. You see there are the options to use 1920x1080.
View attachment 487652
I know what I coded and I'm pretty sure it is working for the huge majority, or we would see a lot more complaints, because one thing is for sure in this forum - if something even a tiny little something is not working, there will be complaints.
This is the code that is executed when the game starts:
And this is the code that defines the preferences:Python:init -5 python: from time import time import datetime import os if os.name == "nt": import ctypes g_user32 = ctypes.windll.user32 g_y_physical_screen = g_user32.GetSystemMetrics(1) else: g_y_physical_screen = 1200
So if you get 1440 when you manually execute the command after the game has been loaded, maybe it starts on your secondary screen which has lower settings?Python:if not renpy.loadable("use_fixed_resolution_720.txt"): vbox: style_prefix "check" label _("Resolution") textbutton _("manual resize") action SetField(persistent, 'resolution', 1000) textbutton _("1280x720") action SetField(persistent, 'resolution', 1280) textbutton _("1600x900") action SetField(persistent, 'resolution', 1600) if g_y_physical_screen >= 1200: textbutton _("1920x1080") action SetField(persistent, 'resolution', 1920) if g_y_physical_screen >= 1600: textbutton _("2560x1440") action SetField(persistent, 'resolution', 2560)
Please check the variable g_y_physical_screen in the console.
Just type:
g_y_physical_screen
If you also get 1440 then I have no idea why it doesn't work. But probably you get 1080 or lower.
I only use one screen, so I cannot really test this.
If g_y_physical_screen is not 1440, you can try this:
Open the console and type:
g_y_physical_screen = 1440
After that, go to the preferences. You should see the additonal option 1920x1080 now.
If for whatever reason windows returns the resolution from the wrong monitor when the game starts, I'm pretty sure something can be found to work around that. But I wasn't aware of that problem.
EDIT: If you have the problem that higher resolutions are not available, please try the files attached in the zip. Copy them to the "game" folder and replace the two existing files. The logic has been changed, so that every time the preferences are opened, the game will again get the native resolution of your screen (instead of only once when the game is started). Please let me know if this works for you.
will try the zip files and let you know if anything changes.
Edit: I believe that got it, as now the 1080 option is available (exactly as it is intended based on the logic of the code above)
(strangely enough, the values do not change in the console for ctypes and g_y_physical_screen ... would seem to be an issue with multiple monitors with differing native resolutions on my end imho.)
Still ... many thanks for looking into this.
Last edited: