mirror of
https://github.com/moraroy/NonSteamLaunchers-On-Steam-Deck.git
synced 2025-02-08 14:33:24 +01:00
Update NSLGameScanner.py
This commit is contained in:
parent
148e0cb9bb
commit
2f200aefb6
@ -1329,20 +1329,25 @@ else:
|
||||
# List to store final Itch.io game details
|
||||
itchgames = []
|
||||
|
||||
# Match game_id between 'caves' and 'games' tables and collect relevant game details
|
||||
# Match game_id between 'caves' and 'games' tables
|
||||
itchgames = []
|
||||
for cave in caves:
|
||||
game_id = cave[1]
|
||||
if game_id in games_dict:
|
||||
game_info = games_dict[game_id]
|
||||
cave_info = json.loads(cave[11])
|
||||
base_path = cave_info['basePath']
|
||||
candidates = cave_info['candidates']
|
||||
executable_path = candidates[0]['path']
|
||||
base_path = json.loads(cave[11])['basePath']
|
||||
candidates = json.loads(cave[11])['candidates']
|
||||
|
||||
# Skip games with an executable that ends with '.html' (browser games)
|
||||
if executable_path.endswith('.html'):
|
||||
if candidates and isinstance(candidates, list) and len(candidates) > 0:
|
||||
executable_path = candidates[0].get('path')
|
||||
if executable_path and executable_path.endswith('.html'):
|
||||
print(f"Skipping browser game: {game_info[2]}")
|
||||
continue
|
||||
game_title = game_info[2]
|
||||
itchgames.append((base_path, executable_path, game_title))
|
||||
else:
|
||||
print(f"No candidates found for game: {game_info[2]}")
|
||||
|
||||
|
||||
# Extract the game title
|
||||
game_title = game_info[2]
|
||||
|
Loading…
x
Reference in New Issue
Block a user