Alt + Enter crashes on dual monitor setup

Find quick help here to get you started with Hollywood
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

Here is small amount of code that already fails:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", ScaleMode = #SCALEMODE_AUTO, FitScale = True, Sizeable=True, borderless=True, smoothscale=True}

TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK RIGHT MOUSE")
WaitRightMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
There is one guy who is getting this problem and is willing to help currently, so I am able to get some more info about this.

I guess we can confirm now with this small piece of code that it is Hollywood problem and not in my code.
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

Some new info from that one helping, take into consideration that I am not sure always of his answers, so I might be giving slightly erroneous data to you here. But..


First of all, this FIRST one fails:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", Mode="ask", monitor=1, Sizeable=True, ScaleMode = #SCALEMODE_AUTO, Fitscale=True, borderless=True}

This SECOND one seems to work otherwise, except that it doesn't show on taskbar:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", Mode="ask", monitor=1}
Also, Adding any of these alone to that one works:
Sizeable=True
ScaleMode = #SCALEMODE_AUTO
Fitscale=True
borderless=True




Making it seem like it is a conflict with two or more of these at the same time making the bug happen.

He commented that this THIRD one didn't work:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", Mode="ask", monitor=1, Sizeable=True, ScaleMode = #SCALEMODE_AUTO, Fitscale=True}}
Here is what he commented about choosing different responses to the "ask" part of the THIRD one:
fullscreen - causes a black screen, game is unresponsive and one full thread usage, can't even close it with "esc", killing it takes a little while (in general very bad),

windowed - game starts, shows on taskbar, but is again invisible, gotta do the "shift, windows" trick,

resolution - same results as fullscreen

However, I am not sure what did he mean exactly by this, since he didn't say if the ask part showed normally or not, since to my understanding even the ask part is hidden. Going to ask this.


And while he didn't say it directly, I assume he meant that this FOURTH one did work still:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", Mode="ask", monitor=1, Sizeable=True, ScaleMode = #SCALEMODE_AUTO}
Which would mean that adding Fitscale is the point when it failed, and would therefore be colliding with one of the others in this.
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

This one works almost:

Code: Select all

@DISPLAY {Width=1920, Height=1080, ScaleWidth=#NATIVE, ScaleHeight=#NATIVE, KeepProportions=True, Title = "AI Kills All Humans", Mode="ask", monitor=1, Sizeable=True, ScaleMode = #SCALEMODE_AUTO, borderless=True, smoothscale=True}
here the reply:
"app runs, is bigger than the screen"

Using #NATIVE instead of 1920 and 1080 results in same bigger than screen problem, and:
"works, displays game, but is extremely chuggy when starting and closing the game. The chugginess doesn't occur on windowed"

And using 100 percent instead of 1920 and 1080, also results in the same bigger than screen problem, and:
"works, displays game, not chuggy"

I wonder if problem is with scale getting wrong numbers or something with dual monitor setups.
User avatar
airsoftsoftwair
Posts: 5594
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Alt + Enter crashes on dual monitor setup

Post by airsoftsoftwair »

Bugala wrote: Sat Aug 03, 2024 10:50 am Here is small amount of code that already fails:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", ScaleMode = #SCALEMODE_AUTO, FitScale = True, Sizeable=True, borderless=True, smoothscale=True}

TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK RIGHT MOUSE")
WaitRightMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
Can you provide some more information on what you mean by "fails"? What exactly happens when running this code?
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

airsoftsoftwair wrote: Tue Aug 13, 2024 9:43 pm
Bugala wrote: Sat Aug 03, 2024 10:50 am Here is small amount of code that already fails:

Code: Select all

@DISPLAY {Width=1920, Height=1080, Title = "AI Kills All Humans", ScaleMode = #SCALEMODE_AUTO, FitScale = True, Sizeable=True, borderless=True, smoothscale=True}

TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK RIGHT MOUSE")
WaitRightMouse()
Cls()
TextOut(#CENTER, #CENTER, "CLICK LEFT MOUSE")
WaitLeftMouse()
Can you provide some more information on what you mean by "fails"? What exactly happens when running this code?
There are two problems happening with dual monitor setups, but I am not sure which one happens in this specific case.

When starting the program

1. Screen shows all black
2. Program shows nothing at all, but it can be found in apps (not sure what that means)

I suppose, this streamer here: https://www.twitch.tv/grasshyren/video/2213329910 is playing a version of my game with this specific line, and he is getting the problem number 2.

If using mode="ask" instead of mode="windowed", then when starting the program, it will show the screen options selector, but after the user chooses the display option, then one of these before mentioned two problems happen.

Problem can be fixed by using ALT + F4 (in case of Black Screen) or Windows + Shift + Right (Program not displaying at all. It appears it is displayed on non-existing monitor, This is what streamer comments on the before mentioned video)
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

Here is also a youtube link to the same video. He is encountering the problem already in the first minute of this video: https://www.youtube.com/watch?v=OBa8SOwxe9M

Point is that when he clicks on steam that "play"-button, it is same as double clicking the hollywood.exe file.
As you can see, nothing seemingly happens there.

At this point (1:54) https://youtu.be/OBa8SOwxe9M?si=LAI37lRCWtlP8hdj&t=114

you can see how he is still able to turn it off, which means it is on somewhere, and he also comments that nothing popped up.

At this moment I luckily noticed his stream started and came to ask him if he had two monitors, which he affirmed, and I gave him the fix, and at 2:20 he commented it went to a non-existing third monitor.

at 2:40 he comments more about that it launched on a non-existing third monitor and comments some other things too on that, he ends commenting about the issue for first time bit after 3 minutes, so basically check the first 3 and half minutes of that video to see the first part of commenting.

Then at around 5:20 https://youtu.be/OBa8SOwxe9M?si=n8B2LHlIPlr5HJ-l&t=323
he starts commenting again and he says he had the same problem with Unity and gives some more details about it, It's worth a look for you, he comments for less than a minute about it.

so in total you have roughly 4 minutes to watch.
User avatar
airsoftsoftwair
Posts: 5594
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Alt + Enter crashes on dual monitor setup

Post by airsoftsoftwair »

So I've hooked up a second monitor to a Windows 10 system but I can't really reproduce any of the issues described in this thread. Furthermore, this remark caught my attention:
he starts commenting again and he says he had the same problem with Unity and gives some more details about it, It's worth a look for you, he comments for less than a minute about it
If he has the same problem with Unity, then it's really really likely that this is a problem with his system or some faulty drivers or configuration or whatever. I mean Unity is a multi-billion dollar enterprise with hundreds of programmers working on the engine. It's highly unlikely that Hollywood and Unity both should have the same "bug" and since neither you nor me can reproduce the issue, I think it's very unlikely to be a Hollywood bug.

Nevertheless, you really shouldn't use Mode="Ask" with @DISPLAY on a modern system. This is really an ancient feature mostly designed for Amiga systems where fullscreen mode comes cheapest by switching the physical monitor resolution. On modern Windows or macOS systems this is typically no longer done. Instead, the GPU is used to scale the graphics to fullscreen. So your best bet for putting your game in fullscreen mode is probably this:

Code: Select all

@DISPLAY {Mode = "AutoFullScreen"}
This will try to use the best fullscreen mode for host system. On systems that don't support upscaling via the GPU it will do a physical monitor resolution switch, on more modern systems it will switch to fullscreen via GPU scaling.
Bugala
Posts: 1221
Joined: Sun Feb 14, 2010 7:11 pm

Re: Alt + Enter crashes on dual monitor setup

Post by Bugala »

Thanks, will try that AutoFullScreen option and send it for that guy to test to see what happens.

And to clarify a bit.

I am not able to reproduce the issue either.

However, There were roughly 10 streamers who tried the game, and I would say probably at least half of them encountered this issue.

The point with not knowing exact amount of how many of them encountered the issue is because I sent almost all of them a message in advance warning about the issue, so some of them didn't comment anything about it. But from recalling watching them, I think that about half of them either were having that trouble live, like that example one I sent you, and some of them while not showing the trouble, commented about it in way of "good the dev sent instructions on how to fix the black screen bug", meaning they had encountered it but had got past it with the alt + f4 or windows + shift + right, and hence the bug was not shown in the stream, even they had encountered it. So whether it is Hollywood, or their own doing trouble, it is then something that lots of dual monitor setup owners do, and which also might explain why neither you or me encountered it, since we are just using dual monitors in vanilla mode. For I don't normally use dual monitor, and only attached another monitor to test if I could trigger the problem. Also, I did that on two different computers even, and neither gave the problem.
Post Reply