Skip to content

Commit

Permalink
Fix lines not shown in console if logged after scroll up and clear lines
Browse files Browse the repository at this point in the history
  • Loading branch information
WEGFan committed Sep 5, 2021
1 parent 7279867 commit d793da8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Celeste.Mod.mm/Patches/Monocle/Commands.cs
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,7 @@ public void ReloadCommandsList() {
}
drawCommands.Insert(0, new patch_Line(text, color));
int maxCommandLines = Math.Max(CoreModule.Settings.ExtraCommandHistoryLines + (Engine.Instance.Window.ClientBounds.Height - 100) / 30, 0);
firstLineIndexToDraw = Calc.Clamp(firstLineIndexToDraw, 0, Math.Max(drawCommands.Count - 1, 0));
while (drawCommands.Count > maxCommandLines) {
drawCommands.RemoveAt(drawCommands.Count - 1);
}
Expand Down

0 comments on commit d793da8

Please sign in to comment.