Skocz do zawartości
  • 0

Skript na puszke pandory


gmpl

Pytanie

Witam napisze ktoś skript na puszke pandorę (Ma wypadać jeden przedmiot)
Komendy:
/pandora all [ilosc]
/pandora [gracz] [ilosc]
Drop:
64x Diamenty 4%, 64x Drewno 4% , 1x Spodnie 4/3 4% , 1x Buty 4/3 4% , 1. Klata 4/3 4% , 1x Helm 4/3 4% , /eco give %player% 2000$ 2% , 1x Magiczny Kilof 8/3/3 2% , x1 Magiczny Kilof 2 10/3/3 1% , 1x Kilof 5/3/3 4%, 1 Mob spawner 1%

Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/
Udostępnij na innych stronach

12 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
command /pandora [<text>] [<text>]:
	trigger:
		if arg 1 is "all":
			if player has permissions "pandora.all":
				if arg 2 is set:
					if arg 2 is number:
						give to all player %arg 2% dragon egg with name "&6Pandora" and lore "&6Postaw zeby otworzyc"
						send "Dostales %arg 2% pandor"
						stop
					else:
						send "To nie jest ilosc"
				else:
					send "Nie podales ilosci"
			else:
				send "Nie masz do tego permisji"
		if arg 1 is player:
			if arg 2 is set:
				if player has permissions "pandora.gracz":
					if arg 2 is number:
						give to %arg 1% %arg 2% dragon egg with name "&6Pandora" and lore "&6Postaw zeby otworzyc"
						send "Dostales %arg 2% pandor" to arg 1 parsed as player
						stop
					else:
						send "To nie jest ilosc"
				else:
					send "Nie masz do tego permisji"
			else:
				send "Nie podales ilosci"
on place dragon egg:
	if name of dragon egg is "&6Pandora":
		if lore of dragon egg is "&6Postaw zeby otworzyc":
			cancel event
			chance of 4.0%:
				give 64 diamond to player
			chance of 4.0%:
				give 64 wood to player
			chance of 4.0%:
				give 1 diamond leggins of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond boots of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%
				give 1 diamond helmet of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%
				give 1 diamond chestplate of enchant protection 4 and unbreaking 3 to player
			chance of 2.0%:
				execute console command "eco give %player% 2000" to player
			chance of 1.0%:
				give 1 diamond pickax with name "&9Magiczny kilof" of enchant efficency 10 and unbreaking 3 and fortune 3 to player
			chance of 4.0%:
				give 1 diamond pickax of enchant efficiency 5 and unbreaking 3 and fortune 3 to player
			chance of 1.0%
				give 1 mob spawner to player
			
		
		

Nie sprawdzalem czy dziala

Edytowane przez konrad055
Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213875
Udostępnij na innych stronach

  • 0
13 minut temu, konrad055 napisał:

command /pandora [<text>] [<text>]:
	trigger:
		if arg 1 is "all":
			if player has permissions "pandora.all":
				if arg 2 is set:
					if arg 2 is number:
						give to all player %arg 2% dragon egg with name "&6Pandora" and lore "&6Postaw zeby otworzyc"
						send "Dostales %arg 2% pandor"
						stop
					else:
						send "To nie jest ilosc"
				else:
					send "Nie podales ilosci"
			else:
				send "Nie masz do tego permisji"
		if arg 1 is player:
			if arg 2 is set:
				if player has permissions "pandora.gracz":
					if arg 2 is number:
						give to %arg 1% %arg 2% dragon egg with name "&6Pandora" and lore "&6Postaw zeby otworzyc"
						send "Dostales %arg 2% pandor" to arg 1 parsed as player
						stop
					else:
						send "To nie jest ilosc"
				else:
					send "Nie masz do tego permisji"
			else:
				send "Nie podales ilosci"
on place dragon egg:
	if name of dragon egg is "&6Pandora"
		if lore of dragon egg is "&6Postaw zeby otworzyc"
			cancel event
			chance of 4.0%:
				give 64 diamond to player
			chance of 4.0%:
				give 64 wood to player
			chance of 4.0%:
				give 1 diamond leggins of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond boots of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%
				give 1 diamond helmet of enchant protection 4 and unbreaking 3 to player
			chance of 4.0%
				give 1 diamond chestplate of enchant protection 4 and unbreaking 3 to player
			chance of 2.0%:
				execute console command "eco give %player% 2000" to player
			chance of 1.0%:
				give 1 diamond pickax with name "&9Magiczny kilof" of enchant efficency 10 and unbreaking 3 and fortune 3 to player
			chance of 4.0%:
				give 1 diamond pickax of enchant efficiency 5 and unbreaking 3 and fortune 3 to player
			chance of 1.0%
				give 1 mob spawnerto player
			
		
		

Nie sprawdzalem czy dziala

Hmm mam 25 błędów. A może po prostu nie mam jakiegoś pluginu. Pluginy: Skript, skDragon-0.14.0, SkQuery, skRayFall+v1.9.12, skUtilities.v0.9.2

Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213876
Udostępnij na innych stronach

  • 0
10 minut temu, knugi napisał:
  Pokaż ukrytą zawartość


command /pandora [<text>] [<integer>]:
	trigger:
		if arg 1 is "all":
			if player has permissions "pandora.all":
				if arg 2 is set:
					give arg 2 of dragon egg named "&6Pandora" with lore "&6Postaw zeby otworzyc" to all players
					send "Dostales %arg 2% pandor"
					stop
				else:
					send "Nie podales ilosci"
			else:
				send "Nie masz do tego permisji"
		if arg 1 is player:
			if arg 2 is set:
				if player has permissions "pandora.gracz":
					give arg 2 of dragon egg named "&6Pandora" with lore "&6Postaw zeby otworzyc" to arg 1 parsed as player
					send "Dostales %arg 2% pandor" to arg 1 parsed as player
					stop
				else:
					send "Nie masz do tego permisji"
			else:
				send "Nie podales ilosci"
on place dragon egg:
	if name of dragon egg is "&6Pandora":
		if lore of dragon egg is "&6Postaw zeby otworzyc":
			cancel event
			chance of 4.0%:
				give 64 diamond to player
			chance of 4.0%:
				give 64 17 to player
			chance of 4.0%:
				give 1 diamond leggings of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond boots of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond helmet of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond chestplate of protection 4 and unbreaking 3 to player
			chance of 2.0%:
				execute console command "eco give %player% 2000"
			chance of 1.0%:
				give 1 diamond pickaxe of efficiency 10 and unbreaking 3 and fortune 3 named "&9Magiczny kilof"  to player
			chance of 4.0%:
				give 1 diamond pickaxe of efficiency 5 and unbreaking 3 and fortune 3 to player
			chance of 1.0%:
				give 1 mob spawner to player

 

Poprawiony kod @konrad055

1 blad z komenda /pandora oraz jak stawiam pandore z nazwą &6Pandora oraz z lore &6Postaw zeby otworzyc to nic sie nie dzieje.

Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213895
Udostępnij na innych stronach

  • 0

Jaki błąd?

 

Tutaj poprawiony event:

Spoiler

on place dragon egg:
	if name of player's tool is "&6Pandora":
		if lore of player's tool is "&6Postaw zeby otworzyc":
			cancel event
			remove 1 of dragon egg named "&6Pandora" with lore "&6Postaw zeby otworzyc" from player's inventory
			chance of 4.0%:
				give 64 diamond to player
			chance of 4.0%:
				give 64 17 to player
			chance of 4.0%:
				give 1 diamond leggings of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond boots of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond helmet of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond chestplate of protection 4 and unbreaking 3 to player
			chance of 2.0%:
				execute console command "eco give %player% 2000"
			chance of 1.0%:
				give 1 diamond pickaxe of efficiency 10 and unbreaking 3 and fortune 3 named "&9Magiczny kilof"  to player
			chance of 4.0%:
				give 1 diamond pickaxe of efficiency 5 and unbreaking 3 and fortune 3 to player
			chance of 1.0%:
				give 1 mob spawner to player

 

Ja testowałem to nie było błędu, tylko nie sprawdziłem czy dodaje przedmioty :) 

Edytowane przez knugi
Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213896
Udostępnij na innych stronach

  • 0
9 minut temu, knugi napisał:

Jaki błąd?

 

Tutaj poprawiony event:

  Ukryj zawartość


on place dragon egg:
	if name of player's tool is "&6Pandora":
		if lore of player's tool is "&6Postaw zeby otworzyc":
			cancel event
			remove 1 of dragon egg named "&6Pandora" with lore "&6Postaw zeby otworzyc" from player's inventory
			chance of 4.0%:
				give 64 diamond to player
			chance of 4.0%:
				give 64 17 to player
			chance of 4.0%:
				give 1 diamond leggings of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond boots of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond helmet of protection 4 and unbreaking 3 to player
			chance of 4.0%:
				give 1 diamond chestplate of protection 4 and unbreaking 3 to player
			chance of 2.0%:
				execute console command "eco give %player% 2000"
			chance of 1.0%:
				give 1 diamond pickaxe of efficiency 10 and unbreaking 3 and fortune 3 named "&9Magiczny kilof"  to player
			chance of 4.0%:
				give 1 diamond pickaxe of efficiency 5 and unbreaking 3 and fortune 3 to player
			chance of 1.0%:
				give 1 mob spawner to player

 

Ja testowałem to nie było błędu, tylko nie sprawdziłem czy dodaje przedmioty :) 

https://snag.gy/lJDqwy.jpg

Edytowane przez gmpl
Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213898
Udostępnij na innych stronach

  • 0
11 godzin temu, knugi napisał:

Przykro mi, lecz tych linijek co podałeś w błędzie nie ma w tym kodzie, który Tobie podesłałem. 

Działa, dziękuję :D a mam pytanko? Można jeszcze zrobić aby zawsze coś wypadało? Bo raz wypada, raz nie. Oraz te 2 błędy to było bo dopisałem te z góry /pandora all/gracz

Odnośnik do komentarza
https://skript.pl/temat/32994-skript-na-puszke-pandory/#findComment-213924
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ę...