def mappings(self, profile_save_dir):
        m = mobase.Mapping()
        m.createTarget = True
        m.isDirectory = True
        m.source = profile_save_dir.absolutePath()
        m.destination = self._savesDir

        return [m]
Esempio n. 2
0
 def mappings(self) -> List[mobase.Mapping]:
     appdata = self.gameDirectory().filePath("appdata")
     m = mobase.Mapping()
     m.createTarget = True
     m.isDirectory = True
     m.source = appdata
     m.destination = appdata
     return [m]
    def mappings(self) -> List[mobase.Mapping]:
        modsPath = self._organizer.modsPath()
        unityMods = self.getUnityDataMods()

        mappings: List[mobase.Mapping] = []

        for modName in unityMods:
            m = mobase.Mapping()
            m.createTarget = False
            m.isDirectory = True
            m.source = join(modsPath, modName, "AssetBundle")
            m.destination = self.gameDirectory().filePath(
                join("masterduel_Data", "StreamingAssets", "AssetBundle")
            )
            mappings.append(m)

        return mappings
 def mappings(self) -> List[mobase.Mapping]:
     map = []
     modDirs = [self.DOCS_MOD_SPECIAL_NAME]
     self._listDirsRecursive(modDirs, prefix=self.DOCS_MOD_SPECIAL_NAME)
     for dir_ in modDirs:
         for file_ in self._organizer.findFiles(path=dir_,
                                                filter=lambda x: True):
             m = mobase.Mapping()
             m.createTarget = True
             m.isDirectory = False
             m.source = file_
             m.destination = os.path.join(
                 self.documentsDirectory().absoluteFilePath("Mods"),
                 file_.split(
                     self.DOCS_MOD_SPECIAL_NAME)[1].strip("\\").strip("/"),
             )
             map.append(m)
     return map