aboutsummaryrefslogtreecommitdiff
path: root/features/betterGuis/museumGui.js
diff options
context:
space:
mode:
authorSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-01-20 17:30:44 +0800
committerSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-01-20 17:30:44 +0800
commit30e6cde8110b75dada8e6c3c01456245ab990011 (patch)
tree6443fff1990dfa246c59d7ca604208e4ca3e4f1b /features/betterGuis/museumGui.js
parent0a390f63ed58c95ca5cf6422580288fd4fac6912 (diff)
downloadSoopyV2-30e6cde8110b75dada8e6c3c01456245ab990011.tar.gz
SoopyV2-30e6cde8110b75dada8e6c3c01456245ab990011.tar.bz2
SoopyV2-30e6cde8110b75dada8e6c3c01456245ab990011.zip
fix ct 2.0 issues with museum gui (soopyv2 will probs no longer work on ct 1.3)
Diffstat (limited to 'features/betterGuis/museumGui.js')
-rw-r--r--features/betterGuis/museumGui.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/features/betterGuis/museumGui.js b/features/betterGuis/museumGui.js
index f652cf3..d2756da 100644
--- a/features/betterGuis/museumGui.js
+++ b/features/betterGuis/museumGui.js
@@ -436,11 +436,11 @@ class MuseumGui {
if(!this.searchText){
if(currPage > 1){
this.previousButton.visable = true
- if(Player.getOpenedInventory().getStackInSlot(45).getID() !== -1) this.previousButton.setLore(Player.getOpenedInventory().getStackInSlot(45).getLore())
+ if(Player.getOpenedInventory().getStackInSlot(45)) this.previousButton.setLore(Player.getOpenedInventory().getStackInSlot(45).getLore())
}
if(currPage < pageNum){
this.nextButton.visable = true
- if(Player.getOpenedInventory().getStackInSlot(53).getID() !== -1)this.nextButton.setLore(Player.getOpenedInventory().getStackInSlot(53).getLore())
+ if(Player.getOpenedInventory().getStackInSlot(53))this.nextButton.setLore(Player.getOpenedInventory().getStackInSlot(53).getLore())
}
}
@@ -549,7 +549,7 @@ class MuseumGui {
this.itemsBox.addChild(itemBox)
}
- if(Player.getOpenedInventory().getStackInSlot(24).getID() !== -1 && Player.getOpenedInventory().getStackInSlot(20).getID() !== -1){
+ if(Player.getOpenedInventory().getStackInSlot(24) && Player.getOpenedInventory().getStackInSlot(20)){
let cancelButton = new ButtonWithArrow().setText("§cCancel").setLocation(0.1,0.4,0.35,0.2).setDirectionRight(false).setLore(Player.getOpenedInventory().getStackInSlot(24).getLore())
cancelButton.addEvent(new SoopyMouseClickEvent().setHandler(()=>{