Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /getLoad_g:
- trigger:
- getLoad_g(player)
- function getLoad_g(p: player):
- set metadata tag "getLoad_g" of {_p} to chest inventory with 3 rows named "&0"
- set slots (integers between 0 and 26) of metadata tag "getLoad_g" of {_p} to gray stained glass pane named "&0"
- set slot 4 of metadata tag "getLoad_g" of {_p} to paper named "&rPlease wait..."
- set {_i} to {_p}'s ping
- set slot 26 of metadata tag "getLoad_g" of {_p} to lime stained glass pane named "&aPing: %{_i}%"
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to light gray wool named "&7Unloaded load"
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 1800:
- stop loop
- wait 0.3 seconds
- set slot 10 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 1" with lore "&asuccessful!"
- set slot 11 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 2..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 1000:
- stop loop
- wait 0.3 seconds
- set slot 11 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 2" with lore "&asuccessful!"
- set slot 12 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 3..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 750:
- stop loop
- wait 0.3 seconds
- set slot 12 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 3" with lore "&asuccessful!"
- set slot 13 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 4..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 350:
- stop loop
- wait 0.3 seconds
- set slot 13 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 4" with lore "&asuccessful!"
- set slot 14 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 5..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 200:
- stop loop
- wait 0.3 seconds
- set slot 14 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 5" with lore "&asuccessful!"
- set slot 15 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 6..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 170:
- stop loop
- wait 0.3 seconds
- set slot 15 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 6" with lore "&asuccessful!"
- set slot 16 of metadata tag "getLoad_g" of {_p} to green wool named "&2Loading load 7..."
- delete {_getLoad_g}
- loop 100 times:
- add 1 to {_getLoad_g}
- if {_getLoad_g} != 100:
- if {_p}'s ping <= 125:
- stop loop
- wait 0.3 seconds
- set slot 16 of metadata tag "getLoad_g" of {_p} to lime wool named "&aLoaded load 7" with lore "&asuccessful!"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- wait 0.3 seconds
- else:
- stop loop
- set slots (integers between 10 and 16) of metadata tag "getLoad_g" of {_p} to red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)"
- open (metadata tag "getLoad_g" of {_p}) to {_p}
- on inventory open:
- if event-inventory = (metadata tag "getLoad_g" of player):
- while player's current inventory = (metadata tag "getLoad_g" of player):
- if {_i} != player's ping:
- set slot 26 of player's current inventory to lime stained glass pane named "&aPing: %{_i}%"
- set {_i} to player's ping
- wait 1 second
- on inventory click:
- if event-inventory = (metadata tag "getLoad_g" of player):
- if event-slot = (integers between 10 and 16):
- if event-item = red wool named "&cPing update failed..." with lore "&0" and "&7(Click to retry)":
- getLoad_g({_p})
- else:
- cancel event
- else:
- cancel event
- # --- --- --- --- --- --- --- --- ---
- # |0 |1 |2 |3 |4 |5 |6 |7 |8 |
- # --- --- --- --- --- --- --- --- ---
- # |9 |10 |11 |12 |13 |14 |15 |16 |17 |
- # --- --- --- --- --- --- --- --- ---
- # |18 |19 |20 |21 |22 |23 |24 |25 |26 |
- # --- --- --- --- --- --- --- --- ---
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement