kourendlibrary: Null check

This commit is contained in:
sdburns1998
2019-07-07 15:20:21 +02:00
parent 04197f3d6b
commit b61c98e2a3

View File

@@ -228,7 +228,10 @@ class KourendLibraryOverlay extends Overlay
Point screen = Perspective.localToCanvas(client, local, client.getPlane(), n.getLogicalHeight());
if (screen != null)
{
g.drawImage(b.getIcon(), screen.getX() - (b.getIcon().getWidth() / 2), screen.getY() - b.getIcon().getHeight(), null);
if (b != null)
{
g.drawImage(b.getIcon(), screen.getX() - (b.getIcon().getWidth() / 2), screen.getY() - b.getIcon().getHeight(), null);
}
}
});
}