Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Joacim Andersson on Tue 03/12/2024 11:02:26

Title: [RESOLVED] Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 11:02:26
In the Default Setup I have "Start in Windowed Mode" set to false. I compile my program and run the exe file, it runs in a window. I run the Winsetup.exe program, it has the "Fullscreen as borderless window" checked, I click the Save and Run button and my game still opens up in Windowed mode instead of in full-screen.

I've tried to delete everything in the Compiled\Windows folder and rebuild the game with the same result, what am I missing?
Title: Re: Trouble getting my game to run in full screen mode
Post by: eri0o on Tue 03/12/2024 11:05:15
Testing game has the windowed set different, in the Editor Preferences

See https://adventuregamestudio.github.io/ags-manual/EditorPreferences.html#test-game

I believe this was done a long time ago simply because people used to test games as windowed and release them full screen.
Title: Re: Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 11:07:19
I'm not running the game from the editor, but trying to run the compiled exe directly from the File Explorer.
Title: Re: Trouble getting my game to run in full screen mode
Post by: eri0o on Tue 03/12/2024 11:10:50
If you ever used winsetup, it will save the config in the Saved Games dir of your game and those have priority over the default setup.

The AGS games have a command line interface that has --tell flags that can be used to trace what config comes from where but it merges the user config on top of the default setup config and this is what sets the config in summary.
Title: Re: Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 11:13:54
But I've deleted all the files in the Compiled folder and rebuilt it. The winsetup.exe file has the Fullscreen checkbox checked, yet the game starts in Windowed mode.
Title: Re: Trouble getting my game to run in full screen mode
Post by: eri0o on Tue 03/12/2024 11:14:53
https://adventuregamestudio.github.io/ags-manual/EngineConfigFile.html#configuration-file-locations

Here, as I mentioned, if you ever saved it, it's there in the Saved Games dir.

I am confused, you previously said that you set in the Default Setup and now you mentioned it's set in the other place.


Are you using System.Window = true in your code at game_start ?
Title: Re: Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 11:18:11
I understand that. But if I've deleted everything in the Compiled folder, how can it still use a setting that is never saved? Also, the winsetup.exe file doesn't change it.
Title: Re: Trouble getting my game to run in full screen mode
Post by: eri0o on Tue 03/12/2024 11:31:58
It's in other directory, it will be saved if you either changed using winsetup or if you changed using System.Window and then used System.SaveConfigToFile

https://adventuregamestudio.github.io/ags-manual/System.html#systemwindowed
https://adventuregamestudio.github.io/ags-manual/System.html#systemsaveconfigtofile

If it's not any of the above I would suggest running it through command line and logging the engine output to see if it's receiving the right config or not and if it's getting the right config and failing to make it windowed - but I really would need to eliminate all previous possibilities before going down that path.
Title: Re: Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 11:40:45
Aha, I found the acsetup.cfg file in the Shell:SavedGames folder. But if that is the one that is used, why is there a acsetup.cfg file in the Compiled folder, do I need to distribute that file at all?
Title: Re: Trouble getting my game to run in full screen mode
Post by: Crimson Wizard on Tue 03/12/2024 11:42:50
Quote from: Joacim Andersson on Tue 03/12/2024 11:40:45Aha, I found the acsetup.cfg file in the Shell:SavedGames folder. But if that is the one that is used, why is there a acsetup.cfg file in the Compiled folder, do I need to distribute that file at all?

There are 3 config files read by AGS games. Both engine and winsetup programs combine them together, using override rule.
This is explained in this article in the manual:
https://adventuregamestudio.github.io/ags-manual/EngineConfigFile.html

Default Setup in the Editor defines the contents of the config file generated along with the game files.
Winsetup writes the personal user config file.


Quote from: Joacim Andersson on Tue 03/12/2024 11:02:26I compile my program and run the exe file, it runs in a window. I run the Winsetup.exe program, it has the "Fullscreen as borderless window" checked, I click the Save and Run button and my game still opens up in Windowed mode instead of in full-screen.

You may be confusing 2 options: "Start in windowed mode" and "Fullscreen as borderless window".
The second option defines what happens when you run the game in fullscreen: either it is a "real" fullscreen (aka exclusive fullscreen mode) or a borderless window that covers whole desktop.
Title: Re: Trouble getting my game to run in full screen mode
Post by: Joacim Andersson on Tue 03/12/2024 12:09:31
Thank you to both of you, issue solved.