From 1fff6d441d8591743b5f98c4fc297555d21d6b0f Mon Sep 17 00:00:00 2001 From: uwx Date: Sat, 13 Apr 2024 05:00:35 -0300 Subject: [PATCH] Add support for Test Drive Unlimited 2 (#147) * Add TDU2 Support --------- Co-authored-by: uwx --- README.md | 1 + games/game_tdu2.py | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 games/game_tdu2.py diff --git a/README.md b/README.md index 824bcf0..f1d5594 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,7 @@ You can rename `modorganizer-basic_games-xxx` to whatever you want (e.g., `basic | Train Simulator Classic — [STEAM](https://store.steampowered.com/app/24010/) | [Ryan Young](https://github.com/YoRyan) | [game_trainsimulator.py](games/game_trainsimulator.py) | | | Valheim — [STEAM](https://store.steampowered.com/app/892970/Valheim/) | [Zash](https://github.com/ZashIn) | [game_valheim.py](games/game_valheim.py) | | | Test Drive Unlimited | [uwx](https://github.com/uwx) | [game_tdu.py](games/game_tdu.py) | | +| Test Drive Unlimited 2 — [STEAM](https://steamcommunity.com/app/9930/) | [uwx](https://github.com/uwx) | [game_tdu2.py](games/game_tdu2.py) | | | The Witcher: Enhanced Edition - [GOG](https://www.gog.com/game/the_witcher) / [STEAM](https://store.steampowered.com/app/20900/The_Witcher_Enhanced_Edition_Directors_Cut/) | [erri120](https://github.com/erri120) | [game_witcher1.py](games/game_witcher1.py) | | | The Witcher 3: Wild Hunt — [GOG](https://www.gog.com/game/the_witcher_3_wild_hunt) / [STEAM](https://store.steampowered.com/app/292030/The_Witcher_3_Wild_Hunt/) | [Holt59](https://github.com/holt59/) | [game_witcher3.py](games/game_witcher3.py) | | | Tony Hawk's Pro Skater 3 | [uwx](https://github.com/uwx) | [game_thps3.py](games/game_thps3.py) | | diff --git a/games/game_tdu2.py b/games/game_tdu2.py new file mode 100644 index 0000000..83b0862 --- /dev/null +++ b/games/game_tdu2.py @@ -0,0 +1,35 @@ +# -*- encoding: utf-8 -*- + +import mobase +from PyQt6.QtCore import QFileInfo + +from ..basic_game import BasicGame + + +class TDU2Game(BasicGame): + + Name = "Test Drive Unlimited 2 Support Plugin" + Author = "uwx" + Version = "1.0.0" + + GameName = "Test Drive Unlimited 2" + GameShortName = "tdu2" + GameNexusName = "testdriveunlimited2" + GameNexusId = 2353 + GameSteamId = 9930 + GameBinary = "UpLauncher.exe" + GameDataPath = "" + + def executables(self): + return [ + mobase.ExecutableInfo( + "Test Drive Unlimited 2", + QFileInfo(self.gameDirectory().absoluteFilePath(self.binaryName())), + ), + mobase.ExecutableInfo( + "TDU2 Universal Launcher", + QFileInfo( + self.gameDirectory().absoluteFilePath("TDU2_Universal_Launcher.exe") + ), + ), + ]