Classes
Classes allow the player to pick a specific class at the beginning of the game which gives them special abilities.
Classes can be used on any map type, however care must be taken to balance them properly.
Players can then change their class in game with the /class
command.
Element | Description |
---|---|
<classes> </classes> | A node containing a single class or a group of classes. |
Sub-elements | Value/Children | |
---|---|---|
<class> </class> | A single player class. | Class Sub-elements |
Class Attributes
Attribute | Description | Value | Default |
---|---|---|---|
name | RequiredThe class's name, must be unique. | String | |
description | The description shown in the /classes command. | String | |
longdescription | The description shown in class picker menu. | String | |
icon | RequiredThe icon shown in the class picker menu. | Single Material Pattern | |
family | RequiredThe "group" of classes. | Class Family Name | |
sticky | If set to true , players cannot change the class mid-match, instead they must rejoin. | true/false | false |
default | Specify if the class is the default class for new players. One class must be set as the default. | true/false | false |
restrict | If set to true , only operators can use this class. | true/false | false |
Class Sub-elements
Element | Description | Value |
---|---|---|
<kit> | The kit given to players using this class. | Kits |
Examples
<classes family="ghost" sticky="true">
<!-- This is the default, so players will join with this unless they change class. -->
<class name="Demon" default="true" description="Smoke and Fire!" icon="fireball">
<kit>
<effect amplifier="2" ambient="true">damage resistance</effect>
<effect ambient="true">speed</effect>
<item slot="8" amount="16" material="cooked beef"/>
<item slot="1" amount="5" name="`3Grenade" grenade="true" material="ender pearl"/>
</kit>
</class>
<!-- The second class is Pyro, players can select this before joining or changing in game with /class. -->
<class name="Pyro" description="Light players on fire!" icon="flint and steel">
<kit>
<item slot="0" enchantment="fire aspect" name="`6Fire Stick" material="blaze rod"/>
<item slot="1" enchantment="arrow fire" name="`6Fire Bow" unbreakable="true" material="bow"/>
<item slot="7" amount="10" material="arrow"/>
</kit>
</class>
</classes>