Jump to content

[Guide] Gambler Challenge #8 - Automated Remote Play Method


HusKy

Recommended Posts

  • 3 months later...
On 2018. 12. 12. at 0:56 AM, leandrorhcp said:

I meant on the script, changed "PS4 Remote Play" to "Uso a distancia de PS4", should work in any other languages I believe.

 

I guess it is not working in any languages sorrowfully :(

 

With this method I should change the script to "PS4 távoli játék"  and the "á" and the "é" letters are messing it up, making it unavailable for me-

Link to comment
Share on other sites

21 minutes ago, yawran said:

 

I guess it is not working in any languages sorrowfully :(

 

With this method I should change the script to "PS4 távoli játék"  and the "á" and the "é" letters are messing it up, making it unavailable for me-

 

Try to replace these 2 lines:

 

    ControlSend, , {Enter down}, PS4 Remote Play
    ControlSend, , {Enter up}, PS4 Remote Play

 

With:

 

    ControlSend, , {Enter down}, ahk_exe RemotePlay.exe
    ControlSend, , {Enter up}, ahk_exe RemotePlay.exe

 

This should work but I have not tested it.

 

edit. If this does not work, then you might be able to change window title with some specialized tool, e.g. https://www.murgee.com/window-title-changer/

I have not tested this either, just listing some options here.

Edited by HusKy
  • Like 1
Link to comment
Share on other sites

12 minutes ago, HusKy said:

 

Try to replace these 2 lines:

 

    ControlSend, , {Enter down}, PS4 Remote Play
    ControlSend, , {Enter up}, PS4 Remote Play

 

With:

 

    ControlSend, , {Enter down}, ahk_exe RemotePlay.exe
    ControlSend, , {Enter up}, ahk_exe RemotePlay.exe

 

This should work but I have not tested it.

It works now, thank you very much!!  I already loved you for the Compendium script <3<3

I guess the script should be updated for this one as far as this works in any language.

Link to comment
Share on other sites

  • 4 months later...
On 16/10/2020 at 2:42 AM, PaleVoyager said:

This no longer works.  PS Remote Play app has changed and no longer responds to scripts.

 

I will have to test it out more, but from my quick testing, Enter key still acts as :cross: and Escape key is still :circle:.

Link to comment
Share on other sites

1 hour ago, SovereignsFall said:

I can also confirm this seems to no longer be working with Remote Play. Hitting control+B does nothing.

 

The script needs to be updated and I don't have access to Remote Play on Windows PC right now.

 

What's the name of the process? Previously it was "RemotePlay.exe". The only line that needs to be changed (twice) in the script is this:

ahk_exe RemotePlay.exe

 

Link to comment
Share on other sites

I went ahead and updated the script. It works once again.

 

However, I couldn't figure out why "ControlSend" command does not work properly so I had to use "Send" command which requires PS Remote Play to be the active window. Let me know if you figure out how to target PS Remote Play with ControlSend command.

Link to comment
Share on other sites

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
#MaxThreadsPerHotkey 2
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
DetectHiddenWindows, On

Gui, -MaximizeBox
Gui, -MinimizeBox
Gui, Add, Button, default, Start
Gui, Show,w150 h80, Generic X presser
return

Toggle := True
^b::
Toggle := !Toggle
ButtonStart:

SetKeyDelay, 200
WinGet, remotePlay_id, List, ahk_exe RemotePlay.exe
if (remotePlay_id = 0)
{
	MsgBox, PS Remote Play not found
	return
}
Loop, %remotePlay_id%
{
  id := remotePlay_id%A_Index%
  WinGetTitle, title, % "ahk_id " id
  If InStr(title, "PS")
    break
}	
WinGetClass, remotePlay_class, ahk_id %id%
WinMove, ahk_id %id%,, 0, 0, 400, 200
ControlFocus,, ahk_class %remotePlay_class%
WinActivate, ahk_id %id%

Loop
{
	If not Toggle
		break
	ControlSend,, {Enter down},  ahk_id %id%
    Sleep 20
    ControlSend,, {Enter up},  ahk_id %id%
    Sleep, 1000
}
return

PauseLoop:
  ControlSend,, {Enter up},  ahk_id %id%
  return

GuiClose:
gosub PauseLoop
^k::ExitApp

Let me know if this works for you, I tried making it simple, still can use ctrl+b to run and you can close GUI for same result.

Edited by Septomor
Link to comment
Share on other sites

On 27. 10. 2020 at 4:47 AM, Septomor said:

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
#MaxThreadsPerHotkey 2
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
DetectHiddenWindows, On

Gui, -MaximizeBox
Gui, -MinimizeBox
Gui, Add, Button, default, Start
Gui, Show,w150 h80, Generic X presser
return

Toggle := True
^b::
Toggle := !Toggle
ButtonStart:

SetKeyDelay, 200
WinGet, remotePlay_id, List, ahk_exe RemotePlay.exe
if (remotePlay_id = 0)
{
	MsgBox, PS Remote Play not found
	return
}
Loop, %remotePlay_id%
{
  id := remotePlay_id%A_Index%
  WinGetTitle, title, % "ahk_id " id
  If InStr(title, "PS")
    break
}	
WinGetClass, remotePlay_class, ahk_id %id%
WinMove, ahk_id %id%,, 0, 0, 400, 200
ControlFocus,, ahk_class %remotePlay_class%
WinActivate, ahk_id %id%

Loop
{
	If not Toggle
		break
	ControlSend,, {Enter down},  ahk_id %id%
    Sleep 20
    ControlSend,, {Enter up},  ahk_id %id%
    Sleep, 1000
}
return

PauseLoop:
  ControlSend,, {Enter up},  ahk_id %id%
  return

GuiClose:
gosub PauseLoop
^k::ExitApp

Let me know if this works for you, I tried making it simple, still can use ctrl+b to run and you can close GUI for same result.

 

Thanks, I will test it out!

 

I have to say, I really hate using the custom language AHK is using.

Link to comment
Share on other sites

  • 1 month later...
37 minutes ago, Snowy1192 said:

I would be keen to use this but am on Mac unfortunately. If I ran it through a Mac based program would the code be same or would I need to edit it?

 

Just find something for Mac that simulates keyboard presses and use that. However, this particular script only works with AHK.

Link to comment
Share on other sites

  • 2 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...