1. If you're looking for help-related things (for example, the key rebinding tutorial), please check the FAQ and Q&A forum! A lot of the stickies from this forum have been moved there to clean up space.
    Dismiss Notice

Why does Starbound minimize when focus is lost on the game window if Borderless Window is checked?

Discussion in 'Starbound Discussion' started by Soxxx, Jul 23, 2017.

  1. Soxxx

    Soxxx Space Hobo

    Why does Starbound minimize when focus is lost on the game window if Borderless Window is checked? I don't know, but seeing as how this has been an issue since 2013, I am only left to assume there will never be a true Borderless Window mode for this game. So I've gone ahead and made a band aid fix using AutoHotKey scripting.

    There are a few things to keep in mind before you run the code:

    1. AutoHotKey must be installed on your PC to use the script fix. If you're unfamiliar with AHK you can check out their site at https://autohotkey.com I will NOT make an .exe so don't ask. If someone offers you a .exe file, I would NOT recommend running it, stick to the script because you can read the code before you run the script.

    2. In the video option make sure Borderless Window AND Fullscreen are NOT checked.

    3. The game must be running before you run the script. Minimized, Maximized, or in a custom sized window, it matters not.

    4. That's about it. Enjoy!

    You can download the script file or just copy & paste the code into your own AHK file.


    Here's the code:

    #Persistent
    #SingleInstance Force
    WinGet, SB_BWFixer, Style, Starbound, , ,
    If (SB_BWFixer & +0xC00000)
    { WinRestore, Starbound, , ,
    Sleep, 200
    WinRestore, Starbound, , ,
    WinSet, Style, -0xC00000, Starbound
    WinMove, Starbound, , 0, 0, , ,
    WinMaximize, Starbound, , ,
    } ExitApp
     

    Attached Files:

    Last edited: Jul 23, 2017
  2. RossTarZ

    RossTarZ Void-Bound Voyager

    I tried out your code, it didn't work at first, then I changed 'Starbound' to 'A' so it would do it to the focused window and also deleted the 3rd and 4th row.
    It worked. Once.
    I tried the command WinGetTitle which returned that the name of the window is indeed Starbound.
    After that I wanted to tweak it more, I don't know what happened but I've been unable to make it work again. It works with other programs.
    Not sure what to do.

    Anyways thanks for the code. I haven't found any other solution without installing software for borderless windows.
     

Share This Page