Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #EnchantManager
- #Create by soramame
- #二次配布は禁止です 必ずPlayerRealms Skript Communityに参加した状態でダウンロードしてください!
- #また バグ報告はsoramame_256#0256にDMでしてください!
- #以下 コード 変更する際は自己責任で御願いします 変更されている場合のコードのエラーは対応できません
- #---------------------------------------------------------------------------------------
- command /enchantmanager:
- permission: enchantmanager.use
- trigger:
- if player's tool isn't air:
- open chest with 6 rows named "&bEnchantManager" to player
- wait 1 tick
- set slot 0 of player's current inventory to player's tool
- set slot 10 of player's current inventory to glowing book named "&bダメージ軽減" with lore "&b手に持っているアイテムにダメージ軽減を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 11 of player's current inventory to glowing book named "&b火炎耐性" with lore "&b手に持っているアイテムに火炎耐性を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 12 of player's current inventory to glowing book named "&b落下耐性" with lore "&b手に持っているアイテムに落下耐性を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 13 of player's current inventory to glowing book named "&b爆発耐性" with lore "&b手に持っているアイテムに爆発耐性を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 14 of player's current inventory to glowing book named "&b飛び道具耐性" with lore "&b手に持っているアイテムに飛び道具耐性を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 15 of player's current inventory to glowing book named "&b水中呼吸" with lore "&b手に持っているアイテムに水中呼吸を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 16 of player's current inventory to glowing book named "&b水中採掘" with lore "&b手に持っているアイテムに水中採掘を付与します"
- set slot 19 of player's current inventory to glowing book named "&b棘の鎧" with lore "&b手に持っているアイテムに棘の鎧を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 20 of player's current inventory to glowing book named "&b水中歩行" with lore "&b手に持っているアイテムに水中歩行を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 21 of player's current inventory to glowing book named "&bダメージ増加" with lore "&b手に持っているアイテムにダメージ増加を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 22 of player's current inventory to glowing book named "&bアンデット特攻" with lore "&b手に持っているアイテムにアンデット特攻を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 23 of player's current inventory to glowing book named "&b虫特攻" with lore "&b手に持っているアイテムに虫特攻を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 24 of player's current inventory to glowing book named "&bノックバック" with lore "&b手に持っているアイテムにノックバックを付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 25 of player's current inventory to glowing book named "&b火属性" with lore "&b手に持っているアイテムに火属性を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 28 of player's current inventory to glowing book named "&bドロップ増加" with lore "&b手に持っているアイテムにドロップ増加を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 29 of player's current inventory to glowing book named "&b効率強化" with lore "&b手に持っているアイテムに効率強化を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 30 of player's current inventory to glowing book named "&bシルクタッチ" with lore "&b手に持っているアイテムにシルクタッチを付与します"
- set slot 31 of player's current inventory to glowing book named "&b耐久力" with lore "&b手に持っているアイテムに耐久力を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 32 of player's current inventory to glowing book named "&b幸運" with lore "&b手に持っているアイテムに幸運を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 33 of player's current inventory to glowing book named "&b射撃ダメージ増加" with lore "&b手に持っているアイテムに射撃ダメージ増加を付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 34 of player's current inventory to glowing book named "&bパンチ" with lore "&b手に持っているアイテムにパンチを付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 37 of player's current inventory to glowing book named "&bフレイム" with lore "&b手に持っているアイテムにフレイムを付与します"
- set slot 38 of player's current inventory to glowing book named "&b無限" with lore "&b手に持っているアイテムに無限を付与します"
- set slot 39 of player's current inventory to glowing book named "&b宝釣り" with lore "&b手に持っているアイテムに宝釣りを付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 40 of player's current inventory to glowing book named "&b入れ食い" with lore "&b手に持っているアイテムに入れ食いを付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 41 of player's current inventory to glowing book named "&b修繕" with lore "&b手に持ってるアイテムに修繕を付与します"
- set slot 42 of player's current inventory to glowing book named "&b氷渡り" with lore "&b手に持っているアイテムに氷渡りを付与します" and "&bレベルの設定はクリック後にチャットでしてください"
- set slot 53 of player's current inventory to red wool block named "&cエンチャントをすべて破棄" with lore "&cエンチャントをすべて破棄します"
- else:
- message "&cError! アイテムを所持した状態でないと使用できません!"
- on inventory click:
- if name of player's current inventory contains "&bEnchantManager":
- if clicked slot is 10:
- cancel event
- prot(player)
- if clicked slot is 11:
- cancel event
- firepro(player)
- if clicked slot is 12:
- cancel event
- fallpro(player)
- if clicked slot is 13:
- cancel event
- blastpro(player)
- if clicked slot is 14:
- cancel event
- projepro(player)
- if clicked slot is 15:
- cancel event
- resp(player)
- if clicked slot is 16:
- cancel event
- aqua(player)
- if clicked slot is 19:
- cancel event
- thor(player)
- if clicked slot is 20:
- cancel event
- dept(player)
- if clicked slot is 21:
- cancel event
- shar(player)
- if clicked slot is 22:
- cancel event
- smit(player)
- if clicked slot is 23:
- cancel event
- bane(player)
- if clicked slot is 24:
- cancel event
- knoc(player)
- if clicked slot is 25:
- cancel event
- fireas(player)
- if clicked slot is 28:
- cancel event
- loot(player)
- if clicked slot is 29:
- cancel event
- effi(player)
- if clicked slot is 30:
- cancel event
- silk(player)
- if clicked slot is 31:
- cancel event
- unbr(player)
- if clicked slot is 32:
- cancel event
- fort(player)
- if clicked slot is 33:
- cancel event
- pow(player)
- if clicked slot is 34:
- cancel event
- pun(player)
- if clicked slot is 37:
- cancel event
- fla(player)
- if clicked slot is 38:
- cancel event
- infi(player)
- if clicked slot is 39:
- cancel event
- luck(player)
- if clicked slot is 40:
- cancel event
- lure(player)
- if clicked slot is 41:
- cancel event
- mend(player)
- if clicked slot is 42:
- cancel event
- fros(player)
- if clicked slot is 53:
- disenchant player's tool
- cancel event
- else:
- cancel event
- on chat:
- if {%sender%.enchant} is set:
- cancel event
- set {_n} to message parsed as number
- if sender's tool isn't air:
- if sender has permission "enchantmanager.enchant":
- if {_n} <= 32768:
- if {%sender%.enchant} is "prot":
- set {_n} to "Protection %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "firepro":
- set {_n} to "Fire Protection %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "fallpro":
- set {_n} to "Feather Falling %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "blastpro":
- set {_n} to "Blast Protection %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "projepro":
- set {_n} to "Projectile Protection %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "resp":
- set {_n} to "Respiration %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "aqua":
- set {_n} to "Aqua Affinity %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "thor":
- set {_n} to "Thorns %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "dept":
- set {_n} to "Depth Strider %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "shar":
- set {_n} to "Sharpness %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "smit":
- set {_n} to "Smite %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "bane":
- set {_n} to "Bane of Arthropods %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "knoc":
- set {_n} to "Knockback %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "fireas":
- set {_n} to "Fire Aspect %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "loot":
- set {_n} to "Looting %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "effi":
- set {_n} to "Efficiency %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "unbr":
- set {_n} to "Unbreaking %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "fort":
- set {_n} to "Fortune %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "pow":
- set {_n} to "Power %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "pun":
- set {_n} to "Punch %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "fros":
- set {_n} to "Frost Walker %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "luck":
- set {_n} to "Luck of the Sia %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- if {%sender%.enchant} is "lure":
- set {_n} to "Lure %{_n}%"
- evaluate "enchant sender's tool with %{_n}%"
- message "&bエンチャントしました" to sender
- clear {%sender%.enchant}
- else:
- {%sender%.enchant} is set
- message "&cError! 実行中に不明なエラーが発生しました! soramame_256#0256に報告してください!"
- stop
- else:
- message "&c数値は32768以下にしてください!"
- else:
- message "&c権限が足りません!"
- clear {%sender%.enchant}
- else:
- message "&c手にアイテムを持ってください!"
- else:
- stop
- function prot(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "prot"
- stop
- function firepro(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "firepro"
- stop
- function fallpro(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "fallpro"
- stop
- function blastpro(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "blastpro"
- stop
- function projepro(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "projepro"
- stop
- function resp(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "resp"
- stop
- function aqua(p: player):
- close {_p}'s inventory
- message "&bエンチャントしました" to {_p}
- enchant {_p}'s tool with Aqua Affinity
- stop
- function thor(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "thor"
- stop
- function dept(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "dept"
- stop
- function shar(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "shar"
- stop
- function smit(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "smit"
- stop
- function bane(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "bane"
- stop
- function knoc(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "knoc"
- stop
- function fireas(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "fireas"
- stop
- function loot(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "loot"
- stop
- function effi(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "effi"
- stop
- function silk(p: player):
- close {_p}'s inventory
- message "&bエンチャントしました" to {_p}
- enchant {_p}'s tool with Silk Touch
- stop
- function unbr(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "unbr"
- stop
- function fort(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "fort"
- stop
- function mend(p: player):
- close {_p}'s inventory
- enchant {_p}'s tool with Mending
- message "&bエンチャントしました" to {_p}
- stop
- function pow(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "pow"
- stop
- function pun(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "pun"
- stop
- function fla(p: player):
- close {_p}'s inventory
- enchant {_p}'s tool with Flame
- message "&bエンチャントしました" to {_p}
- stop
- function infi(p: player):
- close {_p}'s inventory
- enchant {_p}'s tool with Infinity
- message "&bエンチャントしました" to {_p}
- stop
- function fros(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "fros"
- stop
- function luck(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "luck"
- stop
- function lure(p: player):
- close {_p}'s inventory
- message "&bチャットに付与するエンチャントのレベルを入力してください" to {_p}
- set {%{_p}%.enchant} to "lure"
- stop
Add Comment
Please, Sign In to add comment