1
0

Add --redirect-console option

This commit is contained in:
otya128
2017-07-08 17:41:31 +09:00
parent 18719c0c17
commit 2076af47f6
4 changed files with 28 additions and 7 deletions

View File

@@ -651,4 +651,20 @@ class Console
petitcom.graphic.GRPFHeight = GRPF.surface.h;
GRPF.createTexture(petitcom.renderer, petitcom.textureScaleMode);
}
}
}
class NativeConsole : Console
{
File file;
this(File file, PetitComputer p)
{
super(p);
this.file = file;
}
override void printString(wstring text)
{
super.printString(text);
file.write(text);
file.flush;
}
}