Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
supersonicAI
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dmath010
supersonicAI
Commits
029dea67
Commit
029dea67
authored
7 years ago
by
Vicki Pfau
Browse files
Options
Downloads
Patches
Plain Diff
retro: Overload data_path so calling without a hint uses our hint
parent
3d8dfe09
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
retro/__init__.py
+7
-2
7 additions, 2 deletions
retro/__init__.py
with
7 additions
and
2 deletions
retro/__init__.py
+
7
−
2
View file @
029dea67
...
...
@@ -5,7 +5,7 @@ import os
import
json
import
subprocess
import
sys
from
retro._retro
import
Movie
,
RetroEmulator
,
core_path
,
data_path
from
retro._retro
import
Movie
,
RetroEmulator
,
core_path
,
data_path
as
_data_path
ROOT_DIR
=
os
.
path
.
abspath
(
os
.
path
.
dirname
(
os
.
path
.
dirname
(
__file__
)))
RETRO_DATA_PATH
=
os
.
path
.
dirname
(
__file__
)
...
...
@@ -40,6 +40,11 @@ EMU_CORES = {}
EMU_INFO
=
{}
EMU_EXTENSIONS
=
{}
def
data_path
(
hint
=
RETRO_DATA_PATH
):
return
_data_path
(
hint
)
with
open
(
os
.
path
.
join
(
os
.
path
.
dirname
(
__file__
),
'
cores.json
'
))
as
f
:
_coreInfo
=
f
.
read
()
RetroEmulator
.
load_core_info
(
_coreInfo
)
...
...
@@ -58,7 +63,7 @@ def get_game_path(game=""):
"""
Return the path to a given game
'
s directory
"""
return
os
.
path
.
join
(
data_path
(
RETRO_DATA_PATH
),
game
)
return
os
.
path
.
join
(
data_path
(),
game
)
def
get_romfile_path
(
game
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment