1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2024-12-12 11:10:29 +00:00

Terminal cursor bounds checking

This commit is contained in:
Lignum 2017-05-05 00:08:10 +02:00
parent 4e3def39e0
commit 4b8493baab
No known key found for this signature in database
GPG Key ID: E4DE8F54CA0912BA

View File

@ -410,7 +410,7 @@ public class WidgetTerminal extends Widget
y += FixedWidthFontRenderer.FONT_HEIGHT;
}
if( tblink )
if( tblink && tx >= 0 && ty >= 0 && tx < tw && ty < th )
{
TextBuffer cursor = new TextBuffer( '_', 1 );
TextBuffer cursorColour = new TextBuffer( "0123456789abcdef".charAt( terminal.getTextColour() ), 1 );