Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- variables:
- {orange} = orange stained glass pane
- {red} = red stained glass pane
- options:
- mainguiname: <##ff4d00>&lᴇᴍᴘʏʀᴇᴀɴ <##ff6800>| <##ff8330>ᴇɴᴄʜᴀɴᴛᴇʀ
- guiname: <##ff4d00>&lᴇɴᴄʜᴀɴᴛᴇʀ <##ff6800>| <##ff8330>%{_itemname}%
- on right click:
- if clicked block is lodestone:
- if player's held item is air:
- set {_enchanting} to a new chest inventory with 6 rows with name "{@mainguiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of {_enchanting} to anvil named "&e&l[!] &eThere is no item selected" with lore "", "&f&oHold the item", "&f&oyou want to upgrade!"
- open {_enchanting} to player
- #! Pickaxe
- if player is holding any pickaxe:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Sword
- if player is holding any sword:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Axe
- if player is holding any axe:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Helmet
- if player is holding any helmet:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Chestplate
- if player is holding any chestplate:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Leggings
- if player is holding any leggings:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- #! Boots
- if player is holding any boots:
- set {_item} to player's held item
- set {_itemname} to name of player's held item
- set {_enchanting} to a new chest inventory with 6 rows with name "{@guiname}"
- set slot 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 and 53 of {_enchanting} to {orange} named "&6"
- set slot 40 of {_enchanting} to barrier named "<##ff6800>ᴄᴀɴᴄᴇʟ"
- set slot 22 of player's current inventory to {_item} named {_itemname}
- open {_enchanting} to player
- on inventory click:
- if name of event-inventory is "{@guiname}":
- if index of event-slot = 0, 1, 2, 3, 4, 5, 6 ,7, 8, 45, 46, 47, 48, 49, 50, 51, 52 or 53:
- cancel event
- else:
- if name of event-inventory is "{@guiname}":
- if index of event-slot = 40:
- cancel event
- close player's inventory
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement