diff --git a/pkg/daemon/api/games.go b/pkg/daemon/api/games.go index cc3d7348..a08d5f2e 100644 --- a/pkg/daemon/api/games.go +++ b/pkg/daemon/api/games.go @@ -7,6 +7,7 @@ import ( "github.com/go-chi/render" "github.com/rs/zerolog/log" + "github.com/wizzomafizzo/tapto/pkg/assets" "github.com/wizzomafizzo/tapto/pkg/config" "github.com/wizzomafizzo/tapto/pkg/database/gamesdb" "github.com/wizzomafizzo/tapto/pkg/platforms" @@ -64,7 +65,12 @@ func (s *Index) GenerateIndex(platform platforms.Platform, cfg *config.UserConfi if err != nil { s.CurrentDesc = status.SystemId } else { - s.CurrentDesc = system.Id + md, err := assets.GetSystemMetadata(system.Id) + if err != nil { + s.CurrentDesc = system.Id + } else { + s.CurrentDesc = md.Name + } } } log.Info().Msgf("indexing status: %s", s.CurrentDesc) diff --git a/pkg/platforms/mister/tracker.go b/pkg/platforms/mister/tracker.go index abc0a44e..37c6960b 100644 --- a/pkg/platforms/mister/tracker.go +++ b/pkg/platforms/mister/tracker.go @@ -204,9 +204,8 @@ func (tr *Tracker) LoadCore() { result := tr.LookupCoreName(coreName, tr.ActiveGamePath) if result != (NameMapping{}) { - mister.SetActiveGame(result.CoreName) - if result.ArcadeName != "" { + mister.SetActiveGame(result.CoreName) tr.ActiveGameId = coreName tr.ActiveGameName = result.ArcadeName tr.ActiveGamePath = "" // TODO: any way to find this? @@ -242,6 +241,10 @@ func (tr *Tracker) loadGame() { log.Error().Msgf("error getting active game: %s", err) tr.stopGame() return + } else if !filepath.IsAbs(activeGame) { + // arcade game, ignore handling + // TODO: will this work ok long term? + return } else if activeGame == "" { tr.stopGame() return