-
Notifications
You must be signed in to change notification settings - Fork 13
Classes
Classes are defined in the plugin's config.yml. Here's an example class:
heavy:
armor:
helmet: 306.PROTECTION_PROJECTILE-2
chest: 307.PROTECTION_PROJECTILE-2
legs: 308.PROTECTION_PROJECTILE-2
boots: 309.PROTECTION_PROJECTILE-2
inventory:
- 267.1.DAMAGE_ALL-1
- 261.1.ARROW_INFINITE-1
- 373,32757.5
- 262.1
potion-effects:
- SLOW.1.forever
Let's look at the helmet line to see how you define armor items:
helmet: 306.PROTECTION_PROJECTILE-2
306 is the item ID for the helmet - in this case, it's a iron helmet. An enchantment is then applied by adding an extra period, and the name enchantment, with a dash separating the enchantment level. In this case, a level 2 Projectile Protection enchantment is being applied to the helmet. Follow the same format for adding multiple enchantments:
helmet: 306.PROTECTION_PROJECTILE-2.PROTECTION_FIRE-1
Inventory items are given almost exactly like armor is, let's take a look at one:
267.1.DAMAGE_ALL-1
This gives the player 1 iron sword (item ID 267), with a level 1 sharpness enchantment (DAMAGE_ALL is sharpness in-game). The amount of the item is the second number, in this case they should only get 1 as it's a sword. Multiple enchantments get applied like with armor.
At the bottom is a list of potion effects. These are formatted like so:
SLOW.1.forever
That will give the player a Slowness I potion effect that lasts forever. You can also have them last a certain amount of time, for example, here's Speed II potion effect that lasts for 30 seconds:
SPEED.2.30