iSpark Posted August 14, 2012 Share Posted August 14, 2012 Hey how can i add a dxDrawRectangle To that Text Lua local screen_width, screen_height = guiGetScreenSize() local RESPAWN_KEY = "space" local showRespawn = false local text = "#FF5500Press #808080"..RESPAWN_KEY.." #FF5500to respawn" local scale = 1.5 local font = "arial" local textWidth = dxGetTextWidth(text:gsub("#%x%x%x%x%x%x", ""), scale, font) local fontHeight = dxGetFontHeight(scale, font) local color = tocolor(255, 128, 0, 255) setElementData(getLocalPlayer(), "respawn.playing", false, true) local running = false local vehicleData = {} local SAVE_INTER = 22500 local saveTimer = nil local reset = true -- reset timer local lastSaved = 0 Thank's Link to comment
Castillo Posted August 14, 2012 Share Posted August 14, 2012 dxDrawRectangle dxDrawText Link to comment
iSpark Posted August 14, 2012 Author Share Posted August 14, 2012 dxDrawRectangle dxDrawText I try but The Code not work Link to comment
iSpark Posted August 14, 2012 Author Share Posted August 14, 2012 local screen_width, screen_height = guiGetScreenSize() local RESPAWN_KEY = "space" local showRespawn = false dxDrawText = "#FF5500Press #808080"..RESPAWN_KEY.." #FF5500to respawn" dxDrawRectangle ( x/3.8, y/3.8, x/2.02, y/2, tocolor ( 0, 0, 0, 150 ) local scale = 1.5 local font = "arial" local textWidth = dxGetTextWidth(text:gsub("#%x%x%x%x%x%x", ""), scale, font) local fontHeight = dxGetFontHeight(scale, font) local color = tocolor(255, 128, 0, 255) setElementData(getLocalPlayer(), "respawn.playing", false, true) local running = false local vehicleData = {} local SAVE_INTER = 22500 local saveTimer = nil local reset = true -- reset timer local lastSaved = 0 Link to comment
Castillo Posted August 14, 2012 Share Posted August 14, 2012 That's all wrong, read the basics and then start with something else. Link to comment
Castillo Posted August 14, 2012 Share Posted August 14, 2012 I can, but I won't, because that wouldn't be helpful, you should learn the basics. Link to comment
Callum Posted August 14, 2012 Share Posted August 14, 2012 You just need to use the aforesaid functions and incorporate all of the variables you have predefined. 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