Jump to content
  • Announcement

    The HyperSpin 2 early access beta is here!

    We’re starting the first public testing phase with Platinum Members to keep the scope manageable while we test the current feature set and begin to add more. In the future, we’ll provide a version for basic members as well.  On behalf of the entire HyperSpin team, we look forward to another exciting adventure with our community.

Need help fixing my rotation script with HL3


Griffindodd

Recommended Posts

Posted

I have a script that rotates my monitor via a motor depending if a Mame game is vertical or horizontal.

My Mame module sends the name of the ROM I am launching to my 'Rotation.exe' script with the following command...

Runwait, %emupath%\Rotation.exe "%romName%"

My Rotation.exe script then checks that name against my list of vertical ROMS (Rotation.ini) and then fires the rotation of the monitor accordingly.

;[Rotation.exe]

;
;
#SingleInstance force 

romName = %1%
param := "%romName%"
;reads verticalRoms controlled roms list
IniRead, verticalRoms, %A_ScriptDir%\Rotation.ini, controls, Set2_vertical
;reads state of vertical, horizontal rotation (user added line in "controls.ini")
iniread, state, %a_scriptdir%\Rotation.ini, Controls, PrevState 
ifnotinstring, verticalRoms, %romname%, gosub, horizontalrotation


verticalrotation:
if ( State = "vertical") 
{
exitapp
} 
else if ( State = "horizontal") 
{ 
Run, %COMSPEC% /c "smccmd --resume --speed -1700", ,{enter},hide

iniwrite, vertical, C:\Hyperspin\Emulators\Mame\Rotation.ini, controls, PrevState 
exitapp
}


horizontalrotation:
if ( State = "horizontal" ) 
{
exitapp
} 
else if ( State = "vertical") 
{ 
Run, %COMSPEC% /c "smccmd --resume --speed 1700", ,{enter},hide
iniwrite, horizontal, C:\Hyperspin\Emulators\Mame\Rotation.ini, controls, PrevState 
exitapp
}


Since upgrading to RL and Mame 0.153b my rotation script fires for every ROM not just the vertical ROMs listed in my Rotation.ini

All paths are correct

Posted

Can you post a sampling of this value?

IniRead, verticalRoms, %A_ScriptDir%\Rotation.ini, controls, Set2_vertical

I'd like to see how the names are delimited/separated.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...