🖌️Renderer
Table to work with renderer.
SetDrawColor(r [?]
: integer
, g [?]
: integer
, b [?]
: integer
, a [?]
: integer
): nil
[?]
: integer
, g [?]
: integer
, b [?]
: integer
, a [?]
: integer
): nil
r [?]
integer
Red color. (default: 255)
g [?]
integer
Green color. (default: 255)
b [?]
integer
Blue color. (default: 255)
a [?]
integer
Alpha color. (default: 255)
Sets the color of the renderer.
DrawLine(x0: integer
, y0: integer
, x1: integer
, y1: integer
): nil
integer
, y0: integer
, x1: integer
, y1: integer
): nil
x0
integer
X coordinate of the first point.
y0
integer
Y coordinate of the first point.
x1
integer
X coordinate of the second point.
y1
integer
Y coordinate of the second point.
Draws a line.
DrawPolyLine(points: table
): nil
table
): nil
points
table
Table of points.
Draws a polyline.
DrawPolyLineFilled(points: table
): nil
table
): nil
points
table
Table of points.
Draws a filled polyline.
DrawFilledRect(x: integer
, y: integer
, w: integer
, h: integer
): nil
integer
, y: integer
, w: integer
, h: integer
): nil
x
integer
X coordinate of the rectangle.
y
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
Draws a filled rectangle.
DrawOutlineRect(x: integer
, y: integer
, w: integer
, h: integer
): nil
integer
, y: integer
, w: integer
, h: integer
): nil
x
integer
X coordinate of the rectangle.
y
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
Draws an outlined rectangle.
DrawOutlineCircle(x: integer
, y: integer
, r: integer
, s: integer
): nil
integer
, y: integer
, r: integer
, s: integer
): nil
x
integer
X coordinate of the circle.
y
integer
Y coordinate of the circle.
r
integer
Radius of the circle.
s
integer
Segments of the circle.
Draws an outlined circle.
DrawFilledCircle(x: integer
, y: integer
, r: integer
): nil
integer
, y: integer
, r: integer
): nil
x
integer
X coordinate of the circle.
y
integer
Y coordinate of the circle.
r
integer
Radius of the circle.
Draws a filled circle.
DrawOutlineRoundedRect(x: integer
, y: integer
, w: integer
, h: integer
, radius: integer
): nil
integer
, y: integer
, w: integer
, h: integer
, radius: integer
): nil
x
integer
X coordinate of the rectangle.
y
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
radius
integer
Radius of the rectangle.
Draws an outlined rounded rectangle.
DrawFilledRoundedRect(x: integer
, y: integer
, w: integer
, h: integer
, radius: integer
): nil
integer
, y: integer
, w: integer
, h: integer
, radius: integer
): nil
x
integer
X coordinate of the rectangle.
y
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
radius
integer
Radius of the rectangle.
Draws a filled rounded rectangle.
DrawOutlineTriangle(points: table
): nil
table
): nil
points
table
Table of points.
Draws an outlined triangle.
DrawFilledTriangle(points: table
): nil
table
): nil
points
table
Table of points.
Draws a filled triangle.
DrawTexturedPolygon(points: table
, texture: integer
): nil
table
, texture: integer
): nil
points
table
Table of points.
texture
integer
Texture handle.
Draws a textured polygon.
LoadFont(name: string
, size: integer
, flags: integer
, weight: integer
): integer
string
, size: integer
, flags: integer
, weight: integer
): integer
name
string
Name of the font.
size
integer
Size of the font.
flags
integer
Font flags.
weight
integer
Font weight.
Loads a font.
DrawText(font: integer
, x: integer
, y: integer
, text: string
): nil
integer
, x: integer
, y: integer
, text: string
): nil
font
integer
Font handle.
x
integer
X coordinate of the text.
y
integer
Y coordinate of the text.
text
string
Text to draw.
Draws a text.
Converts world coordinates to screen coordinates. Returns x, y and visible.
GetScreenSize(): integer
, integer
integer
, integer
Returns screen size.
GetTextSize(font: integer
, text: string
): integer
, integer
integer
, text: string
): integer
, integer
font
integer
Font handle.
text
string
Text to measure.
Returns text size.
LoadImage(path: string
): integer
string
): integer
path
string
Path to the image.
Loads an image. Returns image handle.
DrawImage(handle: integer
, x: integer
, y: integer
, w: integer
, h: integer
): nil
integer
, x: integer
, y: integer
, w: integer
, h: integer
): nil
handle
integer
Image handle.
x
integer
X coordinate of the image.
y
integer
Y coordinate of the image.
w
integer
Width of the image.
h
integer
Height of the image.
Draws an image.
DrawImageCentered(handle: integer
, x: integer
, y: integer
, w: integer
, h: integer
): nil
integer
, x: integer
, y: integer
, w: integer
, h: integer
): nil
handle
integer
Image handle.
x
integer
X coordinate of the image.
y
integer
Y coordinate of the image.
w
integer
Width of the image.
h
integer
Height of the image.
Draws an image centered.
GetImageSize(handle: integer
): integer
, integer
integer
): integer
, integer
handle
integer
Image handle.
Returns image size.
DrawFilledRectFade(x0: integer
, y0: integer
, x1: integer
, y1: integer
, alpha0: integer
, alpha1: integer
, bHorizontal: boolean
): nil
integer
, y0: integer
, x1: integer
, y1: integer
, alpha0: integer
, alpha1: integer
, bHorizontal: boolean
): nil
x0
integer
X coordinate of the rectangle.
y0
integer
Y coordinate of the rectangle.
x1
integer
X coordinate of the rectangle.
y1
integer
Y coordinate of the rectangle.
alpha0
integer
Alpha of the first point.
alpha1
integer
Alpha of the second point.
bHorizontal
boolean
Horizontal fade.
Draws a filled rectangle with fade.
DrawFilledGradRect(x0: integer
, y0: integer
, x1: integer
, y1: integer
, r: integer
, g: integer
, b: integer
, a: integer
, r2: integer
, g2: integer
, b2: integer
, a2: integer
, bHorizontal: boolean
): nil
integer
, y0: integer
, x1: integer
, y1: integer
, r: integer
, g: integer
, b: integer
, a: integer
, r2: integer
, g2: integer
, b2: integer
, a2: integer
, bHorizontal: boolean
): nil
x0
integer
X coordinate of the rectangle.
y0
integer
Y coordinate of the rectangle.
x1
integer
X coordinate of the rectangle.
y1
integer
Y coordinate of the rectangle.
r
integer
Red color of the first point.
g
integer
Green color of the first point.
b
integer
Blue color of the first point.
a
integer
Alpha color of the first point.
r2
integer
Red color of the second point.
g2
integer
Green color of the second point.
b2
integer
Blue color of the second point.
a2
integer
Alpha color of the second point.
bHorizontal
boolean
Horizontal gradient.
Draws a filled gradient rectangle.
DrawGlow(x0: integer
, y0: integer
, w: integer
, h: integer
, thickness: integer
, obj_rounding: integer
): nil
integer
, y0: integer
, w: integer
, h: integer
, thickness: integer
, obj_rounding: integer
): nil
x0
integer
X coordinate of the rectangle.
y0
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
thickness
integer
Thickness of the glow.
obj_rounding
integer
Rounding of the glow.
Draws a glow.
DrawBlur(x0: number
, y0: number
, w: number
, h: number
, strength: number
, rounding: number
, alpha: number
): nil
number
, y0: number
, w: number
, h: number
, strength: number
, rounding: number
, alpha: number
): nil
x0
number
X coordinate of the rectangle.
y0
number
Y coordinate of the rectangle.
w
number
Width of the rectangle.
h
number
Height of the rectangle.
strength
number
Strength of the blur.
rounding
number
Rounding of the blur.
alpha
number
Alpha of the blur.
Draws a blur.
PushClip(x: integer
, y: integer
, w: integer
, h: integer
, intersect: boolean
): nil
integer
, y: integer
, w: integer
, h: integer
, intersect: boolean
): nil
x
integer
X coordinate of the rectangle.
y
integer
Y coordinate of the rectangle.
w
integer
Width of the rectangle.
h
integer
Height of the rectangle.
intersect
boolean
Intersect with the previous clip.
Pushes a clip rect.
PopClip(): nil
nil
Pops a clip rect.
DrawCenteredNotification(text: string
, duration: number
): nil
string
, duration: number
): nil
text
string
Text to draw.
duration
number
Duration of the notification.
Draws a centered notification.
Last updated