Skocz do zawartości
  • 0

Drop z golemów...


marynarz

Pytanie

15 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
On death:
	if victim is a iron golem:
		if attacker is a player:
			clear drops
			name of iron golem is "&cGGolem":
				chance of 50%:
					give 1 iron ingot or 2 iron ingot or 3 iron ingot or 4 iron ingot or 5 iron ingot to the attacker

Nie testowane ale może działa

Edytowane przez SupcioXD
Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-137920
Udostępnij na innych stronach

  • 0
on death of iron golem:
	clear drops
	if attacker is a player:
		chance of 50%:
			set {_int} to a random integer between 1 and 5
			drop {_int} iron ingot at event-location

 

Edytowane przez esej
Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-137946
Udostępnij na innych stronach

  • 0
9 godzin temu, esej napisał:

on death of iron golem:
	clear drops
	if attacker is a player:
		chance of 50%:
			set {_int} to a random integer between 1 and 5
			drop {_int} iron ingot at event-location

 

Okej, wszystko spoko - aczkolwiek, czy dasz rade zrobić tak, że nie po zabiciu golema przez gracza - tylko przez każdą jego śmierć?
np. poprzez spalenie się w lawie - na tym mi najbardziej zależy.

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138146
Udostępnij na innych stronach

  • 0
on death of iron golem:
	clear drops
	chance of 50%:
		set {_int} to a random integer between 1 and 5
		set {_item} to "%{_int}% iron ingot"
		drop {_item} at event-location

lub
 

on death of iron golem:
	clear drops
	chance of 50%:
		set {_int} to a random integer between 1 and 5
		set {_int} to {_int} parsed as an number
		drop {_int} iron ingot at event-location


@ShroN nie można parsować liczby z przedmiotem w jednym :)

Edytowane przez esej
Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138207
Udostępnij na innych stronach

  • 0
on death of iron golem:
	clear drops
	set {_int} to a random integer between 1 and 5 
	set {_item} to "%{_int}% iron ingot" parsed as item
	drop {_item} at location of victim #albo drop {_item} at victim of location

#albo

on death of iron golem:
	clear drops
	set {_int} to a random integer between 1 and 5 parsed as number
	set {_item} to "%{_int}% of iron ingot" parsed as item
	drop {_item} at location of victim #albo drop {_item} at victim of location

@esej zapomniałeś o parsed as item :P

Edytowane przez ShroN
Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138208
Udostępnij na innych stronach

  • 0
on death of iron golem:
	clear drops
	chance of 50%:
		set {_int} to a random integer between 1 and 5
		set {_item} to "%{_int}% iron ingot"
		drop {_item} at event-location

Nie ma żadnego błędu, aczkolwiek nie respi żelaza.

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138216
Udostępnij na innych stronach

  • 0
on death of iron golem:
	clear drops
	chance of 50%:
		set {_int} to a random integer between 1 and 5
		set {_int} to {_int} parsed as number
		set {_item} to "iron ingot" 
		set {_item} to {_item} parsed as item
		drop {_int} of {_item} at event-location

Nie mam pomysłów , ale dzisiaj pisałem coś podobnego i mi działało tylko nie pamiętam jak to było :/ Postaram się rozwiązać ten problem.

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138219
Udostępnij na innych stronach

  • 0
2 minuty temu, esej napisał:

on death of iron golem:
	clear drops
	chance of 50%:
		set {_int} to a random integer between 1 and 5
		set {_int} to {_int} parsed as number
		set {_item} to "iron ingot" 
		set {_item} to {_item} parsed as item
		drop {_int} of {_item} at event-location

Nie mam pomysłów , ale dzisiaj pisałem coś podobnego i mi działało tylko nie pamiętam jak to było :/ Postaram się rozwiązać ten problem.

Również bez żadnego błędu, aczkolwiek stawiam po 100 golemów i ani jednego żelaza nie dropi.. - dzięki wielkie za chęci :)

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138221
Udostępnij na innych stronach

  • 0

Sposób , który musisz przetestować nie wiadomo czy będzie działał
by the way... pamiętaj o tym , że jest 50% :D

on death of iron golem:
	clear drops
	chance of 50%:
		set {_num} to a random integer between 1 and 5
		set {_num} to {_num} parsed as number
		drop ({_num}) iron ingot at event-location
		stop
Spoiler

# Sposób alternatywny... działa 100%
on death of iron golem:
	clear drops
	chance of 50%:
		set {_num} to a random integer between 1 and 5
		{_num} = 1:
			drop 1 iron ingot at event-location
		{_num} = 2:
			drop 2 iron ingot at event-location
		{_num} = 3:
			drop 3 iron ingot at event-location
		{_num} = 4:
			drop 4 iron ingot at event-location
		{_num} = 5:
			drop 5 iron ingot at event-location

 

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138224
Udostępnij na innych stronach

  • 0
1 minutę temu, esej napisał:

Sposób , który musisz przetestować nie wiadomo czy będzie działał
by the way... pamiętaj o tym , że jest 50% :D


on death of iron golem:
	clear drops
	chance of 50%:
		set {_num} to a random integer between 1 and 5
		set {_num} to {_num} parsed as number
		drop ({_num}) iron ingot at event-location
		stop
  Ukryj zawartość


# Sposób alternatywny... działa 100%
on death of iron golem:
	clear drops
	chance of 50%:
		set {_num} to a random integer between 1 and 5
		{_num} = 1:
			drop 1 iron ingot at event-location
		{_num} = 2:
			drop 2 iron ingot at event-location
		{_num} = 3:
			drop 3 iron ingot at event-location
		{_num} = 4:
			drop 4 iron ingot at event-location
		{_num} = 5:
			drop 5 iron ingot at event-location

 

@esej - nie mam zielonego pojęcia, aczkolwiek ani sposób pierwszy ani sposób drugie czyli alternatywny, nie działa.
W pierwszym wystąpił mi taki błąd ->
zMOvsbdiRPmTgkkjeuX45g.png
W drugim, błędów brak.

 

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138225
Udostępnij na innych stronach

  • 0
3 minuty temu, esej napisał:

on death of iron golem:
	clear drops
	chance of 50%:
		set {_num} to a random integer between 1 and 5
		loop {_num} times:
			drop 1 iron ingot at location of victim

 

Działa - dzięki wielkie, masz u mnie wielkiego plusika! :)
Można zamknąć temat.

Odnośnik do komentarza
https://skript.pl/temat/20341-drop-z-golem%C3%B3w/#findComment-138228
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ę...