Fix .NET launcher console not working

This commit is contained in:
Bepis committed 2021-05-31 23:21:36 +10:00
1 parent 048943c322
commit 64a75b8513
1 file changed
+11 -2
@@ -31,8 +31,17 @@ namespace BepInEx
public void Initialize(bool alreadyActive)
{
ConsoleActive = alreadyActive;
StandardOut = Console.Out;
if (alreadyActive)
{
// We're in a .NET framework / XNA environment; console *is* stdout
ConsoleOut = Console.Out;
StandardOut = new StreamWriter(Console.OpenStandardOutput());
}
else
{
StandardOut = Console.Out;
}
}
public void CreateConsole(uint codepage)