Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - hermine.potter

Pages: [1] 2 3 ... 27
1
General / Re: how to exit model 2 emulator
« on: January 11, 2019, 04:20:28 AM »
I'm using autoit for this.
By pushing SELECT + START + DPAD DOWN + L + R on a snes pad, the process OpenBOR.exe will be closed. (see section OPENBor here)



Source as follows here: ($coord[7] == "240" means the sum of L + R + START + SELECT together / simultaneously pressed (16 + 32 + 128 + 64 = 240 )

(thanks to Ejoc and Adam1213 for original and customized sourcecode and thanks to osrevad for Ascii-Art:

Code: [Select]
; from here :
; https://www.autoitscript.com/forum/topic/10953-joystick-udf/?tab=comments#comment-323294
; original script from POST#1 doesnt works. tooked script from POST#4
;____________________________________________________________________
;       Original program by Ejoc                                    ;
;       Improved by Adam1213 (autoit 3.2 compatiblity + improved labels         ;
;____________________________________________________________________

#include <GUIConstants.au3>
#include <Misc.au3>

;_________________ SETUP_____________________________________
Local $joy,$coor,$h,$s,$msg

$joy    = _JoyInit()

dim $labels_text[8]=['X', 'Y', 'Z', 'R', 'U', 'V', 'POV', 'Buttons']
dim $labels_no=UBound($labels_text)
dim $labels[$labels_no]
dim $labels_value[$labels_no]
;__________ CONFIG ____________________________________________
;---------- Find the max length of the longest label --------------
$label_len=0
for $text in $labels_text
    $len=stringlen($text)
    if $len>$label_len then
        $label_len=$len
    endif
next
$label_len*=6
;_____________ GUI _______________________________________________
;~ GUICreate('Joystick Test', 200, 200)
;~ GUICtrlCreateLabel('Joystick', 40, 20, 100, 20)

;~ for $i=0 to $labels_no-1
;~     GuiCtrlCreatelabel($labels_text[$i]&':', 10, 60+$i*12, $label_len, 12)
;~     $labels[$i]=GuiCtrlCreatelabel('', 10+$label_len, 60+$i*12, 70, 12)
;~     $labels_value[$i]=''
;~ next
;~ GUISetState()
;~ ;_____________________________________________________________________

while 1
    $coord=_GetJoy($joy,0)
    for $i=0 to UBound($coord)-1
        if $coord[$i]<>$labels_value[$i] then
            GUICtrlSetData($labels[$i], $coord[$i])
            $labels_value[$i]=$coord[$i]
        endif
next
sleep(10)

;SNES PAD
;           L __                      | |                        __ R
;               \  ___________________|_|_____________________  /
;              _,-'                                      ____ '-._
;            ,'             S U P E R  N I T E N D O _,-'    `-._ `.
;          ,'       ___     -ENTERTAINMENT SYSTEM- ,'     __ X   `. `.
;         /        |   |                          /      /  \      \  \
;        /      ___|   |___                      /   __  \__/  __ A \  \
;        |     |           |        ,.       ,.  |  /  \      /  \   | !
;        !     |___     ___|      ,','     ,','  |  \__/  __  \__/   | |
;        \         |   |         ','      '.'    \ Y     /  \       /  /
;         \        |___|         SELECT   START   \      \__/      /  /
;          `.                  ___________________ `._  B       _,' ,'
;            `-._          _.'`                   `-._`'~-.,-~'`_.'`
;                `'~-.,-~'`                           `'~-.,-~'`
;
;DPAD
;           U
;          ___
;    UL   |   |    UR
;      ___|   |___
;  L  |           |  R
;     |___     ___|
;    DL   |   |    DR
;         |___|
;           D

;~ ;L
;~ If $coord[7] == "16" Then
;~ msgbox(0, "", "L")

;~ ;R
;~ ElseIf $coord[7] == "32" Then
;~ msgbox(0, "", "R")

;~ ;Y
;~ ElseIf $coord[7] == "4" Then
;~ msgbox(0, "", "Y")

;~ ;X
;~ ElseIf $coord[7] == "8" Then
;~ msgbox(0, "", "X")

;~ ;B
;~ ElseIf $coord[7] == "1" Then
;~ msgbox(0, "", "B")

;~ ;A
;~ ElseIf $coord[7] == "2" Then
;~ msgbox(0, "", "A")

;~ ;START
;~ ElseIf $coord[7] == "64" Then
;~ msgbox(0, "", "START")

;~ ;SELECT
;~ ElseIf $coord[7] == "128" Then
;~ msgbox(0, "", "SELECT")

;~ ; DPAD UP
;~ ElseIf $coord[6] == "0" Then
;~ msgbox(0, "", "U")

;~ ; DPAD UP / RIGHT
;~ ElseIf $coord[6] == "4500" Then
;~ msgbox(0, "", "UR")

;~ ; DPAD RIGHT
;~ ElseIf $coord[6] == "9000" Then
;~ msgbox(0, "", "R")

;~ ; DPAD DOWN / RIGHT
;~ ElseIf $coord[6] == "13500" Then
;~ msgbox(0, "", "DR")

;~ ; DPAD DOWN
;~ ElseIf $coord[6] == "18000" Then
;~ msgbox(0, "", "D")

;~ ; DPAD DOWN / LEFT
;~ ElseIf $coord[6] == "22500" Then
;~ msgbox(0, "", "DL")

;~ ;DPAD LEFT
;~ ElseIf $coord[6] == "27000" Then
;~ msgbox(0, "", "L")

;~ ;DPAD UP / LEFT
;~ ElseIf $coord[6] == "31500" Then
;~ msgbox(0, "", "UL")

;~ ;START + SELECT
;~ ElseIf $coord[7] == "192" Then
;~ msgbox(0, "", "START + SELECT")

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;START + SELECT + L + R + DPAD DOWN
 If $coord[7] == "240" AND $coord[6] = "18000" Then
 ;msgbox(0, "", "EXIT")
ProcessClose("OpenBOR.exe")
Exit
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; END EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

EndIf

$msg =GUIGetMSG()
    if $msg = $GUI_EVENT_CLOSE Then Exitloop
WEnd

$lpJoy=0 ; Joyclose

;======================================
;   _JoyInit()
;======================================
Func _JoyInit()
    Local $joy
    Global $JOYINFOEX_struct    = "dword[13]"

    $joy=DllStructCreate($JOYINFOEX_struct)
    if @error Then Return 0
    DllStructSetData($joy, 1, DllStructGetSize($joy), 1);dwSize = sizeof(struct)
    DllStructSetData($joy, 1, 255, 2)              ;dwFlags = GetAll
    return $joy
EndFunc

;======================================
;   _GetJoy($lpJoy,$iJoy)
;   $lpJoy  Return from _JoyInit()
;   $iJoy   Joystick # 0-15
;   Return  Array containing X-Pos, Y-Pos, Z-Pos, R-Pos, U-Pos, V-Pos,POV
;           Buttons down
;
;           *POV This is a digital game pad, not analog joystick
;           65535   = Not pressed
;           0       = U
;           4500    = UR
;           9000    = R
;           Goes around clockwise increasing 4500 for each position
;======================================
Func _GetJoy($lpJoy,$iJoy)
    Local $coor,$ret

    Dim $coor[8]
    DllCall("Winmm.dll","int","joyGetPosEx", _
            "int",$iJoy, _
            "ptr",DllStructGetPtr($lpJoy))

    if Not @error Then
        $coor[0]    = DllStructGetData($lpJoy,1,3)
        $coor[1]    = DllStructGetData($lpJoy,1,4)
        $coor[2]    = DllStructGetData($lpJoy,1,5)
        $coor[3]    = DllStructGetData($lpJoy,1,6)
        $coor[4]    = DllStructGetData($lpJoy,1,7)
        $coor[5]    = DllStructGetData($lpJoy,1,8)
        $coor[6]    = DllStructGetData($lpJoy,1,11)
        $coor[7]    = DllStructGetData($lpJoy,1,9)
    EndIf


    return $coor
 EndFunc

If you want to edit & customize, see section ;;; EDIT HERE ;;; at line #148:



If you want loop script, simply set Exit to comment:
Code: [Select]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;START + SELECT + L + R + DPAD DOWN
 If $coord[7] == "240" AND $coord[6] = "18000" Then
 ;msgbox(0, "", "EXIT")
ProcessClose("OpenBOR.exe")
;Exit
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; END EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;



If you want to send ALT + F4, if a specific windows is in front / focus (for example Windows Notepad / Editor):
Code: [Select]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;START + SELECT + L + R + DPAD DOWN
 If $coord[7] == "240" AND $coord[6] = "18000" Then
 ;msgbox(0, "", "EXIT")
WinWaitActive("Untitled - Notepad","")
WinWait("Untitled - Notepad","")
Send("!+{F4}",0)
Exit
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; END EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;



If you want to close a collection of emulator systems / more than one application:

create a file called : emulators.txt

fill it with the names of tasks from taskmanager. for example:

vlc.exe
zsnes.exe
scummvm.exe
notepad.exe
calc.exe

Code: [Select]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;START + SELECT + L + R + DPAD DOWN
 If $coord[7] == "240" AND $coord[6] = "18000" Then
;msgbox(0, "", "EXIT")
$file = FileOpen("emulators.txt", 0)
While 1
    Local $line = FileReadLine($file)
    If @error = -1 Then ExitLoop
;   MsgBox(0, "", $line)
ProcessClose ( $line )
WEnd
FileClose($file)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; END EDIT HERE ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

all the enclosed tasks will be closed at the same time

2
General / Re: Attract only works in window mode.
« on: November 29, 2018, 02:26:27 AM »
@ MuZila
same problem here
I think AM-window is keeping in front, your emulator is playing in background.

on my test-system I've got the same problems you describe:
Windows 10 x64 LTSB 1607
AM 2.5.1 (x86; normal and XP-Version)
zsnes emulator + game (I'm hearing the gamesound; no picture; can't switch to emulator with ALT + TAB)

at the moment => i do not know / no solution from me
try version 2.4.0 => report us

3
General / Re: Attract only works in window mode.
« on: November 28, 2018, 10:08:49 PM »
@ MuZila
"no games play" => do you hear the game sound playing, but no pictures is shown?

could you test mame version 0.204 (without setting anything; just copy a game in rom-folder of mame and setup it to AM).

4
General / Re: How to get from Attract Mode back to Emulation Station.
« on: November 19, 2018, 02:46:09 AM »
@ mcmike953

=setup menu / any option
depends on, what you want to configure

>AM itself
in AM : press TAB key

>emulation station
exit AM (so you are on commandline / bash) > type:
Code: [Select]
emulationstation
>RetroPie
exit AM > type:
Code: [Select]
cd RetroPie-Setup/

sudo ./retropie_setup.sh



=AM send me to command prompt
if you exit AM, you will land to bash (commandline) by standard. So that's correct



=Do I turn of power from there?:
it possible in commandline, if you type:
Code: [Select]
sudo poweroff
it's possible to power off automatic, if you exit AM:
start AM > press TAB key > General > Exit Command : sudo poweroff

or by pressing a hardware switch:
Here



=get from AM back to Emulation Station:
start AM > press TAB key > General > Exit Command : emulationstation


5
@ gamesfan
sorry, can't help. I'm not using mameui.
I'm offering you the relevant files (old = before patching ; new = after patching).
Use a tool like winmerge to see which codeline differs / changes and transfer it to mameui sourcecode (it seems similar to mame sourcecode).

6
General / Re: Focus problem using batch for pcsx2
« on: November 08, 2018, 01:15:08 AM »
What happens, if you set the resfix plugin to your emulator-display?
start AM > press TAB key > Plug-ins > ResFix > Enabled : Yes > Specific Emulators : name_of_your_emulator_display

7
General / Re: Joy2Key with Attractmode
« on: November 08, 2018, 12:26:55 AM »
@ dukpoki
Probably it will not close both programs. I do not know surely. This should do it:

See section OpenBOR.
Create an autoit script that kills your emulator and joy2key task (you have to check this information in taskmanager under details).

In AM add a third parameter:
Code: [Select]
executable           cmd
args                 /c start "" "C:\path_to_emulator\your_emulator.exe" & start "" "path_to_joy2key\joy2key.exe" & start "" "path_to_task-kill_skript\task-kill-script.exe"

8
General / Re: Exiting game to AM on arcade machine
« on: November 08, 2018, 12:23:18 AM »
@ goz
start AM > press TAB key > Emulators > choose your emulator-display > choose Exit Hotkey > press your desired buttons simultaneously

9
@ slowsl
setup your games names > close AM > goto your artwork folder > rename artwork to your folder-game-names (so foldername and picturename are identic) > goto AM artwork folder > delete scummvm folder >

start AM > press TAB key > Emulators > choose your scummvm-display > depending on your layout (attrac-man, cools, reflect, verticools, and so on) > set flyer, marquee, snap, wheel to your artwork folder > Exit AM > start AM (and your artwork should be there now)

one offtopic information about scummvm 2.0.0 on windows & latest AM version 2.5.0:
i've added my games via scummvm-menu manually in scummvm.
After adding, setup and configure scummvm display and emulator in AM, correct game names are showed in AM automatic?!
After starting game via AM, a window popups that scummvm searchs your input to scummvm-gameid automatically (only the games, that i've addes manually to scummvm-menu). Nice feature of scummvm team. Thanks ^-^

10
General / Re: Flash Executable Files
« on: November 07, 2018, 10:24:20 PM »
See section windows_games.
If you are able to start the game via commandline, it should work in AM too.

11
@ slowsl
thats right.
See here (Section scumm-vm).
scummvm using own game-id (sq5 for Space Quest 5).
You have to use the own scumm-vm game-id as gamefolder names > create romlist > then edit the second column (title) in romlist (See)

12
General / Re: Official AM icon
« on: November 07, 2018, 01:31:23 AM »
It's the button to start an arcade machine (choosing one player game).
So it's a nice homage to arcade machine ^-^

13
General / Re: Flash Executable Files
« on: November 05, 2018, 12:37:39 AM »

14
General / Re: Joy2Key with Attractmode
« on: November 05, 2018, 12:33:34 AM »
@ moonpatrol
you could create a .bat file containing this:
Code: [Select]
@echo off
start "" "path_to_your_emulator\your_emulator.exe"
start "" "path_to_joy2key\joy2key.exe"

or in AM:
Code: [Select]
executable           cmd
args                 /c start "" "C:\path_to_emulator\your_emulator.exe" & start "" "path_to_joy2key\joy2key.exe"

15
General / Re: American Laser Games Help!
« on: October 25, 2018, 12:30:35 AM »
A little note on using batch files:
If you convert a .bat file with this tool to .exe you are able to suppress the command window / start it invisible.

Pages: [1] 2 3 ... 27