Skocz do zawartości
  • 0

Ostatnie wpisane komendy


Pytanie

potrzebuje skrypt na 27 ostatnich wpisanych komend przez graczy w gui i glowa gracza tego kto wpisal komende gdy ktos wpisze komende to sie ustawia zmienna no i tam pisze nazwa komendy i nick gracza

Edytowane przez AxonGames
Odnośnik do komentarza
https://skript.pl/temat/48946-ostatnie-wpisane-komendy/
Udostępnij na innych stronach

6 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
on command:
	if size of {commands::*} >= 27:
		remove first element of {commands::*}
		remove first element of {commandsX::*}
	add full command to {commands::*}
	add "%name of player%" to {commandsX::*}

command /gui:
	trigger:
		open chest inventory named "sss" with 3 rows to player
		loop (size of {commands::*} times:
			set slot (loop-number - 1) of player's current inventory to skull of ("%{commandsX::%loop-number%}%" parsed as offlineplayer) named "%{commandsX::%loop-number%}%" with lore "%{commands::%loop-number%}%"

przetestuj

Odnośnik do komentarza
https://skript.pl/temat/48946-ostatnie-wpisane-komendy/#findComment-304570
Udostępnij na innych stronach

  • 0
Godzinę temu, CoFFeIN04 napisał:

on command:
	if size of {commands::*} >= 27:
		remove first element of {commands::*}
		remove first element of {commandsX::*}
	add full command to {commands::*}
	add "%name of player%" to {commandsX::*}

command /gui:
	trigger:
		open chest inventory named "sss" with 3 rows to player
		loop (size of {commands::*} times:
			set slot (loop-number - 1) of player's current inventory to skull of ("%{commandsX::%loop-number%}%" parsed as offlineplayer) named "%{commandsX::%loop-number%}%" with lore "%{commands::%loop-number%}%"

przetestuj

2 błedy, https://imgur.com/a/FloYULo

Odnośnik do komentarza
https://skript.pl/temat/48946-ostatnie-wpisane-komendy/#findComment-304574
Udostępnij na innych stronach

  • 0

Nie ma błędów

on command:
	if size of {commands::*} >= 27:
		remove first element of {commands::*} from {commands::*}
		remove first element of {commandsX::*} from {commandsX::*}
	add full command to {commands::*}
	add name of player to {commandsX::*}

command /cmds:
	trigger:
		open chest inventory named "&cKomendy" with 3 rows to player
		loop (size of {commands::*}) times:
			set slot (loop-number - 1) of player's current inventory to skull of ("%{commandsX::%loop-number%}%" parsed as offlineplayer) named "%{commandsX::%loop-number%}%" with lore "/%{commands::%loop-number%}%"
on inventory click:
	name of player's inventory = "&cKomendy"
	clicked inventory is not player's inventory
	cancel event

 

Odnośnik do komentarza
https://skript.pl/temat/48946-ostatnie-wpisane-komendy/#findComment-304584
Udostępnij na innych stronach

  • 0
Godzinę temu, CoFFeIN04 napisał:

Nie ma błędów


on command:
	if size of {commands::*} >= 27:
		remove first element of {commands::*} from {commands::*}
		remove first element of {commandsX::*} from {commandsX::*}
	add full command to {commands::*}
	add name of player to {commandsX::*}

command /cmds:
	trigger:
		open chest inventory named "&cKomendy" with 3 rows to player
		loop (size of {commands::*}) times:
			set slot (loop-number - 1) of player's current inventory to skull of ("%{commandsX::%loop-number%}%" parsed as offlineplayer) named "%{commandsX::%loop-number%}%" with lore "/%{commands::%loop-number%}%"
on inventory click:
	name of player's inventory = "&cKomendy"
	clicked inventory is not player's inventory
	cancel event

 

Niby działa ale niby chcę ale nie chce, ustawiłem sobie na maks 5 logów i nie nadpisuje tych tego pierwszego na drugiego itd. i trzeciego na czwartego..

Odnośnik do komentarza
https://skript.pl/temat/48946-ostatnie-wpisane-komendy/#findComment-304589
Udostępnij na innych stronach

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ą.

Nieaktywny
Odpowiedz na pytanie...

×   Wklejono zawartość z formatowaniem.   Usuń formatowanie

  Dozwolonych jest tylko 75 emoji.

×   Odnośnik został automatycznie osadzony.   Przywróć wyświetlanie jako odnośnik

×   Przywrócono poprzednią zawartość.   Wyczyść edytor

×   Nie możesz bezpośrednio wkleić grafiki. Dodaj lub załącz grafiki z adresu URL.

  • Ostatnio przeglądający   0 użytkowników

    • Brak zarejestrowanych użytkowników przeglądających tę stronę.
×
×
  • Dodaj nową pozycję...