B-17 The Mighty Eighth: Cannot Remove Border

Ask gaming related questions (AHK v1.1 and older)
KirkDoug
Posts: 2
Joined: 09 Sep 2021, 10:08

B-17 The Mighty Eighth: Cannot Remove Border

15 Sep 2021, 08:09

Hi, all. I'm new to AHK.

Here's script a YouTuber shared with me, the only change I made was to the path to my game install: I run the script, but the border still shows up.

Code: Select all

Path_B17 := "C:\Program Files (x86)\Microprose\B17"
Sleep 3000
Run, %Path_B17%\Game.exe, %Path_B17%
Sleep, 4000
WinSet, Style, -0xC00000,  B-17 - Some Funny Text
Return
In place of -0xC00000 I've tried using these . . . .

Code: Select all

WinSet, Style, -0xC00000
WinSet, Style, -0x800000
. . . . with the same result.

So, the script launches the game, but does not apply the Style I've set, nor does it change the text that shows up in the caption at the top (I'm assuming that's what
B-17 - Some Funny Text
is supposed to do.) So the script is failing to reach past the Run line?
User avatar
mikeyww
Posts: 26849
Joined: 09 Sep 2014, 18:38

Re: B-17 The Mighty Eighth: Cannot Remove Border

15 Sep 2021, 10:13

The forum already has posts about this. The following may help (I did not test).

https://autohotkey.com/board/topic/84485-removing-borders/

viewtopic.php?t=12968
KirkDoug
Posts: 2
Joined: 09 Sep 2021, 10:08

Re: B-17 The Mighty Eighth: Cannot Remove Border

16 Sep 2021, 21:32

So it seems my changing/ leaving off the Title (?) at the end of this line was the whole cause! I don't even remember why I'd changed it :headwall: ......

Code: Select all

WinSet, Style, -0xC00000, B-17 - The Mighty Eighth
Here's the script in working form:

Code: Select all

Path_B17 := "C:\MicroProse\B17 The Mighty Eighth"
Run, %path_b17%\Game.exe,%path_b17%
Sleep, 2500 ;Any lower than 2500 and the next line wont execute.
WinSet, Style, -0xC00000, B-17 - The Mighty Eighth ;Don't change/ remove this
Return
User avatar
boiler
Posts: 16902
Joined: 21 Dec 2014, 02:44

Re: B-17 The Mighty Eighth: Cannot Remove Border

16 Sep 2021, 22:30

Instead of the Sleep, 2500 line, which is either unreliable or causes your script to wait longer than necessary (or both), you should use:

Code: Select all

WinWait, B-17 - The Mighty Eighth

Return to “Gaming Help (v1)”

Who is online

Users browsing this forum: No registered users and 48 guests