Master_MTA Posted August 11, 2017 Share Posted August 11, 2017 hi all i have small question how i can transfer the text length to pixel i wanna check when i draw dx text if it more than 100px maybe then return like that local sx_,sy_=guiGetScreenSize() local mx,my=sx_/1366,sy_/768 local tt='test' addEventHandler('onClientRender',root,function() if #tt+my*275>=278 then return end ----------my try dxDrawText ( tt,mx*323, my*275,mx* 265,my* 231, toccolor(255,0,255,255), 1.4) --------------- font size is the problem end) Link to comment
Tails Posted August 12, 2017 Share Posted August 12, 2017 Looking for this? https://wiki.multitheftauto.com/wiki/DxGetTextWidth 1 Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now