Fenyx4 / UltimaPatcher

MIT License
31 stars 1 forks source link

Ultima 2 Upgrade theme issue #24

Open keliburn opened 1 year ago

keliburn commented 1 year ago

After applying the Ultima 2 Upgrade using the patcher, it's not possible to select any other themes using the upgrade's configuration program. It seems that the problem is the patcher is not copying the theme specific files to the proper sub-directories in the Ultima 2 location.

Specifically, I think these lines of code:

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.10", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\" & System.IO.Path.GetFileName(file), True)
            Next

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.ALT", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\" & System.IO.Path.GetFileName(file), True)
            Next

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.C64", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\" & System.IO.Path.GetFileName(file), True)
            Next

Should actually look like this:

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.10", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\EGATHEME.10\" & System.IO.Path.GetFileName(file), True)
            Next

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.ALT", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\EGATHEME.ALT\" & System.IO.Path.GetFileName(file), True)
            Next

            fileNames = My.Computer.FileSystem.GetFiles("Files\U2Upgrade\EGATHEME.C64", FileIO.SearchOption.SearchTopLevelOnly, "*.*")
            For Each file In fileNames
                My.Computer.FileSystem.CopyFile(file, U2Location & "\EGATHEME.C64\" & System.IO.Path.GetFileName(file), True)
            Next