public class WauzRuneBuilder
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private org.bukkit.inventory.meta.ItemMeta |
itemMeta
The item meta of the rune item.
|
private org.bukkit.inventory.ItemStack |
itemStack
The rune item stack.
|
private int |
mightStat
The might stat of the equipment.
|
WauzRune |
rune
The type of the rune to create.
|
private java.lang.String |
successString
The display of the success stat of the equipment.
|
Constructor and Description |
---|
WauzRuneBuilder(WauzRune rune)
Constructs a builder for creating a new rune item.
|
Modifier and Type | Method and Description |
---|---|
private void |
addLoreIfNotBlank(java.util.List<java.lang.String> lores,
java.lang.String lore)
Extends the lore list, if the given lore string is not blank.
|
void |
addMightStat(int mightStat)
Adds a might stat to the rune item.
|
void |
addSuccessStat(int successStat)
Adds a success stat to the equipment item.
|
org.bukkit.inventory.ItemStack |
generate(Tier tier,
Rarity rarity)
Generates the rune item stack, as configured in the builder.
|
public WauzRune rune
private org.bukkit.inventory.ItemStack itemStack
private org.bukkit.inventory.meta.ItemMeta itemMeta
private int mightStat
private java.lang.String successString
public WauzRuneBuilder(WauzRune rune)
rune
- The type of the rune to create.public void addMightStat(int mightStat)
mightStat
- The value of the stat.public void addSuccessStat(int successStat)
successStat
- The value of the stat.public org.bukkit.inventory.ItemStack generate(Tier tier, Rarity rarity)
tier
- The tier of the rune item.rarity
- The rarity of the rune item.addLoreIfNotBlank(List, String)
private void addLoreIfNotBlank(java.util.List<java.lang.String> lores, java.lang.String lore)
lores
- The list of lores.lore
- The lore to add.