Bug when user is revoked from vip groupSolved

Hello,

  "Protection settings": {
    "Protection levels": {
      "0": {
        "Online protection percentage (0-100)": 0.0,
        "Offline protection percentage (0-100)": 30.0
      },
      "1": {
        "Online protection percentage (0-100)": 60.0,
        "Offline protection percentage (0-100)": 100.0
      },
      "2": {
        "Online protection percentage (0-100)": 75.0,
        "Offline protection percentage (0-100)": 100.0
      }, 
    },​
raidprotection.level.0 set to default group
raidprotection.level.1 set to vip group
raidprotection.level.2 set to helper group

when user is revoked from vip, he have always raidprotection.level.1
o.show user Taz
Player 'Taz (765611XXXXXXXXXXX)' permissions:
autolocker.use, quicksmelt.use, removertool.normal, skinbox.use, baserepair.use, raidprotection.level.0, EntityLimit.default, signartist.url, signartist.text


Player 'Taz (765611XXXXXXXXXXX)' groups:
default


 Group 'default' players:
76561############ (Taz)

Group 'default' permissions:
autolocker.use, quicksmelt.use, removertool.normal, skinbox.use, raidprotection.level.0, EntityLimit.default

o.show group vip
Group 'vip' players:
765611981XXXXXXXX (Anais)

Group 'vip' permissions:
removertool.vip, skinbox.vip, instantcraft.use, raidprotection.level.1, EntityLimit.vip


o.show group helper
Group 'helper' players:
765611981XXXXXXXX (Funky Woozy)

Group 'helper' permissions:
removertool.helper, skinbox.helper, instantcraft.use, raidprotection.level.2, EntityLimit.vip

 

o.revoke user Taz raidprotection.admin
Player 'Taz' does not have permission 'raidprotection.admin'
> o.revoke group admin raidprotection.admin
Group 'admin' does not have permission 'raidprotection.admin'
> o.revoke group vip raidprotection.admin
Group 'vip' does not have permission 'raidprotection.admin'
> o.revoke group helper raidprotection.admin
Group 'helper' does not have permission 'raidprotection.admin'

XtNsk8Y3AkW4vPJ.png

Player disconnected from server after vip ended

Is not when vip is revoked, the bug appear when you y've multiple level:

    "Protection levels": {
      "0": {
        "Online protection percentage (0-100)": 0.0,
        "Offline protection percentage (0-100)": 30.0
      }
    },​
work fine, return 30%

    "Protection levels": {
      "0": {
        "Online protection percentage (0-100)": 0.0,
        "Offline protection percentage (0-100)": 30.0
      },
      "1": {
        "Online protection percentage (0-100)": 60.0,
        "Offline protection percentage (0-100)": 100.0
      }
    },​
return 60% as in the previous screenshot
 


Merged post

ok, saw in description (din't see the first time) :
  • If a player is assigned multiple protection levels, the highest one is the one that will be used (even if its worse)
Locked automatically