@@ -10,6 +10,7 @@ import (
1010
1111 "github.com/satisfactorymodding/SatisfactoryModManager/backend/installfinders/common"
1212 "github.com/satisfactorymodding/SatisfactoryModManager/backend/installfinders/launchers"
13+ "github.com/satisfactorymodding/SatisfactoryModManager/backend/installfinders/launchers/epic"
1314 "github.com/satisfactorymodding/SatisfactoryModManager/backend/installfinders/launchers/steam"
1415)
1516
@@ -44,11 +45,15 @@ func crossover() ([]*common.Installation, []error) {
4445 continue
4546 }
4647 bottleRoot := filepath .Join (bottlesPath , bottle .Name ())
47- bottleInstalls , bottleErrs := steam .FindInstallationsWine (bottleRoot , "CrossOver" , nil )
48- installations = append (installations , bottleInstalls ... )
49- if bottleErrs != nil {
50- errors = append (errors , bottleErrs ... )
48+ search := func (finder func (winePrefix string , launcher string , launchPath []string ) ([]* common.Installation , []error )) {
49+ bottleInstalls , bottleErrs := finder (bottleRoot , "CrossOver" , nil )
50+ installations = append (installations , bottleInstalls ... )
51+ if bottleErrs != nil {
52+ errors = append (errors , bottleErrs ... )
53+ }
5154 }
55+ search (steam .FindInstallationsWine )
56+ search (epic .FindInstallationsWine )
5257 }
5358
5459 return installations , errors
0 commit comments