Only wood autocompressor shows when you do the command and not the diamond one
Code:
command /acs:
trigger:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&4Not Unlocked"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&4Not Unlocked"
open (metadata tag "acs" of player) to player
if {diamondautocompressoreligibility::%player%} is true:
if {diamondautocompress::%player%} is false:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&4Autocompressor Off"
open (metadata tag "acs" of player) to player
if {diamondautocompressoreligibility::%player%} is true:
if {diamondautocompress::%player%} is true:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&2Autocompressor On"
open (metadata tag "acs" of player) to player
if {diamondautocompressoreligibility::%player%} is false:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&4Not Unlocked"
open (metadata tag "acs" of player) to player
if {woodautocompressoreligibility::%player%} is true:
if {woodautocompress::%player%} is false:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&4Autocompressor Off"
open (metadata tag "acs" of player) to player
if {woodautocompressoreligibility::%player%} is true:
if {woodautocompress::%player%} is true:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&2Autocompressor On"
open (metadata tag "acs" of player) to player
if {woodautocompressoreligibility::%player%} is false:
set metadata tag "acs" of player to chest inventory with 3 rows named "&bAutoCompressors"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&4Not Unlocked"
open (metadata tag "acs" of player) to player
variables:
{diamondautocompress::%player%} = false
{diamondautocompressoreligibility::%player%} = false
on inventory click:
if event-inventory = (metadata tag "acs" of player):
cancel event
if event-inventory = (metadata tag "acs" of player):
if event-inventory = (metadata tag "acs" of player):
if index of event-slot is 13:
if {diamondautocompressoreligibility::%player%} is true:
if {diamondautocompress::%player%} is false:
wait 1 ticks
set {diamondautocompress::%player%} to true
send "Autocompressor Turned On"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&2Autocompressor On"
on inventory click:
if event-inventory = (metadata tag "acs" of player):
cancel event
if event-inventory = (metadata tag "acs" of player):
if index of event-slot is 13:
if {diamondautocompressoreligibility::%player%} is true:
if {diamondautocompress::%player%} is true:
wait 1 ticks
set {diamondautocompress::%player%} to false
send "Autocompressor Turned Off"
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&4Autocompressor Off"
else:
set {diamondautocompress::%player%} to false
send "You haven't unlocked this yet"
cancel event
set slot 13 of metadata tag "acs" of player to a diamond named "&bDiamond Autocompressor" with lore "&4Not Unlocked"
on break:
if {diamondautocompress::%player%} is true:
if player has 64 diamonds named "<bold>Diamond":
set {_diamond} to number of diamonds named "<bold>Diamond" in player's inventory
set {_diamond} to {_diamond} / 64
remove ({_diamond} * 64) of diamonds named "<bold>Diamond" from the player
give {_diamond} of diamond of mending named "&b<bold>Compressed Diamond" to player's inventory
on right click:
if player's held item is a book named "&2Diamond Autocompressor Pass":
if {diamondautocompressoreligibility::%player%} is false:
set {diamondautocompressoreligibility::%player%} to true
send "&9<bold>Diamond AutoCompressor Unlocked!" to player
remove held item from player
else:
send "&4<bold>AutoCompressor is already unlocked!" to player
command /getallbooks:
permission: op
trigger:
give player book named "&2Diamond Autocompressor Pass"
give player book named "&2Wood Autocompressor Pass"
command /getallrevokes:
permission: op
trigger:
give player book named "&4Diamond Autocompressor Revoker"
give player book named "&4Wood Autocompressor Revoker"
on right click:
if player's held item is a book named "&4Diamond Autocompressor Revoker":
if {diamondautocompressoreligibility::%player%} is true:
set {diamondautocompressoreligibility::%player%} to false
send "&9<bold>Diamond AutoCompressor Revoked!" to player
remove held item from player
else:
send "&4<bold>You Don't have the autocompressor unlocked" to player
on break of diamond ore:
if player's tool is a pickaxe:
give player (1 + (level of fortune of player's tool)) of diamonds named "<bold>Diamond"
cancel event
variables:
{woodautocompress::%player%} = false
{woodautocompressoreligibility::%player%} = false
on inventory click:
if event-inventory = (metadata tag "acs" of player):
cancel event
if event-inventory = (metadata tag "acs" of player):
if index of event-slot is 10:
if {woodautocompressoreligibility::%player%} is true:
if {woodautocompress::%player%} is false:
wait 1 ticks
set {woodautocompress::%player%} to true
send "Autocompressor Turned On"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&2Autocompressor On"
on inventory click:
if event-inventory = (metadata tag "acs" of player):
cancel event
if event-inventory = (metadata tag "acs" of player):
if index of event-slot is 10:
if {woodautocompressoreligibility::%player%} is true:
if {woodautocompress::%player%} is true:
wait 1 ticks
set {woodautocompress::%player%} to false
send "Autocompressor Turned Off"
set slot 10 of metadata tag "acs" of player to oak log named "&bWood Autocompressor" with lore "&4Autocompressor Off"
else:
set {woodautocompress::%player%} to false
send "You haven't unlocked this yet"
cancel event
on break:
if {woodautocompress::%player%} is true:
if player has 64 oak logs named "<bold>Oak Wood Log":
set {_wood} to number of oak logs named "<bold>Oak Wood Log" in player's inventory
set {_wood} to {_wood} / 64
remove ({_wood} * 64) of oak logs named "<bold>Oak Wood Log" from the player
give {_wood} of oak log of mending named "&b<bold>Compressed Wood" to player's inventory
on right click:
if player's held item is a book named "&2Wood Autocompressor Pass":
if {woodautocompressoreligibility::%player%} is false:
set {woodautocompressoreligibility::%player%} to true
send "&9<bold>Wood AutoCompressor Unlocked!" to player
remove held item from player
else:
send "&4<bold>AutoCompressor is already unlocked!" to player
on right click:
if player's held item is a book named "&4Wood Autocompressor Revoker":
if {woodautocompressoreligibility::%player%} is true:
set {woodautocompressoreligibility::%player%} to false
send "&9<bold>Wood AutoCompressor Revoked!" to player
remove held item from player
else:
send "&4<bold>You Don't have the autocompressor unlocked" to player
on break of oak log:
if player's tool is an axe:
cancel drops
give player (1 + (level of fortune of player's tool)) of oak logs named "<bold>Oak Wood Log"
on break of oak log:
cancel drops
give player (1 + (level of fortune of player's tool)) of oak logs named "<bold>Oak Wood Log"