Hello!
First time posting here I think, I'm kinda new to Lua.
So I started doing stuff with dxDrawImage and DrawText, and I am a little bit confused right now.
Not sure if it should work or not, but the images are centered and working alright on every resolution, but the text and the "button" is not behaving how it supposed to.
dxDrawText("Text here", sWidth/2.199, sHeight/1.29, 177, 14, ... )
I tried doing the positioning in 2 ways. The texts left upper corner should be at 873x837 on 1920x1080 resolution. It works well on that, but not with the others, it goes further away the lower I go. The same with the box, which I'm not gonna include that here, I don't think it's neccessery.
So the way I calculated it was like this: 1920/873 which is 2.199. I tried to do it the otherway around, and multiply it by 0,45xxx but it's the same. Here are 2 pictures of how it should look, and how it looks like:
1920x1080: https://puu.sh/w9bmU/b759ec873f.jpg
1152x864: https://puu.sh/w9bkN/3dc163c128.jpg
Here is the working picture:
dxDrawImage(sWidth/2-204,sHeight/2-404,409,809,...)
It is centered on every resolution. I also tried doing sWidth/2.199-88 and sHeight/1.29-7 but didn't help it. It's probably something really obvious but I just can't see it. Or is it the counting thats not right? I saw it in a video a long time ago which I can't find anymore, might have misunderstood something or I can't remember it that well.