Eistee Posted June 16, 2013 Share Posted June 16, 2013 hello, ich have created a image in "absolut" picture = guiCreateStaticImage(317, 171, 835, 117, "picture .png", false) How i set the picture so, that the picture is on the same place in all resolutions? Link to comment
iPrestege Posted June 16, 2013 Share Posted June 16, 2013 You can use relative option from guieditor resource it's not good every time but it's not bad too . Link to comment
Eistee Posted June 16, 2013 Author Share Posted June 16, 2013 When i use relativ, its not on the same place, on other resolutions.. Link to comment
DNL291 Posted June 16, 2013 Share Posted June 16, 2013 Divide each of the picture's position values by the screen size manually. And put it multiplied by the your screen width and height. local swidth, sheight = guiGetScreenSize() local X = 317/yourScreenWidth = value local Y = 171/yourScreenHeight = value local width = 835/yourScreenWidth = value local height = 117/yourScreenHeight = value picture = guiCreateStaticImage(swidth*valueX, sheight*valueY, swidth*valueWidth, sheight*valueHeight, "picture .png", false) 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