Skocz do zawartości
  • 0

Sprawdzanie potki


seriomaniak_pl

Pytanie

5 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
4 minuty temu, seriomaniak_pl napisał:

W moim skrypcie potrzebuje fragmentu gdzie sprawdza się czy gracz wypił daną potkę. Mam fragment podany niżej lecz działa przy piciu każdej potki.
Wersja:
Skriptu 2.6.2
skRayFall 1.9.27
SkQuery 4.1.5
skript-reflect 2.3
skript-yaml 1.3.2

 

on consume:
    if player is holding potion of luck:
        send "test" to player
        execute console command "effect clear %player% wither"
        wait 2 tick
        execute console command "effect clear %player% luck"
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        create bossbar titled "&aDziałanie płynu Lugola" and id "lugol.%player%" for player with progress 100 with colors green
        set {lugol::%player%} to 100

Sprawdź to (musisz sobie wytabowac bo na telefonie pisze) :)

Edytowane przez pruslay
Odnośnik do komentarza
Udostępnij na innych stronach

  • 0

Nadal działa na każdy typ potki

 

3 godziny temu, pruslay napisał:
on consume:
    if player is holding potion of luck:
        send "test" to player
        execute console command "effect clear %player% wither"
        wait 2 tick
        execute console command "effect clear %player% luck"
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        create bossbar titled "&aDziałanie płynu Lugola" and id "lugol.%player%" for player with progress 100 with colors green
        set {lugol::%player%} to 100

Sprawdź to (musisz sobie wytabowac bo na telefonie pisze) :)

taki sam problem miałem również ze sprawdzanie nazwy (... named ...). Wtedy również działały nawet bez spełnionego danego warunku

Glicz

Łączę posty. 

Notatka dodana przez Glicz

Odnośnik do komentarza
Udostępnij na innych stronach

  • 0

Hmm, ale co po prostu każda plotka działa nawet jeżeli napiszesz ze to ma być ta potka potion of luck?
 

podaj wersje skript dodatki No i błędy jeżeli występują 

 

on rightclick:
    if player is holding potion of luck:
        remove 1 potion of luck from player's inventory
        send "test" to player
        execute console command "effect clear %player% wither"
        wait 2 tick
        execute console command "effect clear %player% luck"
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        create bossbar titled "&aDziałanie płynu Lugola" and id "lugol.%player%" for player with progress 100 with colors green
        set {lugol::%player%} to 100

Ewentualnie spróbuj coś takiego.

Edytowane przez pruslay
Glicz

Łączę posty. 

Notatka dodana przez Glicz

Odnośnik do komentarza
Udostępnij na innych stronach

  • 0
2 godziny temu, pruslay napisał:
on rightclick:
    if player is holding potion of luck:
        remove 1 potion of luck from player's inventory
        send "test" to player
        execute console command "effect clear %player% wither"
        wait 2 tick
        execute console command "effect clear %player% luck"
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        wait 7 ticks
        play sound "entity.witch.drink" to player
        create bossbar titled "&aDziałanie płynu Lugola" and id "lugol.%player%" for player with progress 100 with colors green
        set {lugol::%player%} to 100

Ewentualnie spróbuj coś takiego.

Nadal nie daje efektu który potrzebuję.
Skriptu 2.6.2
skRayFall 1.9.27
SkQuery 4.1.5
skript-reflect 2.3
skript-yaml 1.3.2

 

Sam znalazłem rozwiązanie

Glicz

Łączę posty.

Notatka dodana przez Glicz

Odnośnik do komentarza
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ę...