Witam, pomoże ktoś hopperem? Nie powinno ciągle spamić tym loopem w else.
variables:
{_Cooldown} = 3 real seconds
on hopper pickup:
if event-item is diamond sword:
set {_location} to "%event-location%"
if {_location} contains "x: 376, y: 64, z: -767":
loop all players in radius 3 of event-location:
if loop-player is in region "dominik":
metadata "NPC" of loop-player is not set
send "Checking..." to loop-player
execute console command "npc create Ojdziec --at 376.5,67,-769.8,world"#Type write: --type Villager before --location to spawn Villager!
wait 1 tick
execute console command "npc create Madka --at 374.5,67,-769.8,world"#Type write: --type Villager before --location to spawn Villager!
wait 1 tick
execute console command "npc sel Madka"
wait 1 tick
execute console command "npc look"
wait 1 tick
execute console command "npc sel Ojdziec"
wait 1 tick
execute console command "npc look"
wait 4 real seconds
strike lightning effect at location (374), (69), (-770) in world "world"
strike lightning effect at location (376), (69), (-770) in world "world"
execute console command "npc remove Madka"
execute console command "npc remove Ojdziec"
stop
else:
cancel event
if difference between {_Cooldown} and now is smaller than 3 seconds:
loop all players in radius 5 of event-location:
metadata "NPC" of loop-player is not set
send "This is not diamond, dominik will break you" to console
spawn 2 zombies at loop-player's head
stop
set {_Cooldown} to now
Edit: +Powinno wykryć gracza, który tam wrzuca by nie było że itemy same wpadają i triggerują..
+ prosiłbym o cooldown na to wywołanie "if something between now is now:".
Pytanie
Misio12320 32
Witam, pomoże ktoś hopperem? Nie powinno ciągle spamić tym loopem w else.
variables: {_Cooldown} = 3 real seconds on hopper pickup: if event-item is diamond sword: set {_location} to "%event-location%" if {_location} contains "x: 376, y: 64, z: -767": loop all players in radius 3 of event-location: if loop-player is in region "dominik": metadata "NPC" of loop-player is not set send "Checking..." to loop-player execute console command "npc create Ojdziec --at 376.5,67,-769.8,world"#Type write: --type Villager before --location to spawn Villager! wait 1 tick execute console command "npc create Madka --at 374.5,67,-769.8,world"#Type write: --type Villager before --location to spawn Villager! wait 1 tick execute console command "npc sel Madka" wait 1 tick execute console command "npc look" wait 1 tick execute console command "npc sel Ojdziec" wait 1 tick execute console command "npc look" wait 4 real seconds strike lightning effect at location (374), (69), (-770) in world "world" strike lightning effect at location (376), (69), (-770) in world "world" execute console command "npc remove Madka" execute console command "npc remove Ojdziec" stop else: cancel event if difference between {_Cooldown} and now is smaller than 3 seconds: loop all players in radius 5 of event-location: metadata "NPC" of loop-player is not set send "This is not diamond, dominik will break you" to console spawn 2 zombies at loop-player's head stop set {_Cooldown} to now
Edit: +Powinno wykryć gracza, który tam wrzuca by nie było że itemy same wpadają i triggerują..
+ prosiłbym o cooldown na to wywołanie "if something between now is now:".
Edytowane przez Misio12320Odnośnik do komentarza
Udostępnij na innych stronach
0 odpowiedzi na to pytanie
Rekomendowane odpowiedzi
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ą.