
[NEARLY SOLVED]
OK, I'm working a new solution all together. I think it's better than the Poor Man's Fullscreen (Sorry BadMouth...)
I downloaded a somewhat new script from the Hyperspin forum (link in my initial post) along with a compiled version of the same. The compiled (.exe) works perfectly!!! Game runs in the center of my horizontal monitor. No Windows title/border and a bezel to boot. Awesome!!
So...next I thought all I had to do was edit the AHK file provided as a base for changes to add my own keystroke remaps, recompile and I'd be golden. No so. When I run the newly created executable I get the following error statement:
__________________________________________________
Error: Parameter #1 invalid The current thread will exit
Specifically: GUI1: New
Line #
-----> 013: Gui, GUI1: New, -Caption +ToolWindow +OwnDialogs
__________________________________________________
I changed NOTHING except the keystroke remaps and I got that over and over again. Just for fun I reverted to the original file and compiled that one with NO CHANGES at all. Same error.
So...the compiled .exe file as downloaded works fine, but I can't make any changes to source AHK file without getting errors after running the compiled version of the same.
What am I doing wrong here? I know I'm very close but I just can't figure it out. Any pointers??
Below is the script of the "unaltered" AHK file, which I assume is the same as the provided EXE file (which WORKS)!!
__________________________________________________
size=100 ; Frame Resolution-Only 33,50,100,200 are supported
YAdjust=56 ; adjusts where to place game window from top of screen, negative moves up, positive moves down
XAdjust=35 ; adjusts where to place game window from left side of screen, 0=allthe way to the left
title=ahk_class FOCAL Test Shell
exitkey=Esc
ShowBezel=true
;-------------------------
Hotkey, ~%exitkey%, Close
WinHide ahk_class Shell_TrayWnd
WinHide, ahk_class Button
Gui, GUI1: New, -Caption +ToolWindow +OwnDialogs
Gui, GUI1: Color, Black
Gui, GUI1: Show, x0 y0 h%A_ScreenHeight% w%A_ScreenWidth%
IfInString, ShowBezel, true
{
Gui, Add, Picture, W%A_ScreenWidth% H%A_ScreenHeight%, %a_scriptdir%\bezel.png
;WinSet,AlwaysOnTop, On, fix it felix jr.exe
Gui Show, x0 y0 h%A_ScreenHeight% w%A_ScreenWidth%
WinSet, Style, -0xC00000, fix it felix jr.exe ; Remove border and titlebar
}
Run, FixitFelixJr.exe
WinWait, %title%
WinActivate, %title%
WinMenuSelectItem, %title%,,Zoom,100`%
WinMenuSelectItem, %title%,,Zoom,%size%`%
winHwnd:=WinActive(title)
WinSet,AlwaysOnTop, On, %title%
WinSet, Style, -0xC00000, %title% ; Remove border and titlebar
DllCall("SetMenu", uint, winHwnd, uint, 0) ; Remove the MenuBar
MaximizeWindow(title)
;-----Control Remaps-----
~3::c ;Insert Coin
;~?::1 ;Start Player 1
;~?::2 ;Start Player 2
;?::{Left} ;Move Left
;?::{Right} ;Move Right
;?::{Up} ;Jump Up a Level
;?::{Down} ;Jump Down a Level
;?::x ;Fix-It
;?::{LButton} ;Jump
;?::{Shift} ;Fix-It
;?::{F5} ;save
;?::{F6} ;FrameSkip
;?::{F7} ;ScreenShot
;?::{scrlk} ;lock mouse crosshairs to center of screen
;------------------------
Process, WaitClose, FixitFelixJr.exe
MaximizeWindow(class) {
Global YAdjust
Global XAdjust
WinGetPos, appX, appY, appWidth, appHeight, %class%
widthMaxPercenty := ( A_ScreenWidth / appWidth )
heightMaxPercenty := ( A_ScreenHeight / appHeight )
If ( widthMaxPercenty < heightMaxPercenty )
percentToEnlarge := widthMaxPercenty
Else
percentToEnlarge := heightMaxPercenty
appWidthNew := appWidth * percentToEnlarge
appHeightNew := appHeight * percentToEnlarge
Transform, appX, Round, %appX%
Transform, appY, Round, %appY%
Transform, appWidthNew, Round, %appWidthNew%, 2
Transform, appHeightNew, Round, %appHeightNew%, 2
appXPos := ( A_ScreenWidth / 2 ) - ( appWidthNew / 2 )
appYPos := ( A_ScreenHeight / 2 ) - ( appHeightNew / 2 )
WinMove, %class%,, % (appXPos+XAdjust), % (appYPos+YAdjust), appWidthNew, appHeightNew
}
Close:
WinClose, ahk_class FOCAL Test Shell
WinShow, ahk_class Shell_TrayWnd
WinShow, ahk_class Button
ExitApp
Return
__________________________________________________