Skocz do zawartości
  • 0

Drop


TheDarkRexYT

Pytanie

7 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool to player:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if player has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if player has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim

powinno działać nie testowałem

Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329596
Udostępnij na innych stronach

  • 0
44 minuty temu, Saanjuk napisał:
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool to player:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if player has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if player has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim

powinno działać nie testowałem

2 błędy. Linijka 7 - cant understand this loop 'drops of event-block using players tool to player'
               Linijka 17 - use 'attacker' and/or 'victim' in damage/death events

Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329600
Udostępnij na innych stronach

  • 0
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if attacker has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if player has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim

 

Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329603
Udostępnij na innych stronach

  • 0
26 minut temu, Saanjuk napisał:
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if attacker has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if player has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim

 

Dwa błędy: Linijka 23 - if player has enough space for loop-value
                    Linijka 25 - 'else' has to be placed just after another 'if' or 'else if' section

I zapomniałem napisać, że jak się da to żeby z mobów też drop leciał do eq. Jeżeli to nie problem...

Edytowane przez TheDarkRexYT
Edycja
Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329605
Udostępnij na innych stronach

  • 0
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill
	perm_mobs: use.drop2inv.mobs

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if attacker has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if attacker has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim
					
on death:
	if victim is not player:
		if attacker has permission "{@perm_mobs}":
			loop drops:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if attacker has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at attacker	

nigdzie nie może byc player w on death musi być attacker

dopisałem moby

 

Edytowane przez Saanjuk
Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329606
Udostępnij na innych stronach

  • 0
18 minut temu, Saanjuk napisał:
Options:
	perm_mine: use.drop2inv.mine
	perm_kill: use.drop2inv.kill
	perm_mobs: use.drop2inv.mobs

on mine:
	if player has permission "{@perm_mine}":
		loop drops of event-block using player's tool:
			add loop-item to {_inventory::*}
		cancel drops
		loop {_inventory::*}:
			if player has enough space for loop-value:
				add loop-value to player's inventory
			else:
				drop loop-value at player
		
on death of player:
	if attacker has permission "{@perm_kill}":
		if attacker is a player:
			loop all items in victim's inventory:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if attacker has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at the victim
					
on death:
	if victim is not player:
		if attacker has permission "{@perm_mobs}":
			loop drops:
				add loop-item to {_inventory::*}
			cancel drops
			loop {_inventory::*}:
				if attacker has enough space for loop-value:
					add loop-value to attacker's inventory
				else:
					drop loop-value at attacker	

nigdzie nie może byc player w on death musi być attacker

dopisałem moby

 

Działa. Dzięki

Odnośnik do komentarza
https://skript.pl/temat/54287-drop/#findComment-329607
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ę...