ClassManagerpublic class CoreClassManager extends java.lang.Object implements ClassManager
| Constructor | Description |
|---|---|
CoreClassManager(Game game) |
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
deleteClass(java.lang.String name) |
Deletes a class from memory and storage with the specified name.
|
GameClass |
getClass(java.lang.String name) |
Returns the GameClass object with a specific name.
|
org.bukkit.inventory.ItemStack |
getClassSelector() |
Gets the class selector item, which may be clicked to open the class selection menu.
|
GameClass |
getRandomClass(GamePlayer player) |
Scans classes in a random order for one the player has permission for.
|
void |
loadClasses() |
Loads classes from the classes.yml file, which is contained in the resources folder of the game.
|
void |
openGUI(GamePlayer player) |
Opens the class selection GUI for a specific entity.
|
public CoreClassManager(Game game)
public void loadClasses()
ClassManagerloadClasses in interface ClassManagerpublic void openGUI(GamePlayer player)
ClassManageropenGUI in interface ClassManagerplayer - the GamePlayer object of the entity to open the GUI forpublic GameClass getClass(java.lang.String name)
ClassManagergetClass in interface ClassManagername - the name of the desired classpublic boolean deleteClass(java.lang.String name)
ClassManagerdeleteClass in interface ClassManagername - the name of the class to deletepublic GameClass getRandomClass(GamePlayer player)
ClassManagergetRandomClass in interface ClassManagerplayer - the player to find a class forpublic org.bukkit.inventory.ItemStack getClassSelector()
ClassManagergetClassSelector in interface ClassManager