Page 1 of 1
Client Side Custom CVARs?
Posted: Tue Apr 01, 2014 8:04 pm
by XutaWoo
Quick question, since I'm not sure where to check: Is there a way to GetCVAR the client's CVAR? I'm asking because I'm trying to implent a strictly player-based option ( display their team's object health as a percentage instead of a raw value ) and I can't really use my ZDoom knowledge here.
Thanks in advance.
RE: Client Side Custom CVARs?
Posted: Tue Apr 01, 2014 8:43 pm
by Ijon Tichy
Look at Samsara's ACS for that. Basically, you need a clientside OPEN script that reads off the client CVars, packs them off somehow (booleans are easy enough, and for other crap you'll likely need multiple invocations), and uses StrParam with ConsoleCommand to puke net scripts to tell the server what that client has its CVars set to. Ideally, only do it on connect, and when the values change (Samsara has it easy as it only uses boolean CVars).
Roundabout as hell, but it works.
I'm not even sure how ZDoom handles user CVars in ACS online!
RE: Client Side Custom CVARs?
Posted: Tue Apr 01, 2014 9:12 pm
by XutaWoo
... I think I'll just wait until CVARINFO hits the scene.
Thanks for the quick answer, though! :p
RE: Client Side Custom CVARs?
Posted: Wed Apr 02, 2014 1:44 am
by Ijon Tichy
XutaWoo wrote:
... I think I'll just wait until CVARINFO hits the scene.
So five years?
RE: Client Side Custom CVARs?
Posted: Wed Apr 02, 2014 1:45 am
by XutaWoo
Ijon Tichy wrote:
XutaWoo wrote:
... I think I'll just wait until CVARINFO hits the scene.
So five years?
It's merely for personal preference when it comes to aesthetics anyway, so I don't think that's too big of an issue. :P