Render
Information about the render binding
drawRect
render.drawRect(x, y, width, height, color)
Renders a rectangle using the specified parameters
x
Number
X pos of the rect
y
Number
Y pos of the rect
width
Number
Width of the rect
height
Number
Height of the rect
drawRoundedRect
render.drawRoundedRect(x, y, width, height, radius, color)
Renders a rounded rectangle
x
Number
X pos of the rect
y
Number
Y pos of the rect
width
Number
Width of the rect
height
Number
Height of the rect
radius
Number
Radius of the rounded parts
drawGradientRect
render.drawGradientRect(x, y, width, height, alpha, bottomLeft, topLeft, bottomRight, topRight)
Draws a gradient with values for all corners of a rectangle
x
Number
X pos of the rect
y
Number
Y pos of the rect
width
Number
Width of the rect
height
Number
Height of the rect
alpha
Number
Alpha of the gradient
drawGradientRectHorizontal
render.drawGradientRectHorizontal(x, y, width, height, alpha, left, right)
Draws a gradient horizontally (left to right)
drawGradientRectVertical
render.drawGradientRectVertical(x, y, width, height, alpha, top, bottom)
Draws a gradient vertically (top to bottom)
drawGradientRoundedRect
render.drawGradientRoundedRect(x, y, width, height, radius, bottomLeft, topLeft, bottomRight, topRight)
Draws a rounded gradient with values for all corners of a rectangle
x
Number
X pos of the rect
y
Number
Y pos of the rect
width
Number
Width of the rect
height
Number
Height of the rect
radius
Number
Radius of the rounded rect
drawGradientRoundHorizontal
render.drawGradientRoundHorizontal(x, y, width, height, radius, left, right)
Draws a rounded gradient horizontally (left to right)
drawGradientRoundVertical
render.drawGradientRoundVertical(x, y, width, height, radius, top, bottom)
Draws a rounded gradient horizontally (top to bottom)
applyGradient
render.applyGradient(x, y, width, height, alpha, bottomLeft, topLeft, bottomRight, topRight, function() {
...
(Render stuff here)
...
})
Applies a gradient to any rendered object in the callback function
x
Number
X pos of the rect
y
Number
Y pos of the rect
width
Number
Width of the rect
height
Number
Height of the rect
alpha
Number
Alpha of the final result
callback function
Function
create a function here to specify a specific group of objects for the gradient to be applied too
interpolateColors
var interpolatedColor = render.interpolateColors(colorOld, colorNew, percentage)
Returns a an interpolated Color between the two colors based on the percentage
applyOpacity
var color = client.getClientColors().getFirst()
var alpha = .5
var opaqueColor = render.applyOpacity(color, alpha)
Applies opacity to a color with a value ranging from 0-1
alpha
Number
Alpha value of the new color
getScaledWidth
render.getScaledWidth()
Returns the scaled width of the screen as a Number
getScaledHeight
render.getScaledHeight()
Returns the scaled height of the screen as a Number
drawEntity3D
render.drawEntity3D(x, y, scale, yaw, pitch, entity)
x
Number
X pos of the entity
y
Number
Y pos of the entity
scale
Number
Scale of the entity
yaw
Number
Yaw of the entity
pitch
Number
Pitch of the entity
drawEntity2D
render.drawEntity2D(x, y, width, height, entity)
Draws the entity's head
x
Number
X pos of the entity's head
y
Number
Y pos of the entity's head
width
Number
Width of the entity's head
height
Number
Height of the entity's head
newContinualAnimation
var anim = render.newContinualAnimation()
Returns a new Continual Animation object
createFramebuffer
var buffer = render.createFramebuffer()
Returns a new Framebuffer object
drawBoundingBox
render.drawBoundingBox(entity, color)
This renders the entity's bounding box with the specified color
color
Color
Color of the bounding box
scissorStart
render.scissorStart(x, y, width, height)
This is a helper function for scissoring out stuff
x
Number
The x position of the scissor
y
Number
The y position of the scissor
width
Number
The width of the scissor
height
Number
The height of the scissor
scissorEnd
render.scissorEnd()
Disables the scissor test
getPartialTicks
var ticks = render.getPartialTicks()
Gets the render partial ticks as a Number
bindMinecraftFramebuffer
render.bindMinecraftFramebuffer()
This rebinds the Minecraft framebuffer so you can continue rendering after using other Framebuffer objects
createShaderUtil
var shader = render.createShaderUtil(fragSource)
Returns a ShaderUtil object
fragSource
String
The complete fragment shader source
Last updated
Was this helpful?