Opened 8 years ago

Closed 8 years ago

Last modified 6 years ago

#9754 closed defect (fixed)

The "auto-detect" switch no-longer works properly

Reported by: Enverex Owned by: criezy
Priority: normal Component: --Other--
Version: Keywords:
Cc: Game:

Description

This used to work by telling you the detected game in the folder (this functionality appears to have been moved to "--detect" instead). It's now changed and instead it tries to launch the game automatically using the detected engine. That would be fine, but it appears to pass along the wrong information to ScummVM and it breaks. Here are a few examples...

scummvm --auto-detect                    ID                   Description
-------------------- ---------------------------------------------------------
monkey2              Monkey Island 2: LeChuck's Revenge (FM-TOWNS/English)
WARNING: SDL mixer output buffer size: 2048 differs from desired: 4096!
User picked target 'monkey2-fm' (gameid 'monkey2-fm')...
  Looking for a plugin supporting this gameid... failed
WARNING: monkey2-fm is an invalid gameid. Use the --list-games option to list supported gameid!

You'd expect it to pass along monkey2, but instead it's passing along monkey2-fm which isn't valid and it fails to start. Seems to happen with any game...

scummvm --auto-detect
ID                   Description
-------------------- ---------------------------------------------------------
sci                  Gabriel Knight: Sins of the Fathers (CD/DOS/English)
sci                  Gabriel Knight: Sins of the Fathers (CD/Windows/English)
WARNING: SDL mixer output buffer size: 2048 differs from desired: 4096!
User picked target 'gk1-cd' (gameid 'gk1-cd')...
  Looking for a plugin supporting this gameid... failed
WARNING: gk1-cd is an invalid gameid. Use the --list-games option to list supported gameid!

Again, it's expecting "sci" but instead is passed "gk1-cd" so nothing happens (the GUI shows a "Could not find any engine capable of running the selected game" as expected).

Change History (3)

comment:1 by criezy, 8 years ago

Owner: set to criezy
Resolution: fixed
Status: newclosed

Thank you for the bug report. This is now fixed.

Several notes:

  • The --auto-detect option always attempted to start a game after listing the detected games. This is not new and has always been the behaviour since this option was added.
  • The --detect option was added more recently to only list the detected games, without attempting to start one.
  • There was indeed a bug added recently where it used an incorrect game ID for some game after auto-detect, which resulted in the bug you see.
  • There was also an older bug that caused other command line options to be lost when using --auto-detect. In particular this resulted in the path (if using -p or --path) to be lost, and usually caused the game to fail to start due to the data files not being found (the exception being if the game had been previously added to ScummVM with a target name identical to the game ID, or if the command was execute from the game directory).

comment:2 by Enverex, 8 years ago

Ah, so the behaviour I saw before was a combination of 1 and 4 happening together.

Thanks for fixing this so quickly!

comment:3 by digitall, 6 years ago

Component: --Unset----Other--
Note: See TracTickets for help on using tickets.