This commit is contained in:
Ale32bit 2023-07-21 14:48:32 +02:00
parent 4880fea8e3
commit 2f7c4fb032
3 changed files with 8 additions and 3 deletions

View file

@ -150,6 +150,8 @@ public class Capy64 : Game, IGame
break; break;
} }
EngineMode = mode;
UpdateSize(true); UpdateSize(true);
} }
@ -179,6 +181,11 @@ public class Capy64 : Game, IGame
private void OnWindowSizeChange(object sender, EventArgs e) private void OnWindowSizeChange(object sender, EventArgs e)
{ {
if (EngineMode == EngineMode.Classic) {
UpdateSize(true);
return;
}
var bounds = Window.ClientBounds; var bounds = Window.ClientBounds;
Width = (int)(bounds.Width / Scale); Width = (int)(bounds.Width / Scale);

View file

@ -157,8 +157,6 @@ public class GPULib : IComponent
public static void GetColor(uint c, out byte r, out byte g, out byte b) public static void GetColor(uint c, out byte r, out byte g, out byte b)
{ {
/*if (_game.EngineMode == EngineMode.Classic)
c = ColorPalette.GetColor(c);*/
Utils.UnpackRGB(c, out r, out g, out b); Utils.UnpackRGB(c, out r, out g, out b);
} }

View file

@ -200,7 +200,7 @@ public class FileHandle : IComponent
return 2; return 2;
} }
return G_Read(L, stream, 1); return G_Read(L, stream, 2);
} }
private static int G_Read(Lua L, Stream f, int first) private static int G_Read(Lua L, Stream f, int first)