I just took a quick look at what Kameleon has sent me.
First thing I noticed: DCMoD uses a command called "dccvar" to set the bitvalues for each rank. In the config I received it looked like this:
Code: Select all
dccvar dc_hcrights "ALL +SECRET +PROTECT +CHEATS +FLY"
The command however seems to only work without quotationmarks. Whenever I tried using it with quotes (") it just set the same value the cvar had before. When using the command like the following I got the same results for all ranks:
Code: Select all
dccvar dc_hcrights ALL +SECRET +PROTECT +CHEATS +FLY
But that's not the issue we are discussing here, only the reason for different results with different adminlevels. I have tried the above permissions on the following jk2mv versions from the official dedicated server downloads:
- jk2mvded-v1.2.1-win32-x64.exe
- jk2mvded-v1.2.1-win32-x86.exe
- jk2mvded-v1.2.1-linux-amd64 (using the Windows-Subsystem for Linux)
- jk2mvded-v1.3-win32-x64.exe
- jk2mvded-v1.3-win32-x86.exe
- jk2mvded-v1.3-linux-amd64 (using the Windows-Subsystem for Linux)
The "dccvar" command sets the bitvalue for the specified cvar to the same value on all of those jk2mv versions, as well as jk2Ded.exe.
However the bitvalues in jk2mvded 1.3 seem to be interpreted differently.
When using "dccvar dc_sarights ROB" it assigns the value 33554432 to dc_sarights, which grants level 1 the "ROB" command group (amrob), this works on all dedicated server versions.
When manually assigning the value 33554431 (one lower than ROB) to a level it should grant all command groups with values lower than ROB (1=SILENCE, 2=SLEEP, 4=FREEZE, 8=KICK, 16=GET, 32=PSAY, ...) to that level, but on jk2mv 1.3 it grants ROB to the admin.
Another interesting part is that the "dccvar" command prints all available commands when used like this:
and for 33554431 it shows
Code: Select all
amsilence, amunsilence, amsleep, amwake/amunsleep, amfreeze, amunfreeze, amkick, amget, amgoto/amtakemeto, ampsay, ammotd, amAAlist, amAAstatus, amban, amkickban, amaddip, amlistip, amremoveip, amslap, amsummon, amrelease, am***, am****, amempower, amunempower, amterminator, amunterminator, amren/amrename, amtimescale, amorigin, amtele, ammake, amtoggle, amAAmanage, amAAadd, amAAclear, amAAignore, amAAunignore, amAAenforce, amAAunenforce, ambanname, amunbanname, ambanteam, amunbanteam, ambanforce, amunbanforce, ambantoggle, amunbantoggle, ambankill, amunbankill, amhunted, amunhunted, amstatus, aminfo, amcheckip, amcvar, amrcon, amexplode
, just like expected. But the ingame admin only gets ROB.
So I guess the ingame system uses another function to check permissions than the "dccvar" command, but without the source code it's hard to figure out what it does and why it fails on jk2mvded 1.3. However as it seems that the issue only exists on jk2mv 1.3 (x86, x64, amd64) I think it's worth looking into it.
//Edit: We looked into it and fau found the cause. It's a bug in jk2mv 1.3. Thanks for finding and reporting this one!
//Edit2: Latest development builds should have a fix (as of 1.3-29-g5593e50). If someone wants to try it themselves:
https://jk2mv.org/builds/