Forum

> > CS2D > Scripts > [Script] Text fixed in designated coordinates
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch [Script] Text fixed in designated coordinates

Keine Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt [Script] Text fixed in designated coordinates

_oops
User Off Offline

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

IMG:https://i.imgur.com/IsQoksn.gif


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

IMG:https://i.imgur.com/rqJpVq0.gif


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
----------------------EDIT---------------------
fixed, with naive approach
2× editiert, zuletzt 22.06.19 20:36:39
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht