-
Notifications
You must be signed in to change notification settings - Fork 2
Hiding Game Window Borders In Wine
The simplest way: modifying the window properties with autoit3:
#include <WinAPI.au3>
#include <WindowsConstants.au3>
$handle = WinGetHandle("GTA2")
consolewrite("handle: " & $handle & @crlf)
_WinAPI_SetWindowLong($handle, $GWL_STYLE, $WS_POPUP)
Result: Window doesn't react anymore in wine!
Tried to change the dwStyle
in CreateWindowEx
and similar functions (AdjustWindowEx
) in GTA2.exe
and dmavideo_original.dll
. Result is that they don't affect the ingame-window at all (probably the network dialogs, but not sure how useful modifying them would be). Some hacking with ollydbg showed, that the CreateWindowEx function gets called from wined3d.dll. Shipping a custom wine-dll-file isn't really that good.
Third approach would be: change the wine theme, so it doesn't display borders (G2HR will run in its own wine prefix anyway). Scratch that, modifying the registry might be enough:
[HKCU/Control Panel/Desktop/WindowMetrics]
CaptionHeight=0
CaptionWidth=0
BorderWidth=0
...
It doesn't get smaller than a minimum size :/
Drawing black borders with AutoIt3 over the window frames (as popup-windows). This will always work, and could be combined with C to make the borders smaller. Maybe we should just go with that, seems to be the most portable solution.
patches and wiki edits welcome!
- HACKING
- Beginner's Guide to the AutoIt3 Code
- Code Structure
- Development-Setup
- Startup
- Hiding-Game-Window-Borders-In-Wine
- Rumble
- Displaying-ingame-text
- Menu
- Related-GTA2-Projects-and-Resources
- Save-Games
- Linux-(Wine)
- G2HR-Windows-Installer (this is probably not worth it, fix the other bugs first!)