MantisBT - Zandronum
View Issue Details
0003054Zandronum[All Projects] Bugpublic2017-04-09 21:562018-09-30 21:47
Korshun 
Torr Samaho 
normalminoralways
closedfixed 
3.0-beta 
3.03.0 
0003054: Using GetCVar clientside with user cvars is broken in 3.0
In 2.1.2, using GetCVar("some_user_cvar") clientside will return the cvar's value. In 3.0, it returns 0.

This means that all 2.1.2 mods that are currently using GetCVar clientside with user cvars will need to replace GetCVar("some_user_cvar") with GetUserCVar(ConsolePlayerNumber(), "some_user_cvar") to work in Zandronum 3.0.
No tags attached.
related to 0002634closed  CLIENTSIDE SetMusic() or CVARINFO not working. 
? user_getcvar_clientside.wad (824) 2017-04-10 20:50
/tracker/file_download.php?file_id=2059&type=bug
Issue History
2017-04-09 21:56KorshunNew Issue
2017-04-10 17:44Torr SamahoNote Added: 0017120
2017-04-10 18:31Torr SamahoAssigned To => Torr Samaho
2017-04-10 18:31Torr SamahoStatusnew => feedback
2017-04-10 20:50KorshunFile Added: user_getcvar_clientside.wad
2017-04-10 20:50KorshunNote Added: 0017121
2017-04-10 20:50KorshunStatusfeedback => assigned
2017-04-15 09:46Torr SamahoNote Added: 0017132
2017-04-15 09:47Torr SamahoStatusassigned => needs testing
2017-04-15 09:47Torr SamahoTarget Version => 3.0
2017-04-16 07:03Torr SamahoRelationship addedrelated to 0002634
2017-04-16 12:24KorshunNote Added: 0017150
2017-04-17 14:40Ru5tK1ngStatusneeds testing => resolved
2017-04-17 14:40Ru5tK1ngResolutionopen => fixed
2017-04-17 14:40Ru5tK1ngFixed in Version => 3.0
2018-09-30 21:47Blzut3Statusresolved => closed

Notes
(0017120)
Torr Samaho   
2017-04-10 17:44   
We discussed about this issue in 0002634:0016395, I'm still open to add the fallback option mentioned in 0002634:0016403 though. Can you post a minimal example wad? Then I'll look into this.
(0017121)
Korshun   
2017-04-10 20:50   
You are right that it turns out it doesn't break if the player is the activator.

Attached an example wad that does SetActivator(-1) and then calls GetCVar("some_user_var").
(0017132)
Torr Samaho   
2017-04-15 09:46   
Should work as in 2.1.2 again now.
(0017150)
Korshun   
2017-04-16 12:24   
Fixed in 170416-0710. The fix works in my mod.