Zrips / CMI

116 stars 97 forks source link

Kits conditions not use other perms #8991

Closed moda84 closed 2 months ago

moda84 commented 2 months ago

Description of Issue

Kits conditions not use other perms.

My kit:

MinerL:
  CommandName: MinerL
  Delay: 604800
  MoneyCost: 200.0
  Conditions:
  - mtlevel.donate.l
  - mtlevel.perk.miner
  Items:
    '28':
      v: 3953
      type: IRON_PICKAXE
      meta:
        ==: ItemMeta
        meta-type: UNSPECIFIC
        enchants:
          minecraft:efficiency: 3
          minecraft:unbreaking: 2
    '29':
      v: 3953
      type: DIAMOND_SHOVEL
      meta:
        ==: ItemMeta
        meta-type: UNSPECIFIC
        enchants:
          minecraft:efficiency: 3
          minecraft:unbreaking: 2
    '30':
      v: 3953
      type: PUMPKIN_PIE
      amount: 16

But player can get it only if have cmi.kit.minerl, but if player have cmi.kit.minerl and no have any perms of list of conditions, then player can claim kit.

Version Information

CMI: 9.7.4.8 SqLite
CMILib: 1.5.0.9
Server: Paper(2273) 1.21-R0.1-SNAPSHOT-
CMI economy: Disabled Vault: 1.7.3-b0-folia CMI Chat: Disabled
Modules -> 63 enabled 3 disabled: tablist, votifier, skin

Errors

No response

Relevant Config Sections

No response

Relevant Plugins

No response

Agreements

Zrips commented 2 months ago

You might be giving kit from console in which case conditions will be ignored, to check conditions you will need to add -c variable, so command should look something like /cmi kit MinerL Zrips -c, other than this regular usage of kit command or GUI clicking will check for valid conditions before giving item to the player

moda84 commented 2 months ago

I not use console. Player with conditions from kit config cant see kit in menu, but if player have cmi.kit.minerl other conditions ignored

moda84 commented 2 months ago

Hmm. now is alright thx