Skip to content

drawRectOutline

fun GuiGraphics.drawRectOutline(
    x: Int, 
    y: Int, 
    width: Int, 
    height: Int, 
    color: Int, 
    thickness: Int = 1
)

Draws a hollow rectangle outline using RenderType.gui.

Parameters

  • x: X coordinate of the top-left corner.

  • y: Y coordinate of the top-left corner.

  • width: Width of the rectangle in pixels.

  • height: Height of the rectangle in pixels.

  • color: ARGB colour of the outline.

  • thickness: Stroke width in pixels (default 1).

fun GuiGraphics.drawRectOutline(
    type: RenderType, 
    x: Int, 
    y: Int, 
    width: Int, 
    height: Int, 
    color: Int, 
    thickness: Int = 1
)

Draws a hollow rectangle outline with an explicit RenderType.

Parameters

  • type: The RenderType to use.

  • x: X coordinate of the top-left corner.

  • y: Y coordinate of the top-left corner.

  • width: Width of the rectangle in pixels.

  • height: Height of the rectangle in pixels.

  • color: ARGB colour of the outline.

  • thickness: Stroke width in pixels (default 1).