Skip to content

Commands and Permissions

AshleyThew edited this page Jul 5, 2026 · 1 revision

Commands and Permissions

Overview

Bank command and permission behavior is split into command and permission subsystems. Admins can tune both without code changes.

How It Works

Command root is /bank. Subcommands are loaded from BankCommandConfiguration and runtime config, with player checks for disabled worlds/gamemodes.

Subsystem split:

  • Command token subsystem (conf/commands.yml): command words, aliases, node names.
  • Permission-check subsystem (conf/permissions.yml): feature gates and value-prefix checks.
  • Open access subsystem (Bank.Type.* and Bank.Opentype.Subset.*): where open routes are allowed.

Configuration

Primary files:

  • conf/commands.yml: command words, aliases, permission nodes, argument info.
  • conf/permissions.yml: non-command permission checks (open types, slot/tabs, interest tiers, loan tiers).

Reference files:

Command branch baseline:

Bank:
  Command: bank
  Argument:
    Open:
      Command: open
      Permission: bank.open.command

Permission check baseline:

Permission:
  Open:
    Sign:
      Check: true
      Permission: bank.open.sign

Admin alignment checklist:

  1. Enable command path in conf/commands.yml.
  2. Grant matching permission node to target group.
  3. Ensure behavior-level checks in conf/permissions.yml do not block the action.
  4. If using subset restrictions, verify Bank.Opentype.Subset.* permits the intended open target.

Commands

Player command groups:

  • /bank info
  • /bank open
  • /bank money ...
  • /bank exp ...
  • /bank cheque ...
  • /bank top ...

Admin command groups:

  • /bank admin reload|save|reset|open|force open|lock|lookup
  • /bank admin money ...
  • /bank admin exp ...
  • /bank admin slots ...
  • /bank admin item ...
  • /bank admin permission ...
  • /bank admin tax ...
  • /bank admin npc setopentypes ...
  • /bank admin block add|remove
  • /bank eco give|set|take

Admin quick command matrix:

Goal Command Typical args
Save all data now /bank admin save -
Reload config and systems /bank admin reload -
Inspect player bank /bank admin open <player>
Force-open bypass /bank admin force open <player>
Unlock/lock account /bank admin lock <player> <true/false>
Correct money /bank admin money add <player> <amount>
Correct exp /bank admin exp add <player> <amount>
Register bank block /bank admin block add -
Set NPC open types /bank admin npc setopentypes [types...]

Important current behavior:

  • commands.yml currently maps both Admin > Tax > Info and Admin > Tax > Withdraw to command token withdraw.

Permissions

Examples from generated config:

  • Command: bank.money, bank.money.deposit, bank.admin.reload
  • Feature access: bank.open.sign, bank.open.citizens, bank.items.deposit, bank.items.withdraw
  • Permission-value prefixes: bank.loan.amount., bank.loan.interest., bank.item.slots., bank.tabs., bank.money.interest.online.

Permission prefix subsystems

  • Loan bounds: bank.loan.amount.*, bank.loan.interest.*
  • Item capacity: bank.item.slots.*, bank.tabs.*
  • Interest rate tiers: bank.money.interest.*, bank.exp.interest.*

Data and Storage

No command metadata is stored in player data. Command behavior is configuration-backed.

Examples

  • Give player money command access only:
    • enable Bank > Money command nodes in conf/commands.yml
    • grant bank.money and needed children
  • Permit 18 tabs through permission system:
    • grant bank.tabs.18

Restrict direct open commands to money only:

  1. Enable subset system in config.yml.
  2. Enable command subset channel with Bank.Opentype.Subset.Command.Enabled: true.
  3. Grant only needed open command nodes (for example bank.open.command.money) from conf/commands.yml.
  4. Test as normal player.
Bank:
  Opentype:
    Subset:
      Enabled: true
      Command:
        Enabled: true

Troubleshooting

  • Command appears but fails permission: verify both node grant and conf/permissions.yml checks.
  • Console open subset fails: verify Bank.Opentype.Subset.Command.Enabled.

Related Pages

Clone this wiki locally