Skip to content

Commit fdaaadd

Browse files
author
Jim
committed
initial wokring SH2 remake plugin.
1 parent 80dc114 commit fdaaadd

1 file changed

Lines changed: 50 additions & 0 deletions

File tree

games/game_silenthill2remake.py

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
from ..basic_game import BasicGame
2+
import mobase
3+
4+
class SilentHill2RemakeModDataChecker(mobase.ModDataChecker):
5+
def __init__(self):
6+
super().__init__()
7+
self.validDirNames = [
8+
"."
9+
]
10+
11+
def dataLooksValid(self, filetree: mobase.IFileTree) -> mobase.ModDataChecker.CheckReturn:
12+
for entry in filetree:
13+
if not entry.isDir():
14+
continue
15+
if entry.name().casefold() in (name.casefold() for name in self.validDirNames):
16+
return mobase.ModDataChecker.VALID
17+
return mobase.ModDataChecker.INVALID
18+
19+
class SilentHill2RemakeGame(BasicGame):
20+
def init(self, organizer: mobase.IOrganizer) -> bool:
21+
super().init(organizer)
22+
self._register_feature(SilentHill2RemakeModDataChecker())
23+
return True
24+
25+
Name = "Silent Hill 2 Remake Support Plugin"
26+
Author = "HomerSimpleton Returns"
27+
Version = "1.0"
28+
29+
GameName = "Silent Hill 2 Remake"
30+
GameShortName = "silenthill2"
31+
GameNexusName = "silenthill2"
32+
33+
GameBinary = "SHProto/Binaries/Win64/SHProto-Win64-Shipping.exe"
34+
GameLauncher = "SHProto.exe"
35+
#GameDataPath = "%GAME_PATH%/SHProto/Content/Paks/~mods"
36+
GameDataPath = "%GAME_PATH%/SHProto/Content"
37+
GameSupportURL = "https://github.com/ModOrganizer2/modorganizer-basic_games/wiki/Game:-Silent-Hill-2-Remake"
38+
39+
GameGogId = [1225972913, 2051029707]
40+
41+
# def executables(self):
42+
# return [
43+
# {
44+
# "name": "Silent Hill 2 Remake",
45+
# "binary": self.GameBinary,
46+
# }
47+
# ]
48+
49+
# def dataDirectory(self):
50+
# return self._gamePath + "/SHProto/Content/Paks"

0 commit comments

Comments
 (0)