Skip to content

Commit

Permalink
Fixed possible overlay exception
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanpmartell committed Aug 1, 2024
1 parent b75b0bb commit 13d1548
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions LittleWarGameClient/OverlayForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,12 @@ protected override void OnRender(D2DGraphics g)
{
for (int i = 0; i < overlayMessages.Count; i++)
{
var notification = overlayMessages[i].Value.message;
g.DrawText($" >{notification}", D2DColor.Yellow, Font, 0, (i + 1) * 30);
try
{
var notification = overlayMessages[i].Value.message;
g.DrawText($" >{notification}", D2DColor.Yellow, Font, 0, (i + 1) * 30);
}
catch { break; }
}
}

Expand Down

0 comments on commit 13d1548

Please sign in to comment.