Hejka. Zacząłem pisac skrypt tak jak w temacie. Mam gotowe pierwsze gui ktorym otwieraja się opcje "gracze" i "spawn". Chce aby po otwarciu menu z lista graczy pokazywala sie glowka kazdego gracza online a po kliknieciu w ktoras wysylala się komenda /tpa <nick gracza ktorego wybralismy>. Aktualny wyglad kodu ponizej:
command /teleport:
trigger:
set {_gui} to a new chest inventory with 1 row with name "&5Menu"
set slot 4 of {_gui} to diamond block with name "&4SPAWN"
set slot 0 of {_gui} to player head with name "&5Gracze"
open {_gui} to player
on inventory click:
if name of event-inventory is "&5Menu":
if index of event-slot = 4:
cancel event
execute command "/spawn" by player
if name of event-inventory is "&5Menu":
if index of event-slot = 0:
cancel event
set {_players} to a new chest inventory with 5 row with name "&5Player List"
#Jak wstawic tu glowe kazdego gracza?
open {_players} to player
Pytanie
Bulbaterson 1
Hejka. Zacząłem pisac skrypt tak jak w temacie. Mam gotowe pierwsze gui ktorym otwieraja się opcje "gracze" i "spawn". Chce aby po otwarciu menu z lista graczy pokazywala sie glowka kazdego gracza online a po kliknieciu w ktoras wysylala się komenda /tpa <nick gracza ktorego wybralismy>. Aktualny wyglad kodu ponizej:
command /teleport: trigger: set {_gui} to a new chest inventory with 1 row with name "&5Menu" set slot 4 of {_gui} to diamond block with name "&4SPAWN" set slot 0 of {_gui} to player head with name "&5Gracze" open {_gui} to player on inventory click: if name of event-inventory is "&5Menu": if index of event-slot = 4: cancel event execute command "/spawn" by player if name of event-inventory is "&5Menu": if index of event-slot = 0: cancel event set {_players} to a new chest inventory with 5 row with name "&5Player List" #Jak wstawic tu glowe kazdego gracza? open {_players} to playerOdnośnik do komentarza
https://skript.pl/temat/43344-skript-skrypt-na-tpa-w-gui/Udostępnij na innych stronach
13 odpowiedzi na to pytanie
Rekomendowane odpowiedzi