Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions src/Log/Minecraft/Vanilla/Forge/ForgeClientLog.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

use Aternos\Codex\Detective\MultiPatternDetector;
use Aternos\Codex\Detective\SinglePatternDetector;
use Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaVersionInformation;
use Aternos\Codex\Minecraft\Log\Type\ClientLogTypeInterface;

class ForgeClientLog extends ForgeLog implements ClientLogTypeInterface
Expand All @@ -18,16 +17,14 @@ public static function getDetectors(): array
(new MultiPatternDetector())
->addPattern('/' . static::MAIN_INFO_PREFIX . 'ModLauncher running: .*--fml\.forgeVersion/m')
->addPattern('/' . static::MAIN_INFO_PREFIX . 'Launching target \'(fml|forge)client\' with arguments/m'),
(new MultiPatternDetector())
->addPattern('/' . static::MAIN_INFO_PREFIX . 'ModLauncher running: .*--version, (?:' . VanillaVersionInformation::getVersionPattern() . '-)?forge-/m')
->addPattern('/' . static::MAIN_INFO_PREFIX . 'Launching target \'forge_client\' with arguments/m'),
// Forge 1.20.2 and newer, independent of the version name the launcher passes and of the Modrinth App's line format
// [17:55:07] [main/INFO]: Launching target 'forge_client' with arguments [--version, 26.3, ...
// [23:18:07] [main] [cpw.mods.modlauncher.LaunchServiceHandler/INFO]: Launching target 'forge_client' with arguments [--version, 26.3, ...
new SinglePatternDetector()
->setPattern('/' . static::MAIN_INFO_PREFIX . 'Launching target \'forge_client\' with arguments/m'),
(new MultiPatternDetector())
->addPattern('/' . static::MAIN_INFO_PREFIX . 'Forge Mod Loader version/m')
->addPattern('/' . static::MAIN_INFO_PREFIX . 'Launching wrapped minecraft \{net\.minecraft\.client/m'),
// The Modrinth App only starts clients and passes the plain Minecraft version without "forge-":
// [23:18:07] [main] [cpw.mods.modlauncher.LaunchServiceHandler/INFO]: Launching target 'forge_client' with arguments [--version, 26.3, ...
(new SinglePatternDetector())
->setPattern('/^\[[^\]]+\] \[main\] \[[^\]\/]+\/INFO\]: Launching target \'forge_client\' with arguments/m')
];
}
}
Loading
Loading