# Włączanie dropu na ziemie, i do eq , 49 (ziemia - ziemia, głowa gracza - eq) command /drop [] [] []: trigger: if sender is not player: send "&c* &7Ta komenda moze byc wykonana tylko przez gracza!" stop if arg 1 is not set: send "&c* &6Drop by &4Nik3N" send "&c* &a/drop gui &8- &7pokazuje twoj drop" send "&c* &a/drop info &8- &7pokazuje drop" if player has permission "kDrop.admin": send "&c* &cKomendy admina:" send "&c* &a/drop reload &8- &7reloaduje skrypt" send "&c* &a/drop reset &8- &7Restartuje zmienne. (graczy i serwerowe)" send "&c* &a/drop edit gui &8- &7edytujesz itemy w dropie" send "&c** &7Ponizsza komenda dziala tylko na item trzymany w rece! Potem ten item wkladasz do gui." send "&c** &7Jezeli chcesz ustawic pare itemkow z fortunka, po prostu wkladasz do gui w jeden slot kilka itemów np 5 coal." send "&c* &a/drop edit chance &8- &7Ustawiasz szanse na item dla gracza" send "&c* &a/drop edit chancevip &8- &7Ustwiasz szanse na item dla &6Vip'a" stop if arg 1 is "del": set {drop.player::%player%::drop::49} to dirt named "&6%player%" with lore "&c* &7Itemy beda leciec na:||&a* &6Ziemie" stop if arg 1 is "info": if {drop.edit.gui} is set: send "&c* &7Trwa edycja dropu, prosze sprobuj ponownie pozniej." stop open chest with 5 rows named "&6Drop serwera" to player wait 2 tick loop {drop.edit::*}: set player's current inventory's slot loop-index parsed as integer to loop-value stop if arg 1 is "gui": if {drop.edit.gui} is set: send "&c* &7Trwa edycja dropu, prosze sprobuj ponownie pozniej." stop open chest with 6 rows named "&6Drop &a%player%" to player wait 2 tick loop {drop.player::%player%::drop::*}: if loop-value is not air: set player's current inventory's slot loop-index parsed as integer to loop-value stop if player has permission "kDrop.admin": if arg 1 is "reload": execute player command "sk reload %script%" stop if arg 1 is "reset": clear {drop.edit::*} clear {ore.edit::*} loop {drop.player::*}: set {_temp} to {drop.player::%loop-index%::drop::49} clear {drop.player::%loop-index%::drop::*} set {drop.player::%loop-index%::drop::49} to {_temp} clear {_temp} send "&c* &7Zmienne wyczyszczone." stop if arg 1 is "edit": if arg 2 is "maxItem": if "%arg 3%" doesn't contain ".": set {drop.maxitem} to arg 3 send "&c* &7Ustawiles maxymalna liczbe itemow z bloku na: &6%arg 3%" stop send "&c* &7Podaj liczbe calkowita." stop if arg 2 is "ore": if {drop.edit.ore} is set: send "&c* &7Trwa edycja przez &6%{drop.edit.ore}%" stop open chest with 5 rows named "&6Ore &7Edycja" to player wait 1 tick loop {ore.edit::*}: set player's current inventory's slot loop-index parsed as integer to loop-value stop if arg 2 is "gui": if {drop.edit.gui} is set: send "&c* &7Trwa edycja przez &6%{drop.edit.gui}%" stop open chest with 5 rows named "&6Drop &7Edycja" to player wait 1 tick loop {drop.edit::*}: set player's current inventory's slot loop-index parsed as integer to loop-value set {drop.edit.gui} to player stop if player's tool is air: send "&c* &7Nie masz nic w reku." stop set {_1} to "%uncoloured 1st line of player's tool's lore%" loop length of {_1} times: if subtext of {_1} between characters loop-number and loop-number is "%nl%": set {_2} to subtext of {_1} between characters loop-number+1 and length of {_1} set {_1} to subtext of {_1} between characters 1 and loop-number-1 exit loop if {_1} is not "": replace all "Gracz: " in {_1} with "" replace all "%%" in {_1} with "" set {_1} to {_1} parsed as number if {_2} is not "": replace all "Vip: " in {_2} with "" replace all "%%" in {_2} with "" set {_2} to {_2} parsed as number if arg 2 is "chance": if arg 3 is not set: send "&c* &7Podaj szanse na item dla Gracza" stop if arg 3 is smaller than 0.01: send "&c* &7Szansa na item nie moze byc mniejsza niz 0.01" stop if {_2} is not "": if arg 3 is larger than {_2}: send "&c* &7Szansa dla gracza nie moze byc wieksza niz dla &6Vip'a" stop set 1st line of player's tool's lore to "&aGracz: &6%arg 3%%%" send "&c* &7Ustawiles &6%arg 3%%% &7szans na wydropienie &6%player's tool% &7dla Gracza" stop if arg 2 is "chanceVip": if {_1} is "": send "&c* &7Nie masz ustawionych szans na item dla Gracza" stop if arg 3 is not set: send "&c* &7Podaj szanse na item dla &6Vip'a" stop if arg 3 is smaller than 0.01: send "&c* &7Szansa na item nie moze byc mniejsza niz 0.01" stop if arg 3 is smaller than {_1}: send "&c* &7Szansa dla &6Vip'a &7nie moze byc mniejsza niz dla Gracza" stop set 2nd line of player's tool's lore to "&aVip: &6%arg 3%%%" send "&c* &7Ustawiles &6%arg 3%%% &7szans na wydropienie &6%player's tool% &7dla &6Vip'a" stop send "&c &7Nieznany argument" stop on quit: if {drop.edit.gui} is player: clear {drop.edit.gui} if {drop.edit.ore} is player: clear {drop.edit.ore} on inventory close: if "%inventory name of player's current inventory%" is "&6Drop &7Edycja": set {_i} to 0 loop 45 times: clear {_error} set {_item} to player's current inventory's slot {_i} set {drop.edit::%{_i}%} to air set {_item} to {_item} parsed as item if {_item} is not air: if {_item} is blacklist: send "&c* &7Nie mozesz dodac &6%{_item}% &7bo znajduje sie na czarnej liscie." exit section set {_1} to "%uncoloured 1st line of {_item}'s lore%" if "%{_1}%" doesn't contain "%nl%" and "Gracz" and "Vip": send "&c* &6%{_item}% &7nie jest poprawnie skonfigurowany" give {_item} to player set {_error} to true exit section if {_error} is not set: if "%{_1}%" contains "%nl%": replace all "%nl%Status: Wlaczony" in {_1} with "" loop length of {_1} times: if subtext of {_1} between characters loop-number-2 and loop-number-2 is "%nl%": set {_2} to subtext of {_1} between characters (loop-number-2)+1 and length of {_1} set {_1} to subtext of {_1} between characters 1 and (loop-number-2)-1 exit loop if {_1} is not "": replace all "Gracz: " in {_1} with "" replace all "%%" in {_1} with "" set {_1} to {_1} parsed as number if {_2} is not "": replace all "Vip: " in {_2} with "" replace all "%%" in {_2} with "" set {_2} to {_2} parsed as number set {drop.edit::%{_i}%} to {_item} set {drop.edit::%{_i}%::chance} to {_1} set {drop.edit::%{_i}%::chanceVip} to {_2} set {drop.edit::%{_i}%::name} to name of player's current inventory's slot {_i} set 3rd line of player's current inventory's slot {_i}'s lore to "&cStatus: &aWlaczony" add 1 to {_i} clear {drop.edit.gui} loop {drop.edit::*}: loop {drop.player::*}: set {drop.player::%loop-index-2%::drop::%loop-index-1%} to loop-value-1 broadcast "&c* Zaktualizowano drop. Ustawienia zostaly zrestartowane." stop if "%inventory name of player's current inventory%" is "&6Ore &7Edycja": clear {drop.edit.ore} set {_i} to 0 loop 45 times: set {_item} to player's current inventory's slot {_i} set {_item} to {_item} parsed as item if {_item} is any ore: send "To jest block %{_item}%" set {ore.edit::%{_i}%} to {_item} add 1 to {_i} clear {drop.edit.ore} stop if "%inventory name of player's current inventory%" is "&6Drop &a%player%": set {_i} to 0 loop 45 times: set {drop.player::%player%::drop::%{_i}%} to player's current inventory's slot {_i} add 1 to {_i} set {drop.player::%player%::drop::49} to player's current inventory's slot 49 stop on inventory click: if "%inventory name of player's current inventory%" is "&6Drop serwera": cancel event if "%inventory name of player's current inventory%" is "&6Drop &a%player%": cancel event if player's current inventory's slot slot is not air: if lore of player's current inventory's slot slot contains "Eq": set player's current inventory's slot slot to dirt named "&6%player%" with lore "&c* &7Itemy beda leciec na:||&a* &6Ziemie" stop if lore of player's current inventory's slot slot contains "ziemie": set player's current inventory's slot slot to player's skull named "&6%player%" with lore "&c* &7Itemy beda leciec do:||&a* &6Eq" stop if lore of player's current inventory's slot slot contains "wlaczony": set 3rd line of player's current inventory's slot slot's lore to "&cStatus: &4Wylaczony" stop if lore of player's current inventory's slot slot contains "wylaczony": set 3rd line of player's current inventory's slot slot's lore to "&cStatus: &aWlaczony" stop on break: if event-block is stone: if player's tool is any pickaxe: loop {drop.edit::*}: if loop-value is not air: if lore of {drop.player::%player%::drop::%loop-index%} contains "wlaczony": if player has permission "kDrop.vip": chance of {drop.edit::%loop-index%::chanceVip}%: set {_item} to "%loop-value%" if player's tool is enchanted with fortune: if "%loop-value%" contains "1" or "2" or "3" or "4" or "5" or "6" or "7" or "8" or "9": set {_item} to "%{_item}%" set {_i} to first 2 characters of "%{_item}%" replace all {_i} in {_item} with "" replace all " " in {_i} with "" set {_i} to {_i} parsed as integer loop 100 times: loop {_i} times: chance of 100/{_i}%: set {_int} to loop-number-2 exit loop if {_int} is set: exit loop set {_item} to "%{_int}% %{_item}%" set {_item} to {_item} parsed as item if {drop.edit::%loop-index%::name} is not set: if {drop.player::%player%::drop::49} is player head: if player has enough space for {_item}: give {_item} to player else: drop {_item} above event-block else: drop {_item} above event-block else if {drop.edit::%loop-index%::name} is set: set {_item} to {_item} named {drop.edit::%loop-index%::name} if {drop.player::%player%::drop::49} is player head: if player has enough space for {_item}: give {_item} to player else: drop {_item} above event-block else: drop {_item} above event-block else if player doesn't have permission "kDrop.vip": chance of {drop.edit::%loop-index%::chance}%: set {_item} to "%loop-value%" if player's tool is enchanted with fortune: if "%loop-value%" contains "1" or "2" or "3" or "4" or "5" or "6" or "7" or "8" or "9": set {_item} to "%{_item}%" set {_i} to first 2 characters of "%{_item}%" replace all {_i} in {_item} with "" replace all " " in {_i} with "" set {_i} to {_i} parsed as integer loop 100 times: loop {_i} times: chance of 100/{_i}%: set {_int} to loop-number-2 exit loop if {_int} is set: exit loop set {_item} to "%{_int}% %{_item}%" set {_item} to {_item} parsed as item if {drop.edit::%loop-index%::name} is not set: if {drop.player::%player%::drop::49} is player head: if player has enough space for {_item}: give {_item} to player else: drop {_item} above event-block else: drop {_item} above event-block else if {drop.edit::%loop-index%::name} is set: set {_item} to {_item} named {drop.edit::%loop-index%::name} if {drop.player::%player%::drop::49} is player head: if player has enough space for {_item}: give {_item} to player else: drop {_item} above event-block else: drop {_item} above event-block loop {ore.edit::*}: if event-block is loop-value: cancel event set event-block to air send "&c* &7Ten block jest zablokowany przez drop. &a/drop"