English [Script] Text fixed in designated coordinates

No replies
Goto Page
To the start Previous 1 Next To the start
Offline Off
Previously I made a thread about asking thread cs2d [Script] Hudtxt stays in given coordinates.

I faced an issue when the player has different resolution other than default resolution.


This is show-case of default resolution, texts were stably positioned.


But when I use different resolution, it becomes like this.

The formula that I wrote in code is this.

x = ( x - player(player_id,"x"))+ (player(player_id,"screenw")/2)
y = ( y - player(player_id,"y")) + (player(player_id,"screenh")/2)

I read some similar scripts in file archive but could not find an explicit solution they are mostly outdated. ( before resolution update )

any hints?

I don't really want to use the mp_hudscale command, it's really ugly. and breaking all hudtxt / hud images that I used in the game
fixed, with naive approach
edited 2×, last 22.06.19 08:36:39 pm
Lastest upload : file cs2d CSGO Graffiti Pack II (12)
To the start Previous 1 Next To the start