Skocz do zawartości
  • 0

Skrypt na komende /tpa i /tpaccept


Pytanie

Witam, moglby mi ktos napisac skrypt na komende /tpa , /tpahere i /tpaccept?

Tak zeby gracz podczas teleportacji nie mogl sie ruszyc, a jak sie ruszy to anuluje teleportacje.

Z gory dzieki :)

Edytowane przez powley
Odnośnik do komentarza
https://skript.pl/temat/20340-skrypt-na-komende-tpa-i-tpaccept/
Udostępnij na innych stronach

  • Odpowiedzi 42
  • Dodano
  • Ostatniej odpowiedzi

Top użytkownicy dla tego pytania

Top użytkownicy dla tego pytania

Rekomendowane odpowiedzi

  • 0
command /tpa [<player>]:
	trigger:
		if player has permission "skript.tpa":
			set {tpa.%player%.%arg 1%} to true
			send "Wyslales prosbe o teleportacje do gracza %arg 1%"
			send "Gracz %player% prosi o teleportacje, wpisz /tpaccept %player% aby zaakcepotwac" to player-arg
			set {tpa.%player%.%arg 1%-next} to false
			set {tpa::%player%-loop-exit} to false
			loop 10 times:
				wait 1 second
				if {tpaccept.%arg 1%.%player%} is true:
					if {tpa::%player%-loop-exit} is false:
						set {tpa::%player%-loop-exit} to true
						send "Nie ruszaj sie przez 5 sekund"
						wait 2 second
						set {tpa::%player%-loc::x} to x-coordinate of player
						set {tpa::%player%-loc::y} to y-coordinate of player
						set {tpa::%player%-loc::z} to z-coordinate of player
						set {tpa.%player%.%arg 1%-next} to true
						loop-exit #albo exit loop
				else:
					send "Oczekiwanie na zgode"
			if {tpa.%player%.%arg 1%-next} is true:
				set {tpa::%player%-not} to false
				loop 5 times:
					wait 1 second
					set {tpa::%player%-loc::n-x} to x-coordinate of player
					set {tpa::%player%-loc::n-y} to y-coordinate of player
					set {tpa::%player%-loc::n-z} to z-coordinate of player
					if {tpa::%player%-loc::n-x} is not {tpa::%player%-loc::x}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
					if {tpa::%player%-loc::n-y} is not {tpa::%player%-loc::y}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
					if {tpa::%player%-loc::n-z} is not {tpa::%player%-loc::z}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
				if {tpa::%player%-not} is false:
					teleport player to location of player-arg
					set {tpa.%player%.%arg 1%} to false
					set {tpaccept.%arg 1%.%player%} to false
					send "Teleportacja"
					stop
			else:
				send "Gracz %arg 1% nie zaakceptowal twojej prosby"
				set {tpa.%player%.%arg 1%} to false
				set {tpaccept.%arg 1%.%player%} to false
				stop


  
command /tpaccept [<player>]:
	trigger:
		if player has permission "skript.tpa":
			if {tpa.%arg 1%.%player%} is true:
				send "Gracz %player% zaakceptował twoja prosbe" to player-arg
				set {tpaccept.%player%.%arg 1%} to true
				stop
			else:
				send "Gracz %arg 1% nie prosil cie o teleportacje"
				stop
  
command /tpadeny [<player>]:
	trigger:
		if player has permission "skript.tpa":
			if {tpa.%arg 1%.%player%} is true:
				send "Gracz %player% odrzucil twoja prosbe" to player-arg
				set {tpa.%player%.%arg 1%} to false
				set {tpaccept.%arg 1%.%player%} to false
				stop
			else:
				send "Gracz %arg 1% nie prosil cie o teleportacje"
				stop

To w sumie ja już nie wiem, spróbuj jeszcze to, napisz ile razy był napis "Oczekiwanie na zgodę" i po ilu sekundach napisało że "gracz nie zaakceptował twojej prośby", czy pisze ci wiadomość gdy gracz wpisze /tpaccept [nick] że gracz zaakceptował twoją zgodę?

 

Odnośnik do komentarza
https://skript.pl/temat/20340-skrypt-na-komende-tpa-i-tpaccept/#findComment-138547
Udostępnij na innych stronach

  • 0
11 godzin temu, ShroN napisał:

command /tpa [<player>]:
	trigger:
		if player has permission "skript.tpa":
			set {tpa.%player%.%arg 1%} to true
			send "Wyslales prosbe o teleportacje do gracza %arg 1%"
			send "Gracz %player% prosi o teleportacje, wpisz /tpaccept %player% aby zaakcepotwac" to player-arg
			set {tpa.%player%.%arg 1%-next} to false
			set {tpa::%player%-loop-exit} to false
			loop 10 times:
				wait 1 second
				if {tpaccept.%arg 1%.%player%} is true:
					if {tpa::%player%-loop-exit} is false:
						set {tpa::%player%-loop-exit} to true
						send "Nie ruszaj sie przez 5 sekund"
						wait 2 second
						set {tpa::%player%-loc::x} to x-coordinate of player
						set {tpa::%player%-loc::y} to y-coordinate of player
						set {tpa::%player%-loc::z} to z-coordinate of player
						set {tpa.%player%.%arg 1%-next} to true
						loop-exit #albo exit loop
				else:
					send "Oczekiwanie na zgode"
			if {tpa.%player%.%arg 1%-next} is true:
				set {tpa::%player%-not} to false
				loop 5 times:
					wait 1 second
					set {tpa::%player%-loc::n-x} to x-coordinate of player
					set {tpa::%player%-loc::n-y} to y-coordinate of player
					set {tpa::%player%-loc::n-z} to z-coordinate of player
					if {tpa::%player%-loc::n-x} is not {tpa::%player%-loc::x}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
					if {tpa::%player%-loc::n-y} is not {tpa::%player%-loc::y}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
					if {tpa::%player%-loc::n-z} is not {tpa::%player%-loc::z}:
						set {tpa::%player%-not} to true
						send "Teleportacja anulowana"
						set {tpa.%player%.%arg 1%} to false
						set {tpaccept.%arg 1%.%player%} to false
						stop
				if {tpa::%player%-not} is false:
					teleport player to location of player-arg
					set {tpa.%player%.%arg 1%} to false
					set {tpaccept.%arg 1%.%player%} to false
					send "Teleportacja"
					stop
			else:
				send "Gracz %arg 1% nie zaakceptowal twojej prosby"
				set {tpa.%player%.%arg 1%} to false
				set {tpaccept.%arg 1%.%player%} to false
				stop


  
command /tpaccept [<player>]:
	trigger:
		if player has permission "skript.tpa":
			if {tpa.%arg 1%.%player%} is true:
				send "Gracz %player% zaakceptował twoja prosbe" to player-arg
				set {tpaccept.%player%.%arg 1%} to true
				stop
			else:
				send "Gracz %arg 1% nie prosil cie o teleportacje"
				stop
  
command /tpadeny [<player>]:
	trigger:
		if player has permission "skript.tpa":
			if {tpa.%arg 1%.%player%} is true:
				send "Gracz %player% odrzucil twoja prosbe" to player-arg
				set {tpa.%player%.%arg 1%} to false
				set {tpaccept.%arg 1%.%player%} to false
				stop
			else:
				send "Gracz %arg 1% nie prosil cie o teleportacje"
				stop

To w sumie ja już nie wiem, spróbuj jeszcze to, napisz ile razy był napis "Oczekiwanie na zgodę" i po ilu sekundach napisało że "gracz nie zaakceptował twojej prośby", czy pisze ci wiadomość gdy gracz wpisze /tpaccept [nick] że gracz zaakceptował twoją zgodę?

 

Jak wpisuje /tpaccept to pisze ze gracz nick nie zaakceptowal twojej prosby a Oczekiwanie na zgode 10 razy pisze

 

Odnośnik do komentarza
https://skript.pl/temat/20340-skrypt-na-komende-tpa-i-tpaccept/#findComment-138681
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ę...