Font
Information about the font binding
The following functions allow you to get an AbstractFontRenderer object which allows for some more functions to be used
Functions
drawString
font.getMinecraftFontRenderer().drawString(text, x, y, color)
//or
font.getTenacityFont14().drawString(text, x, y, color)
Draws a string in the specified x and y values with the specified color
Parameter
Type
Description
drawStringWithShadow
font.getMinecraftFontRenderer().drawStringWithShadow(text, x, y, color)
//or
font.getTenacityFont14().drawStringWithShadow(text, x, y, color)
Draws a string with a shadow in the specified x and y values with the specified color
Parameter
Type
Description
drawCenteredString
font.getMinecraftFontRenderer().drawCenteredString(text, x, y, color)
//or
font.getTenacityFont14().drawCenteredString(text, x, y, color)
Draws a centered string in the specified x and y values with the specified color
Parameter
Type
Description
getStringWidth
font.getMinecraftFontRenderer().getStringWidth(text)
//or
font.getTenacityFont14().getStringWidth(text)
Returns a Number that is the string width based on the specified text
Parameter
Type
Description
text
String
Specified text to use to get the string width
getHeight
font.getMinecraftFontRenderer().getHeight()
//or
font.getTenacityFont14().getHeight()
Returns a Number based on the font's height
getMiddleOfBox
font.getMinecraftFontRenderer().getMiddleOfBox(height)
//or
font.getTenacityFont14().getMiddleOfBox(height)
Returns a Number that should be the font's Y center of the height
getMinecraftFontRenderer
font.getMinecraftFontRenderer().drawString(...
getTenacityFont14
font.getTenacityFont14().drawString(...
getTenacityFont16
font.getTenacityFont16().drawString(...
getTenacityFont18
font.getTenacityFont18().drawString(...
getTenacityFont20
font.getTenacityFont20().drawString(...
getTenacityFont22
font.getTenacityFont22().drawString(...
getTenacityFont24
font.getTenacityFont24().drawString(...
getTenacityFont26
font.getTenacityFont26().drawString(...
getTenacityFont28
font.getTenacityFont28().drawString(...
getTenacityFont32
font.getTenacityFont32().drawString(...
getTenacityFont40
font.getTenacityFont40().drawString(...
getTenacityFont80
font.getTenacityFont80().drawString(...
Last updated
Was this helpful?