Mimu Bot
  • overview
  • command list
  • ⚙️Settings
    • getting started
      • currency / economy
      • activity + pick spawn
      • greet / leave / boost messages
      • deny commands
      • custom formatting
  • Currency System
    • getting started
    • setting up a server shop
  • 💸global currency
    • tickets
      • pets
        • taking care of your pet
    • stars
      • activity classes
  • autoresponder
    • your first autoresponder
    • guides
      • beginner i: using simple placeholders
      • beginner ii: using simple functions
      • intermediate i: ranges and making choices
      • intermediate ii: locked choices
      • advanced i: different matchmodes
      • advanced ii: using user arguments
      • advanced iii: modifying inventory and using args
      • expert i: static button responders
      • expert ii: instanced button responders
    • resources
      • variables - placeholders & functions
      • examples
        • custom currency command examples
          • .bake command
          • .bake command with items
          • .harvest command
          • .stealcookie command
          • .crime command
          • .steal [user] [amount] command
          • .sell command
        • manager/moderation commands
          • self-verification system
            • click a button to verify
            • type "i agree" to verify
          • manual verification system
          • self assignable roles
            • button roles
            • command roles (type +role)
            • command x button roles
          • .roleadd [user] [role] command
          • antiswear/blacklisted words
          • anti link/advertising
          • change to appropriate nickname command
          • .setnick [user] [nickname] command
          • click to disable pings (e.g. partner pings)
        • utility/fun commands
          • .serverinfo command
          • .nick [nickname] command
          • .suggest [text] command
          • .say commands
          • embed reaction command
          • embed action command (user arguments)
          • partner manager reward system
          • would you rather/.topic command
          • .poke [user] command
          • .8ball [text] command
          • mimu, rate [thing] command
          • .muteroulette [user] [user]... command
  • 🛄embeds
    • your first embed
    • embed guide
      • general/nonspecific embed
      • greet/welcome embed
      • leave/goodbye embed
      • rules embed
      • boost embed
  • 🔗quick links
    • ♡ support server
    • ♡ status page
    • ♡ feedback site
  • other
    • [03/2024] v8.10 - leaving patreon and restructuring supporter tiers
      • changelog & details
      • terms of purchasing, refunds, etc.
      • swapping over as an existing patron: early patron badge & more!
      • why are you moving away? what about the donation site?
Powered by GitBook
On this page
  • ✎ the {modifyinv:} variable
  • ✎ what does this have to do with user arguments?

Was this helpful?

  1. autoresponder
  2. guides

advanced iii: modifying inventory and using args

Previousadvanced ii: using user argumentsNextexpert i: static button responders

Last updated 1 year ago

Was this helpful?

  • this page utilizes concepts and functions found on our guide.

  • if you haven't visited or don't fully understand that page yet, return to this after you do!

for inventory commands, make sure you have items added to your shop before continuing!

✎ the {modifyinv:} variable

  • the variable itself isn't very complex for basic usage! but, when combined with user arguments, it can get messy really quickly.

  • this variable modifies the inventory of a user by either adding or removing an item from a user's /balance , under the "inventory" field.

  • the command accepts 3 options: {modifyinv: [item name/ID] | [+/- quantity] | <user>}

if using an item name in the variable, the name must be exact. for example, if I have an item named "chocolate chip cookie", the variable must be {modifyinv: chocolate chip cookie | 1}, not {modifyinv: cookie | 1} or any other variants. for this reason, we always recommend using the item's ID option.

  • notice: the user option is optional. you must have an item name/ID and quantity in the variable when using it.

✎ what does this have to do with user arguments?

  • you're probably thinking, "oookay, so why is this more advanced?"

  • the concept in practice can get very tricky for beginners, especially as we introduce user arguments.

  • let's say I want to make a command called .shake tree that requires another user. this command will give an item for both users /autoresponder add trigger:.shake trees reply:{requirearg: 1 | user}{range:2-10}{embed}{modifyinv: coconut | 1}{modifyinv: coconut | 1 | [$1]} you shook a tree . . . [range] coconuts fell out! you each took one and stashed it in your inventory. /autoresponder editmatchmode trigger:.shake trees matchmode:startswith

  • now, check your inventory to see the item added by using /inventory ; or, alternatively, using /balance, then clicking the blue button with a box.

  • the item "coconut" was added to both users - the user who ran the command, and the user that was mentioned in the command.

  • you can even take it a step further, requiring items using {requireitem:} or displaying both users' current amount of the item by adding {user_item_count: coconut} and {user_item_count: coconut | [$1]} to the autoresponder's reply.

we highly recommend requiring items when modifying someone's inventory, specifically if removing items. users cannot have negative amounts of an item in their inventory, so if removing an item, it will remove only what they have.

advanced ii: using user arguments
the command after use
the button at the bottom of /balance