After Effect System
After consuming the potion, you can configure a countdown, to issue some commands. For example, you can do some potion that gives permission for only 4 minutes. You can give the permission in before drinking, and remove the permission after 4 minutes in "After Effect" commands.
Variable
Description
Example/Expected Value
enabled
Whether it is enabled or not.
true/false
time
Time in seconds.
200
With our final update to the configuration, our potion is officially done!
flight:
displayName: '&6Flight Potion'
lore:
- '&9Food & Drinks'
- '&9Flight I (04:00)'
isSplash: false
deleteBottle: false
instantDrink: false
cooldown: 480
data:
potionType: LUCK
particle:
enabled: true
type: EFFECT
time: 240
amount: 50
commands:
afterEffect:
enabled: true
time: 240
commands:
'1':
commands:
- fly %player% disable
- w %player% You're starting to feel pretty normal again. Perhaps another potion?
executor: CONSOLE
drinkingCommands:
'1':
commands:
- fly %player% enable
- w %player% You get this whimsical feeling flowing through your body.. you're glowing.. and you can fly!!
- effect give %player% minecraft:glowing 300
executor: CONSOLE
Last updated