Jump to content

[HELP] Loginpanel Resolution


MatreN

Recommended Posts

A little example on how you make anything compatible with any resolution.

local x, y = guiGetScreenSize()
local xs, ys = 1920, 1080 -- this represents the designer's screen resolution.

--> for example we have something like:

dxDrawText(100, 200, 300, 400, ...) -- this should look fine on your screen, but not fine at all for everyone's else screen.

dxDrawText(x * (100/xs), y * (200/ys), x * (300/xs), y * (400/ys), ...) -- this should look fine both on your screen and others' screens.

 

Link to comment
5 hours ago, majqq said:

Check this topic, it's well explained, and it works very nice.

 

That topic is about event handlers how could that help to calculate the right screen position in this case?

Edited by HassoN
Link to comment

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...