Jump to content
LaunchBox Community Forums

shortcut to run game through origin that won't run directly


haniobaid

Recommended Posts

I have 26 games on origin at the moment and origin always drives me nuts. Sometimes it updates and links will start working from origin but not by running the exe directly. Sometimes the other way around. It only happens for some games that origin gets phinicky about. Right now I have 2 games out of 26 that act weird: 1. mass effect 3 (I had to uninstall and reinstall origin just to get it to launch the game) after origin updated. This seems to be a bug related to having several exe files with different names on different versions of the game and origins copy protection as people complain about it on orgin forums all the time. 2. Wing commander 4: This runs from origin without problems. If I run it from the exe shortcut in windows, or from launchbox, or from steam or from the start menu shortcut origin creates, it just brings origin to the foreground and nothing happens. I even tried checking the command path in process explorer when I run it from inside origin and it's just the standard path to the exe file! Solution: Ideally I would like a workaround where we can run a command line origin.exe with some command line options to start a specific origin game (eg. d:\p\origin\origin.exe "D:\p\Origin\games\Wing Commander IV\wc4dvd.exe"), but I haven't had any luck finding out how to do this or if it is possible. I would appreciate any ideas or insight on how to do this.
Link to comment
Share on other sites

Wow. I haven't dealt with Origin too much, but that sucks. I was under the impression that everything "just worked" when you used the game's EXE, but apparently I was wrong. This is very telling: http://gaming.stackexchange.com/questions/179412/are-there-any-command-line-arguments-for-origin Supposedly there's a method to launch games just like Steam. So it sounds like I have some work to do. If I can get at those game IDs somehow, I can build an automatic Origin import just like the Steam import and make it magically work. In the mean time, if you can figure out how to come up with those game IDs (per the above link), you could probably put something like this in the application path field: origin://launchgame/DR:235664700 And in theory, it *should* just work (though I have yet to test this in particular). Keep me updated if you have any luck with this or figure out if the IDs are stored somewhere on the machine, where I can parse them. Thanks, Jason
Link to comment
Share on other sites

Partial success. I found out how to get the code every time without using the website but I don't know how you can recreate the process in code. First I got a program called (process explorer). It's made by sysinternals (long since taken over by microsoft), and can be downloaded here: http://technet.microsoft.com/en-us/sysinternals/bb896653.aspx It's like task manager on steroids. I ran the same game the article you linked provided (wing commander 3) which happens to be one of the orgin games I own. I then opened properties for the games process from (process explorer) and went to the environment tab and lo and behold, two of the properties in the games run environment contain the ID. I then did the same steps for the game I am having trouble running from outside origin (wing commander 4) and found the game ID for that (again from environment tab of process explorer property for the game process). here are the 2 properties. EAConnectionId OFB-EAST:39460 OIG_TELEMETRY_PRODID OFB-EAST:39460 I then setup the URL: origin://launchgame/OFB-EAST:39460 and pasted it into firefox. a popup came up asking me which program to use to open the protocol, origin was one of the items on the list, I selected it and checked the option to do this automatically next time. The game opened. I closed it and tried the url from (windows key + r) and the game opened right away. I then tried the url from launchbox but it didn't work. So I tried to run it as a command line for firefox: command: c:\p\ff\firefox.exe command line parameter: origin://launchgame/OFB-EAST:39460 When I did that in the configuration boxes at the bottom and launched the configuration option from the games right click menu it worked like a charm. when I tried to do that with the main game launch fields. Launchbox asked if I wanted to modify the root folder for the game automatically. I selected no but it would not click ok. It wanted to change the root folder to the firefox path. To avoid that I setup a batch file in (D:\p\Origin\games\Wing Commander IV) with the command: C:\ff\firefox.exe origin://launchgame/OFB-EAST:39460 Now this works like a charm. I doubleclick the game icon in launchbox and it runs. Then I started to try to find if the product id is stored somewhere. I checked the registry. It is not there. I did a text search on all files (binary/text) inside the game folder/subfolders, no match. I did the same on the root origin folder (without subfolders), no match. Maybe it is there but encrypted or origin is storing this stuff somewhere else, or the binary format cannot be text searched. Did some more googling and found origin stores stuff under (C:\ProgramData\Origin). A search of the path shows the game id is referenced in : C:\ProgramData\Origin\Logs\Bootstrapper_Log.txt and C:\ProgramData\Origin\Logs\Client_Log.txt The bootstrapper shows the failed and good launch: good launch (where I ran url through firefox): 0: [Dec 30 02:07:40] Event LogFile: C:\ProgramData\Origin\Logs\Bootstrapper_Log 1: [Dec 30 02:07:40] Event 12/30/14 02:07:40 2: [Dec 30 02:07:40] Event Version: 9.5.3.636 3: [Dec 30 02:07:40] Event "D:\p\Origin\Origin.exe""origin://launchgame/OFB-EAST:39460" 4: [Dec 30 02:07:40] Event Multiple instance detected and didn't restart self failed launch (where I just ran the exe): 0: [Dec 30 02:05:41] Event LogFile: C:\ProgramData\Origin\Logs\Bootstrapper_Log 1: [Dec 30 02:05:41] Event 12/30/14 02:05:41 2: [Dec 30 02:05:41] Event Version: 9.5.3.636 3: [Dec 30 02:05:41] Event "D:\p\Origin\Origin.exe""origin2:\\game\launch\?offerIds=1025194,71112&title=Wing%u0020Commander%u2122%u0020IV%u003a%u0020The%u0020Price%u0020of%u0020Freedom&CommandParams=" 4: [Dec 30 02:05:41] Event Multiple instance detected and didn't restart self Here is the client file log: 595 Dec 30 00:14:06.579 Event Origin::Client::CommandFlow::translateHostLaunchGame 8044 Adding Restart Query Parameter. 596 Dec 30 00:14:06.579 Event Origin::Client::RTPFlow::setPendingLaunch 8044 --------------------- RTP SetPendingLaunch ---- 597 Dec 30 00:14:06.579 Event Origin::Client::RTPFlow::setPendingLaunch 8044 Game Title: Unidentified Game 598 Dec 30 00:14:06.579 Event Origin::Client::RTPFlow::setPendingLaunch 8044 Auto Download: false 599 Dec 30 00:14:06.579 Event Origin::Services::LoggerFilter::DumpCommandLineToLog 8044 RTP Param: 600 Dec 30 00:14:06.579 Event Origin::Client::RTPFlow::attemptGameLaunch 8044 RTP: in AttemptGameLaunch 1 601 Dec 30 00:14:06.579 Event Origin::Client::RTPFlow::attemptGameLaunch 8044 User is logged in 602 Dec 30 00:14:06.580 Event Origin::Client::RTPFlow::attemptGameLaunch 8044 Entitlement found, signal disconnected 603 Dec 30 00:14:06.598 Event Origin::Client::RTPFlow::attemptGameLaunch 8044 RTP: startPlayFlow: OFB-EAST:39460 604 Dec 30 00:14:06.598 Event Origin::Client::PlayFlow::start 8044 started PlayFlow state machine 605 Dec 30 00:14:06.603 Event Origin::Engine::Content::PlayFlow::onLaunchGame 8044 PlayFlow: Launching : OFB-EAST:39460 606 Dec 30 00:14:06.603 Event Origin::Engine::Content::LocalContent::launch 8044 IGO disabled for OFB-EAST:39460 **607 Dec 30 00:14:06.603 Error Origin::Services::ProcessWin::createProcess 8044 Open Path (D:\p\Origin\games\Wing Commander IV\wc4dvd.exe) **608 Dec 30 00:14:06.613 Warning Origin::Services::ProcessWin::createProcess 8044 CreateProcessW(D:\p\Origin\games\Wing Commander IV\wc4dvd.exe) Handle: 7392 bProcSuccess: t LastError: 18 **609 Dec 30 00:14:06.613 Warning Origin::Services::ProcessWin::waitForProcessGroup 9988 Resuming new process main thread. ProcessWin: 0x00000af0 Thread: 0x00000860 610 Dec 30 00:14:06.623 Event Origin::Engine::UpdateController::onPlayStarted 8044 [Origin Autoupdater] Inhibit auto-update due to play start. 611 Dec 30 00:14:06.623 Event Origin::Engine::UpdateController::setUpdateInhibitFlag 8044 [Origin Autoupdater] Inhibit auto-updating. 612 Dec 30 00:14:06.624 Event Origin::Downloader::DownloadService::SetDownloadUtilization 8044 [Download Service] SetDownloadUtilization value: 0 Effective utilization: 0 613 Dec 30 00:14:06.624 Event Origin::Engine::Content::PlayFlow::onLaunchResult 8044 PlayFlow: launch result: true 614 Dec 30 00:14:06.625 Event Origin::Client::PlayFlow::onGameLaunched 8044 PlayFlow::onGameLaunched: [OFB-EAST:39460] - result:0 615 Dec 30 00:14:09.623 Event SetPresenceMessageHandler::OnMessage 400 Jingle setting activity to Wing Commanderâ„¢ IV: The Price of Freedom;OFB-EAST:39460;INGAME;;; This URL (http://vikingco.de/pinorigin/) suggests there is a way to monitor the launch of origin.exe by monitoring the https requests using fiddler and found that all the game IDs are part of a request called (entitlements). Apparently origin doesn't make its db details public like steam and last year some people demonstrated the origin url mechanism can be used to take control of a machine by adding a dll to the launch url and making a user click the link I hope this helps. The workaround is fine for me since at the moment this is an exceptional case that only affects a limited number of games.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...