Skocz do zawartości
  • 0

Skrypt na expowiska


Unlucky Gumi

Pytanie

Nie wiem do końca jak to rozwiązać

on script load:
	load yaml "plugins/Skript/scripts/mobSystem/mobConfig.yml" as "mobConfig"
	
	
#typ moba, trudnosc easy med hard
command /mobspawn [<text>] [<text>]:
	trigger:
		set {_n} to yaml value "%arg 1%.%arg 2%.name" from "mobConfig"
		set {_mh} to yaml value "%arg 1%.%arg 2%.hp" from "mobConfig"
		set {_m} to arg-1 parsed as entity type
		spawn {_m} at player's location
		set the maximum health of the last spawned entity to {_mh}
		heal last spawned entity
		set {_h} to health of last spawned entity 
		set display name of last spawned entity to "%{_n}% %{_h}%❤"


#mob, ilosc easy, ilosc med, ilosc hard
command /expowisko [<text>] [<number>] [<number>] [<number>]:
	add player's location to {mobSystem::expList::*}
	loop {mobSystem::expList::*}:
	
	
	
	
every 5 minutes:
	spawn moby w lokacjach

komenda mobspawn działa i respi dany typ moba o danej trudnosci, jak jednak osiagnac to aby moby co jakis czas respily sie w zapisanych lokacjach?

Odnośnik do komentarza
https://skript.pl/temat/36389-skrypt-na-expowiska/
Udostępnij na innych stronach

2 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
on script load:
	load yaml "plugins/Skript/scripts/mobSystem/mobConfig.yml" as "mobConfig"
	
	
#typ moba, trudnosc easy med hard
	
command /mobspawn [<text>] [<text>]:
	trigger:
		set {_n} to yaml value "%arg 1%.%arg 2%.name" from "mobConfig"
		set {_mh} to yaml value "%arg 1%.%arg 2%.hp" from "mobConfig"
		set {_m} to arg-1 parsed as entity type
		spawn {_m} at player's location
		set the maximum health of the last spawned entity to {_mh}
		heal last spawned entity
		set {_h} to health of last spawned entity 
		set display name of last spawned entity to "%{_n}% %{_h}%❤"


#mob, ilosc easy, ilosc med, ilosc hard
command /expowisko [<text>] [<number>] [<number>] [<number>]:
	add player's location to {mobSystem::expList::*}
	send "dodano"
	
	
every 5 minutes:
	loop {mobSystem::expList::*}:
		set {_n} to yaml value "%arg 1%.%arg 2%.name" from "mobConfig"
		set {_mh} to yaml value "%arg 1%.%arg 2%.hp" from "mobConfig"
		set {_m} to TYP MOBA
		spawn {_m} at loop-value
		set the maximum health of the last spawned entity to {_mh}
		heal last spawned entity
		set {_h} to health of last spawned entity 
		set display name of last spawned entity to "%{_n}% %{_h}%❤"

 

Odnośnik do komentarza
https://skript.pl/temat/36389-skrypt-na-expowiska/#findComment-232661
Udostępnij na innych stronach

  • 0
2 godziny temu, xAxee napisał:

on script load:
	load yaml "plugins/Skript/scripts/mobSystem/mobConfig.yml" as "mobConfig"
	
	
#typ moba, trudnosc easy med hard
	
command /mobspawn [<text>] [<text>]:
	trigger:
		set {_n} to yaml value "%arg 1%.%arg 2%.name" from "mobConfig"
		set {_mh} to yaml value "%arg 1%.%arg 2%.hp" from "mobConfig"
		set {_m} to arg-1 parsed as entity type
		spawn {_m} at player's location
		set the maximum health of the last spawned entity to {_mh}
		heal last spawned entity
		set {_h} to health of last spawned entity 
		set display name of last spawned entity to "%{_n}% %{_h}%❤"


#mob, ilosc easy, ilosc med, ilosc hard
command /expowisko [<text>] [<number>] [<number>] [<number>]:
	add player's location to {mobSystem::expList::*}
	send "dodano"
	
	
every 5 minutes:
	loop {mobSystem::expList::*}:
		set {_n} to yaml value "%arg 1%.%arg 2%.name" from "mobConfig"
		set {_mh} to yaml value "%arg 1%.%arg 2%.hp" from "mobConfig"
		set {_m} to TYP MOBA
		spawn {_m} at loop-value
		set the maximum health of the last spawned entity to {_mh}
		heal last spawned entity
		set {_h} to health of last spawned entity 
		set display name of last spawned entity to "%{_n}% %{_h}%❤"

 

every 5 minutes:
	loop {mobSystem::expWilki::*}:
		loop 5 times:
			set {_n} to yaml value "wolf.easy.name" from "mobConfig"
			set {_mh} to yaml value "wolf.easy.hp" from "mobConfig"
			set {_m} to wolf
			spawn {_m} at loop-value
			set the maximum health of the last spawned entity to {_mh}
			heal last spawned entity
			set {_h} to health of last spawned entity 
			set display name of last spawned entity to "%{_n}% %{_h}%❤"
		loop 3 times:
			set {_n} to yaml value "wolf.medium.name" from "mobConfig"
			set {_mh} to yaml value "wolf.medium.hp" from "mobConfig"
			set {_m} to wolf
			spawn {_m} at loop-value
			set the maximum health of the last spawned entity to {_mh}
			heal last spawned entity
			set {_h} to health of last spawned entity 
			set display name of last spawned entity to "%{_n}% %{_h}%❤"
		loop 1 times:
			set {_n} to yaml value "wolf.hard.name" from "mobConfig"
			set {_mh} to yaml value "wolf.hard.hp" from "mobConfig"
			set {_m} to wolf
			spawn {_m} at loop-value
			set the maximum health of the last spawned entity to {_mh}
			heal last spawned entity
			set {_h} to health of last spawned entity 
			set display name of last spawned entity to "%{_n}% %{_h}%❤"

Mam błąd there are multiple loops that match loop-value, jak to rozwiązac zeby moc spawnic po pare mobów

Odnośnik do komentarza
https://skript.pl/temat/36389-skrypt-na-expowiska/#findComment-232685
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ę...