File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -50,7 +50,8 @@ git clone https://github.com/Holt59/modorganizer-basic_games basic_games
5050| [ Dark Messiah of Might & Magic] ( https://store.steampowered.com/app/2100/Dark_Messiah_of_Might__Magic/ ) | Holt59 | [ game_darkmessiah[ ...] .py] ( games/game_darkmessiahofmightandmagic.py ) | <ul ><li >steam detection</li ><li >save game preview</li ></ul > |
5151| [ Darkest Dungeon] ( https://store.steampowered.com/app/262060/Darkest_Dungeon/ ) | [ erri120] ( https://github.com/erri120 ) | [ game_darkestdungeon.py] ( games/game_darkestdungeon.py ) | <ul ><li >steam detection</li ></ul > |
5252| [ Dungeon Siege II] ( https://store.steampowered.com/app/39200/Dungeon_Siege_II/ ) | Holt59 | [ game_dungeonsiege2.py] ( games/game_dungeonsiege2.py ) | <ul ><li >steam detection</li ><li >mod data checker</li ></ul > |
53- | S.T.A.L.K.E.R. Anomaly| [ Qudix] ( https://github.com/Qudix ) | [ game_stalkeranomaly.py] ( games/game_stalkeranomaly.py ) | |
53+ | [ Mount & Blade II: Bannerlord] ( https://store.steampowered.com/app/261550/Mount__Blade_II_Bannerlord/ ) | Holt59 | | <ul ><li >steam detection</li ><li >mod data checker</li ></ul > |
54+ | [ S.T.A.L.K.E.R. Anomaly] ( https://www.stalker-anomaly.com/ ) | [ Qudix] ( https://github.com/Qudix ) | [ game_stalkeranomaly.py] ( games/game_stalkeranomaly.py ) | |
5455| [ Stardew Valley] ( https://store.steampowered.com/app/413150/Stardew_Valley/ ) | [ Syer10] ( https://github.com/Syer10 ) , Holt59 | [ game_stardewvalley.py] ( games/game_stardewvalley.py ) | <ul ><li >steam detection</li ><li >mod data checker</li ></ul > |
5556| [ The Witcher 3: Wild Hunt] ( https://store.steampowered.com/app/292030/The_Witcher_3_Wild_Hunt/ ) | Holt59 | [ game_witcher3.py] ( games/game_witcher3.py ) | <ul ><li >steam detection</li ><li >save game preview</li ></ul > |
5657
Original file line number Diff line number Diff line change 22
33from PyQt5 .QtCore import QFileInfo
44
5+ from typing import List
6+
57import mobase
68
79from ..basic_game import BasicGame
810
911
12+ class MountAndBladeIIModDataChecker (mobase .ModDataChecker ):
13+
14+ _valid_folders : List [str ] = [
15+ "native" ,
16+ "sandbox" ,
17+ "sandboxcore" ,
18+ "storymode" ,
19+ "custombattle" ,
20+ ]
21+
22+ def __init__ (self ):
23+ super ().__init__ ()
24+
25+ def dataLooksValid (
26+ self , tree : mobase .IFileTree
27+ ) -> mobase .ModDataChecker .CheckReturn :
28+
29+ for e in tree :
30+ if e .isDir ():
31+ if e .name ().lower () in self ._valid_folders :
32+ return mobase .ModDataChecker .VALID
33+ if e .exists ("SubModule.xml" , mobase .IFileTree .FILE ): # type: ignore
34+ return mobase .ModDataChecker .VALID
35+
36+ return mobase .ModDataChecker .INVALID
37+
38+
1039class MountAndBladeIIGame (BasicGame ):
1140 Name = "Mount & Blade II: Bannerlord"
1241 Author = "Holt59"
@@ -26,6 +55,11 @@ class MountAndBladeIIGame(BasicGame):
2655 GameNexusId = 3174
2756 GameSteamId = 261550
2857
58+ def init (self , organizer : mobase .IOrganizer ):
59+ super ().init (organizer )
60+ self ._featureMap [mobase .ModDataChecker ] = MountAndBladeIIModDataChecker ()
61+ return True
62+
2963 def executables (self ):
3064 return [
3165 mobase .ExecutableInfo (
@@ -54,4 +88,4 @@ def executables(self):
5488 self .gameDirectory (), "bin/Win64_Shipping_Client/Bannerlord_BE.exe" ,
5589 ),
5690 ),
57- ]
91+ ]
You can’t perform that action at this time.
0 commit comments