Skip to content

Commit d1edf4e

Browse files
authored
Merge pull request #142 from aternosorg/forge-client-26-1
Detect forge 26.1 client logs
2 parents bdad4fa + 162df9e commit d1edf4e

4 files changed

Lines changed: 1628 additions & 2 deletions

File tree

src/Log/Minecraft/Vanilla/Forge/ForgeClientLog.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Aternos\Codex\Minecraft\Log\Minecraft\Vanilla\Forge;
44

55
use Aternos\Codex\Detective\MultiPatternDetector;
6+
use Aternos\Codex\Minecraft\Analysis\Information\Vanilla\VanillaVersionInformation;
67
use Aternos\Codex\Minecraft\Log\Type\ClientLogTypeInterface;
78

89
class ForgeClientLog extends ForgeLog implements ClientLogTypeInterface
@@ -17,11 +18,11 @@ public static function getDetectors(): array
1718
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: ModLauncher running: .*--fml.forgeVersion/m')
1819
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: Launching target \'(fml|forge)client\' with arguments/m'),
1920
(new MultiPatternDetector())
20-
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: ModLauncher running: .*--version, forge-/m')
21+
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: ModLauncher running: .*--version, (?:' . VanillaVersionInformation::getVersionPattern() . '-)?forge-/m')
2122
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: Launching target \'forge_client\' with arguments/m'),
2223
(new MultiPatternDetector())
2324
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: Forge Mod Loader version/m')
2425
->addPattern('/^\[[^\]]+\] \[main\/INFO\]( \[[^\]]+\])?: Launching wrapped minecraft \{net\.minecraft\.client/m')
2526
];
2627
}
27-
}
28+
}

0 commit comments

Comments
 (0)