Jump to content

how to calculate HUD coordinates


Kaneki16

Recommended Posts

Step 1. Download guieditor script, make everything you need here, copy your code.

Step 2. Paste this before your dxDraw functions

local sx,sy = guiGetScreenSize()
local px,py = 1366,768 -- replace 1366, 768 with your resolution
local x,y =  (sx/px), (sy/py)

Step 3. For example you got this

dxDrawRectangle(200,400,100,500)

replace coordinates like this

dxDrawRectangle(x*200,y*400,x*100,y*500)

and that's it.

Easy, isn't it?

Link to comment
  • 2 years later...

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...