[INFO] How To Open Replay Links

Discussion in 'Videos And Replays!' started by cptconundrum, May 1, 2014.

  1. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    This should work again
    brianpurkiss likes this.
  2. brianpurkiss

    brianpurkiss Post Master General

    Messages:
    7,879
    Likes Received:
    7,438
    It's working!

    Thanks for the quick fix.

    You rock.
  3. brianpurkiss

    brianpurkiss Post Master General

    Messages:
    7,879
    Likes Received:
    7,438
    Got another report for ya, it's a minor thing, but just fyi.

    If I have PA open and click on a link to open a replay, the replay link doesn't work. I have to quit PA and then open the replay link.
  4. cptconundrum

    cptconundrum Post Master General

    Messages:
    4,186
    Likes Received:
    4,900
    If that can be fixed at all, you'll need to talk to the author of the app that makes this work on Macs.
    https://github.com/pamods/pastats-macos-replaylinks-handler

    Everything works fine on windows but what happens is the Mac app is trying to switch to the already running program instead of start it again. PA Stats can only process the data when it is sent to PA on startup.
  5. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    I doubt that can be fixed, the expected behavior is that clicking a link starts a new instance of PA. Switching or the like cannot work. Anyway as Conundrum pointed out that is not an issue of the mod, but of the mac specific launching mechanism.
  6. feyder

    feyder Member

    Messages:
    88
    Likes Received:
    13
    Any known issues with crashing on replay start? It downloads and makes the siren and then crashes every time on all replays I have tried.
  7. Quitch

    Quitch Post Master General

    Messages:
    5,850
    Likes Received:
    6,045
    For those of you who want to launch replays and still have your Steam overlay (and the ability to take screenshots for upload to Steam) follow the steps in the OP, but use this code instead.

    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CLASSES_ROOT\Wow6432Node\startpa]
    @=""
    "URL Protocol"=""
    
    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell]
    
    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell\open]
    
    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell\open\command]
    @="C:\\Program Files (x86)\\Steam\\Steam.exe -applaunch 233250 --uioptions \"%1\""
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa]
    @=""
    "URL Protocol"=""
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell]
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell\open]
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell\open\command]
    @="C:\\Program Files (x86)\\Steam\\Steam.exe -applaunch 233250 --uioptions \"%1\""
    Last edited by a moderator: September 1, 2014
    huangth likes this.
  8. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    I updated the registry entries to use --uioptions, which is now the recommened way to do this. The old way now results in the replay link ending up as your username in the login form.

    A new version of PA Stats that handles this correctly in the new build will be out pretty soon.
    cptconundrum, proeleert and Quitch like this.
  9. toast2218

    toast2218 New Member

    Messages:
    4
    Likes Received:
    0
    Im able to click the link and it will launch PA but after I log in nothing happens
  10. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Can you lookup the whole command line that PA is started with in the taskmanager?
  11. toast2218

    toast2218 New Member

    Messages:
    4
    Likes Received:
    0
    How would i do that?
  12. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Open the taskmanager, add the column for the command line and make a screenshot of it. Like this.
    Note that my windows is german, I dunno the exact english wordings.

    [​IMG]

    The red marked word is german for commandline, that's the column you are looking for.
  13. toast2218

    toast2218 New Member

    Messages:
    4
    Likes Received:
    0
  14. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    Did you maybe delete the part --uioptions from the registry file when you added your PA path?
  15. toast2218

    toast2218 New Member

    Messages:
    4
    Likes Received:
    0
    thats possible, ill try again quick and give you the results

    Edit, nope did not work. still logging in and then nothing here is my pastats.reg text

    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\Wow6432Node\startpa]
    @=""
    "URL Protocol"=""

    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell]

    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell\open]

    [HKEY_CLASSES_ROOT\Wow6432Node\startpa\shell\open\command]
    @="C:\\Program Files (x86)\\Steam\\SteamApps\\common\\Planetary Annihilation\\PA.exe --uioptions \"%1\""

    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa]
    @=""
    "URL Protocol"=""

    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell]

    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell\open]

    [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\startpa\shell\open\command]
    @="C:\\Program Files (x86)\\Steam\\SteamApps\\common\\Planetary Annihilation\\PA.exe --uioptions \"%1\""

    EDIT 2
    It worked on g chrome, i guess i just cant use firefox to do it.
    Last edited: September 4, 2014
  16. zgrssd

    zgrssd Active Member

    Messages:
    658
    Likes Received:
    185
    I think nobody ever explained how that setup works on windows.

    Windows can start a programm on user action in two cases:
    1. A specific file type is double clicked - the programm is associated to a filetypes default operation (most often "open"). You know this when you open .doc, .xls, .txt, .pdf and similar files.
    2. A link with a specific protocoll is being followed - the programm is assigned to a specific protocoll.

    Steam uses that for the game links on your desktop (they are considereded weblinks, not the normal programm links programms normally make):
    steam://rungameid/233250
    gog.com downloader and several other platform dependant download manager uses the same trick.
    It is the reason you can set up a different programm to open local html files (.html) while still being able to follow weblinks (http: and https: ).

    What you are doing is assigning the pa.exe as the programm to run links with the protocoll "startpa" - giving it the replay ID as one of the command line parameters.
    startpa://replay=13805715308086225097

    Here is a detailed explanation:
    http://msdn.microsoft.com/en-us/library/ie/aa767914.aspx
    Last edited: September 13, 2014
  17. zgrssd

    zgrssd Active Member

    Messages:
    658
    Likes Received:
    185
    I got it working in firefox, using the following regedit file. I got the data from the firefox page:
    http://kb.mozillazine.org/Register_protocol

    It also has guidelines on setting them up for mac and linux.

    My guess is that FF is looking only for entries that have a shell and shell\open subkey. (Those were in the example regedit file despite being empty in there).
    This is propably owed to FF having a protocol selection/confirmation dialog being closer to the default programm selection of Windows 8.

    Here is my regedit file (path cut out):
    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CLASSES_ROOT\startpa]
    @="URL:startpa protocoll"
    "URL Protocol"=""
    
    [HKEY_CLASSES_ROOT\startpa\shell]
    
    [HKEY_CLASSES_ROOT\startpa\shell\open]
    
    [HKEY_CLASSES_ROOT\startpa\shell\open\command]
    @="\"[path to pa binx64 folder]\\pa.exe\" --uioptions \"%1\""
  18. tatsujb

    tatsujb Post Master General

    Messages:
    12,902
    Likes Received:
    5,385
    @cola_colin :( no worky for me.

    upload_2014-11-13_20-36-58.png

    then upon clicking the link this shows for a second :
    ds.jpg but i couldn't even see what it says I only got to catch it because of a timely screen capture. it really only shows for a split second.
    then this :
    upload_2014-11-13_20-41-42.png
    so I cannot set a "open with"
  19. cola_colin

    cola_colin Moderator Alumni

    Messages:
    12,074
    Likes Received:
    16,221
    firefox sucks, chrome keep displaying the page with the replay info. A properly configured firefox should at least open PA though. Dunno. Never tried to use firefox for it and never tried to do it on linux. No idea.
  20. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Wow, yeah, Firefox seriously broke custom protocols in one of their updates. I've tried many different ways with about:config, but none worked. I even tried editing the mimeTypes.rdf file directly, but still nothing. It just won't display the "open with" dialog.
    tatsujb likes this.

Share This Page