Where is it better to place the general logic of the game as a program?

Hello! I have the logic of setting the fullscreen mode. Is it better to put this in GameMode or Game Instance?

GameMode

GameInstance

Not sure, but I think that GameInstance is more global thing, while GameMode can be set differently for deifferent levels. Also I have seen several times that it is very handy to use GameInstance as Singletone.

Game instance, or game state. They are both perpetual.

Both Game Mode and Game Instance will allow you to store and persist data of your game, however data in Game Mode will not be persistent across levels, this means when you level is unloaded data collected by the game mode will be destroyed, additionaly you might have multiple Game Modes and
not necessarily you will use the same Game Mode in the next level. Game Instance is created once per application and destroyed at the end, if you need your data to be persistance across multiple levels then use Game Instance.

“Game Mode” depends on your level so you can have more than 1 Game Mode!
so better to use in “Game Instance”