papam77 Posted October 12, 2013 Share Posted October 12, 2013 local sX, sY = guiGetScreenSize () -- sY = UP -- sX = SIDES function header () dxDrawRectangle ( sX/1920, sY/25*100, sX/50, sY/3, tocolor ( 0, 125, 255, 255 ) ) end addEventHandler("onClientRender", root, header ) Hello, Why 25*100 doesn't work? Now i have to use 2500 to hit this upper side. http://www.img.tpx.cz/uploads/hitthis.png I do not know why, but i have to use big numbers to get this position, I mean the red upper line. Link to comment
csiguusz Posted October 12, 2013 Share Posted October 12, 2013 This is just math: sY/25*100 doesn't mean sY/(25*100), it means (sY/25)*100 and they are not the same. So use sY/(25*100). 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