Package nl.minetopiasdb.api
Class Book
java.lang.Object
nl.minetopiasdb.api.Book
Class used to interact with books
-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic Book
getBooks()
Get a list of all the available booksgetDescription
(org.bukkit.entity.Player p) Get the description of this bookGet the book item name (with variables) for this book.org.bukkit.Material
The inventory material for this book (as given in the config) used for /boek opengetName()
Get the config-key (ugly name) of the book.The permission-node that is required for interacting with this book.getPrettyName
(org.bukkit.entity.Player p) Get the pretty name of this bookgetText()
The text of this book without any of the variables replacedAll the non-replaced variables of the bookboolean
If true, you'll receive 2 books when completed.void
start
(org.bukkit.entity.Player player) Start the book creation process
-
Constructor Details
-
Book
-
-
Method Details
-
getBooks
Get a list of all the available books- Returns:
- list of all the books
-
getBook
-
getName
Get the config-key (ugly name) of the book.- Returns:
- the config key for the book.
-
getItemName
Get the book item name (with variables) for this book.- Returns:
- book item name
-
getPrettyName
Get the pretty name of this book- Parameters:
p
- player needed for replacing the player-based variables- Returns:
- the pretty name of the book
-
getDescription
Get the description of this book- Parameters:
p
- player needed for replacing the player-based variables- Returns:
- the description of the book
-
getPermission
The permission-node that is required for interacting with this book.- Returns:
- the permission for this book.
-
getMaterial
public org.bukkit.Material getMaterial()The inventory material for this book (as given in the config) used for /boek open- Returns:
- bukkit material for the book
-
getText
The text of this book without any of the variables replaced- Returns:
- book contents
-
getVariables
All the non-replaced variables of the book- Returns:
- a list of the variables
-
isCopyEnabled
public boolean isCopyEnabled()If true, you'll receive 2 books when completed.- Returns:
- if you get a copy
-
start
public void start(org.bukkit.entity.Player player) Start the book creation process- Parameters:
player
- Player who needs to type all the variables.
-