mirror of
https://github.com/derrod/legendary.git
synced 2024-12-22 17:55:27 +00:00
[core] Properly construct Origin launch URI
This commit is contained in:
parent
74bc2fecc0
commit
0bc543518c
|
@ -15,7 +15,7 @@ from requests import session
|
||||||
from requests.exceptions import HTTPError
|
from requests.exceptions import HTTPError
|
||||||
from typing import List, Dict
|
from typing import List, Dict
|
||||||
from uuid import uuid4
|
from uuid import uuid4
|
||||||
from urllib.parse import urlencode
|
from urllib.parse import urlencode, parse_qsl
|
||||||
|
|
||||||
from legendary import __version__
|
from legendary import __version__
|
||||||
from legendary.api.egs import EPCAPI
|
from legendary.api.egs import EPCAPI
|
||||||
|
@ -595,11 +595,13 @@ class LegendaryCore:
|
||||||
('epicusername', user_name),
|
('epicusername', user_name),
|
||||||
('epicuserid', account_id),
|
('epicuserid', account_id),
|
||||||
('epiclocale', self.language_code),
|
('epiclocale', self.language_code),
|
||||||
('theme', 'sws'),
|
|
||||||
('platform', 'epic'),
|
|
||||||
('Hotfix', 'go')
|
|
||||||
]
|
]
|
||||||
|
|
||||||
|
game = self.get_game(app_name)
|
||||||
|
extra_args = game.metadata.get('customAttributes', {}).get('AdditionalCommandline', {}).get('value')
|
||||||
|
if extra_args:
|
||||||
|
parameters.extend(parse_qsl(extra_args))
|
||||||
|
|
||||||
return f'link2ea://launchgame/{app_name}?{urlencode(parameters)}'
|
return f'link2ea://launchgame/{app_name}?{urlencode(parameters)}'
|
||||||
|
|
||||||
def get_save_games(self, app_name: str = ''):
|
def get_save_games(self, app_name: str = ''):
|
||||||
|
|
Loading…
Reference in a new issue