Kebaberon 0 Opublikowano 11 sierpnia 2020 Udostępnij Opublikowano 11 sierpnia 2020 Witam mam prośbę czy da rade stworzyć skrypt który kompasem będzie pokazywał najdalszego gracza? Cytuj Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
0 Kormic 1 824 Opublikowano 11 sierpnia 2020 Udostępnij Opublikowano 11 sierpnia 2020 (edytowane) 43 minuty temu, Kebaberon napisał: Witam mam prośbę czy da rade stworzyć skrypt który kompasem będzie pokazywał najdalszego gracza? command /kompas: trigger: give player compass named "&6&lNawigator" on join: while player is online: if player's tool is compass named "&6&lNawigator": loop all players in player's world: if loop-player is not player: if {_t} is not set: set {_t} to location of the loop-player set {_p} to loop-player if distance between player and loop-player is greater than distance between player and {_t}: set {_t} to location of the loop-player set {_p} to loop-player if {_t} is not set: send "&cNie ma zadnego gracza poza toba w tym swiecie!" to player else: set player's compass target to location of block at {_t} set {_d} to distance between player and {_t} rounded to 1 decimal place send "&aNajdalszy gracz: %{_p}%, dystans: %{_d}%" to player wait 3 seconds Sprawdź czy wszystko poprawnie działa. EDIT: Jest też druga wersja: command /kompas: trigger: give player compass named "&6&lNawigator" while player is online: if player's tool is compass named "&6&lNawigator": if {cooldown::kompas::%player%} is not set: loop all players in player's world: if loop-player is not player: if {_t} is not set: set {_t} to location of the loop-player set {_p} to loop-player if distance between player and loop-player is greater than distance between player and {_t}: set {_t} to location of the loop-player set {_p} to loop-player if {_t} is not set: send "&cNie ma zadnego gracza poza toba w tym swiecie!" to player else: set player's compass target to location of block at {_t} set {_d} to distance between player and {_t} rounded to 1 decimal place send "&aNajdalszy gracz: %{_p}%, dystans: %{_d}%" to player wait 5 seconds clear {cooldown::kompas::%player%} Edytowane 11 sierpnia 2020 przez Kormic Cytuj Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
0 Kebaberon 0 Opublikowano 11 sierpnia 2020 Autor Udostępnij Opublikowano 11 sierpnia 2020 Nie działa ani to pierwsze ani drugie :// Cytuj Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
0 Kormic 1 824 Opublikowano 11 sierpnia 2020 Udostępnij Opublikowano 11 sierpnia 2020 (edytowane) 17 minut temu, Kebaberon napisał: Nie działa ani to pierwsze ani drugie :// Wersja Skripta? EDIT: Zapewne chodzi o to, że masz wersję Skripta, która nie wie czym są pętle 'while', więc masz wersję, która powinna ci zadziałać: command /kompas: trigger: give player compass named "&6&lNawigator" on right click with compass: if player's tool is compass named "&6&lNawigator": if {cooldown::kompas::%player%} is not set: set {cooldown::kompas::%player%} to true loop all players in player's world: if loop-player is not player: if {_t} is not set: set {_t} to location of the loop-player set {_p} to loop-player if distance between player and loop-player is greater than distance between player and {_t}: set {_t} to location of the loop-player set {_p} to loop-player if {_t} is not set: send "&cNie ma zadnego gracza poza toba w tym swiecie!" to player else: set player's compass target to location of block at {_t} set {_d} to distance between player and {_t} rounded to 1 decimal place send "&aNajdalszy gracz: %{_p}%, dystans: %{_d}%" to player wait 5 seconds clear {cooldown::kompas::%player%} else: send "&cMusisz odczekac chwile!" to player Edytowane 11 sierpnia 2020 przez Kormic Cytuj Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Pytanie
Kebaberon 0
Witam mam prośbę czy da rade stworzyć skrypt który kompasem będzie pokazywał najdalszego gracza?
Odnośnik do komentarza
Udostępnij na innych stronach
3 odpowiedzi na to pytanie
Rekomendowane odpowiedzi
Dołącz do dyskusji
Możesz dodać zawartość już teraz a zarejestrować się później. Jeśli posiadasz już konto, zaloguj się aby dodać zawartość za jego pomocą.