Jump to content

draw custom font?


Recommended Posts

fonts = {}
fonts["robotoPath"] = "files/fonts/roboto.ttf"
fonts["robotoSize"] = 20
fonts["robotoBold"] = false
fonts["robotoQuality"] = "proof"

roboto = dxCreateFont (fonts["robotoPath"], fonts["robotoSize"], fonts["robotoBold"], fonts["robotoQuality"])

function showDebugs()
	local X, Y = guiGetScreenSize()
	local myX, myY = 1366, 768

	dxDrawText ("test", 500, 500, _, _, _, _, "roboto", _, _, _, _, _, true)
end
addEventHandler ("onClientRender", getRootElement(), showDebugs)

however the font is in the directory, it is not getting displayed as a roboto font.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...