feat(anvil): set interactable slots
This commit is contained in:
parent
9b840ee53f
commit
8c59dae6ae
1 changed files with 3 additions and 0 deletions
|
@ -40,6 +40,7 @@ public class AnvilManager {
|
|||
return new AnvilGUI.Builder()
|
||||
.plugin(NickoBukkit.getInstance())
|
||||
.itemLeft(getLeftItem(false))
|
||||
.interactableSlots(AnvilGUI.Slot.OUTPUT)
|
||||
.onComplete((completion) -> {
|
||||
if (MojangUtils.isUsernameInvalid(completion.getText())) {
|
||||
return Collections.singletonList(AnvilGUI.ResponseAction.replaceInputText("Invalid username!"));
|
||||
|
@ -56,6 +57,7 @@ public class AnvilManager {
|
|||
return new AnvilGUI.Builder()
|
||||
.plugin(NickoBukkit.getInstance())
|
||||
.itemLeft(getLeftItem(false))
|
||||
.interactableSlots(AnvilGUI.Slot.OUTPUT)
|
||||
.onComplete((completion) -> {
|
||||
if (MojangUtils.isUsernameInvalid(completion.getText())) {
|
||||
return Collections.singletonList(AnvilGUI.ResponseAction.replaceInputText("Invalid username!"));
|
||||
|
@ -72,6 +74,7 @@ public class AnvilManager {
|
|||
return new AnvilGUI.Builder()
|
||||
.plugin(NickoBukkit.getInstance())
|
||||
.itemLeft(getLeftItem(true))
|
||||
.interactableSlots(AnvilGUI.Slot.OUTPUT)
|
||||
.onComplete((completion) -> {
|
||||
if (MojangUtils.isUsernameInvalid(completion.getText())) {
|
||||
return Collections.singletonList(AnvilGUI.ResponseAction.replaceInputText("Invalid username!"));
|
||||
|
|
Loading…
Reference in a new issue