Skocz do zawartości
  • 0

Skrypt wywołujący komendę po wytypowaniu innej


Pytanie

Witam, czy dałby ktoś napisać skrypt, który po wrzuceniu komendy do konsoli "Pex user NICK group set Magnat" wywoływało także drugą komendę, a mianowicie "bc Ktoś na serwerze właśnie zakupił rangę Magnat'a! Dziękujemy za wsparcie! <3"?

Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/
Udostępnij na innych stronach

8 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
command /nadajmagnat <player>:
	trigger:
  		if arg 1 is set:
  			execute console command "Pex user %player% group set Magnat"
  			wait 5 tick
  			if arg 1 has permission "group.magnat":
  				broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"
  			else:
  				send "&cWystapil nieoczekiwany blad. Gracz nie uzyskal rangi MAGNAT."

Teraz nie wpisuj pex... tylko, /nadajmagnat <nick>.

Edytowane przez KrejzolekPRO
Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-145736
Udostępnij na innych stronach

  • 0
command /pex user <text> group set Magnat:
	trigger:
  		if arg 1 is set:
  			execute console command "pex user %arg 1% group set Magnat"
  			broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"
  		else:
  			send "&cPodaj nick gracza."
Edytowane przez xxdamixx
Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-145738
Udostępnij na innych stronach

  • 0
24 minuty temu, KrejzolekPRO napisał:

command /nadajmagnat <player>:
	trigger:
  		if arg 1 is set:
  			execute console command "Pex user %player% group set Magnat"
  			wait 5 tick
  			if arg 1 has permission "group.magnat":
  				broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"
  			else:
  				send "&cWystapil nieoczekiwany blad. Gracz nie uzyskal rangi MAGNAT."

Teraz nie wpisuj pex... tylko, /nadajmagnat <nick>.

Nie działa. 

Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-145743
Udostępnij na innych stronach

  • 0

 
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 3: if arg 1 is set:')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 4: execute console command "Pex user %player% group set Magnat"')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 5: wait 5 tick')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 6: if arg 1 has permission "group.magnat":')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 7: broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 8: else:')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 9: send "&cWystapil nieoczekiwany blad. Gracz nie uzyskal rangi MAGNAT."')


Tak, tak nazwałem skrypt.
Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-145751
Udostępnij na innych stronach

  • 0
16 godzin temu, Ask3r napisał:


 
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 3: if arg 1 is set:')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 4: execute console command "Pex user %player% group set Magnat"')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 5: wait 5 tick')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 6: if arg 1 has permission "group.magnat":')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 7: broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 8: else:')
[17:32:27 ERROR]: indentation error: expected 2 tabs, but found '__->->->->' [-> = tab, _ = space, ? = other whitespace] (chuj.sk, line 9: send "&cWystapil nieoczekiwany blad. Gracz nie uzyskal rangi MAGNAT."')


Tak, tak nazwałem skrypt.

Musisz wytabowac... zaraz ci to zrobie

command /pex user <text> group set Magnat:
    permission: magnat.pex 
    trigger:
        if arg 1 is set:
            execute console command "pex user %arg 1% group set Magnat"
            broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"
        else:
            send "&cPodaj nick gracza."

zamiast uzywac komendy z pexa mozesz ustawic /TwojaKomenda <text> 

Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-145828
Udostępnij na innych stronach

  • 0
command /nadajmagnat [<player>]:
	trigger:
  		if arg 1 is set:
  			console command "pex user %player-arg% group set Magnat"
  			wait 5 tick
  			if player-arg has permission "group.magnat":
  				broadcast "&7Gracz &3%arg 1% &&zakupil range &8MAGNAT&7!"
  			else:
  				send "&cWystapil nieoczekiwany blad. Gracz nie uzyskal rangi MAGNAT."

 

Odnośnik do komentarza
https://skript.pl/temat/21446-skrypt-wywo%C5%82uj%C4%85cy-komend%C4%99-po-wytypowaniu-innej/#findComment-146631
Udostępnij na innych stronach

Nieaktywny
Ten temat został zamknięty. Brak możliwości dodania odpowiedzi.
  • Ostatnio przeglądający   0 użytkowników

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