Loading...
  OR  Zero-K Name:    Password:   

User rights config file ZK

6 posts, 510 views
Post comment
Filter:    Player:  
sort
8 years ago
Does anyone know where the user rights file in the repo is? Trying to find it, apparently someone said changing user rights to zero doesn't work.

(Sorry, really new to working with the ZK repo.)
+0 / -0
8 years ago
AH HA, a wild CommandConfig file appears!
+0 / -0
CommandConfig is not what you want. "Springie rights set to 0" is a punishment that is supposed to change rights level for a single user, changing CommandConfig would change the required level for all users.

There isn't a separate user rights file, that info is in the db as Account.SpringieLevel. There's GetEffectiveSpringieLevel() that takes punishments into account.

Springie uses User.SpringieLevel at https://github.com/ZeroK-RTS/Zero-K-Infrastructure/blob/master/Springie/Springie/autohost/AutoHost.cs#L228. That's set in zk lobby server at https://github.com/ZeroK-RTS/Zero-K-Infrastructure/blob/master/ZkLobbyServer/LoginChecker.cs#L241 and you can see it uses plain SpringieLevel instead of GetEffectiveSpringieLevel(). If you already have the testing environment up you should check if that fixes it, if not you should work on getting it up first.

One problem remains: the user will need to relogin for the punishment to take effect. That's already true for mute, so this doesn't change much, but for bonus points zkls should watch for punishment changes and update mute, springie level and kick banned users accordingly.
+0 / -0
8 years ago
So if i wanted to fix a issue where putting the user rights level to 0 did nothing, where would that be?
(fixing a issue here: https://github.com/ZeroK-RTS/Zero-K-Infrastructure/issues/663)

Thanks!
+0 / -0
Skasi
8 years ago
The ) at the end of your link is seen as part of the url when it shouldn't be. That leads to a "Page not found" error. Correct link:
https://github.com/ZeroK-RTS/Zero-K-Infrastructure/issues/663
+0 / -0


8 years ago
PLrankAdminSprung made a fix already: https://github.com/ZeroK-RTS/Zero-K-Infrastructure/pull/670/files

Setting user rights to 0 didn't "do nothing", it created a punishment entry exactly as needed, but ZKLS didn't make use of it. My previous post explains how.
+0 / -0