From the reference libraryRedM

autodoc_client_functions

jo_libs/modules/debugger/autodoc/autodoc_client_functions.md

autodoc_client_functions

JO Functions > jo.debugger.drawSphere()

Draws a 3D sphere at the specified coordinates. <br>

JO Functions > jo.debugger.drawSphere() > Syntax

jo.debugger.drawSphere(coords, size, color)

JO Functions > jo.debugger.drawSphere() > Parameters

coords : vector

The coordinates where the sphere will be drawn

size : vector <BadgeOptional />

The size of the sphere in x,y,z dimensions - default:vec3(0.5, 0.5, 0.5)

color : table <BadgeOptional />

The color of the sphere

color.r : number - Red component 0-255 - default:255

color.g : number - Green component 0-255 - default:0

color.b : number - Blue component 0-255 - default:0

color.a : number - Alpha/transparency 0-255 - default:100

JO Functions > jo.debugger.drawSphere() > Example

local coords = vec3(1234.56, 789.01, 123.45)
local size = vec3(0.7, 0.7, 0.7)
local color = { r = 0, g = 255, b = 0, a = 150 }
jo.debugger.drawSphere(coords, size, color)


JO Functions > jo.debugger.drawText()

Draws text on the screen with specified parameters. <br>

JO Functions > jo.debugger.drawText() > Syntax

jo.debugger.drawText(text, x, y)

JO Functions > jo.debugger.drawText() > Parameters

text : string

The text content to be displayed

x : number <BadgeOptional />

The x-coordinate position on screen - default:0.01

y : number <BadgeOptional />

The y-coordinate position on screen - if not provided, uses and increments the global offset

JO Functions > jo.debugger.drawText() > Example

-- Drawing text at a specific position
jo.debugger.drawText("Player Health: 100", 0.5, 0.2)


JO Functions > jo.debugger.resetText()

Resets the text display offset to its starting position. <br>

JO Functions > jo.debugger.resetText() > Syntax

jo.debugger.resetText()

JO Functions > jo.debugger.resetText() > Example

jo.debugger.drawText("First line")

jo.debugger.resetText()

jo.debugger.drawText("New first line")

Back to documentation