Skocz do zawartości

xAxee

Zasłużony
  • Ilość zawartości

    6123
  • Rejestracja

  • Ostatnia wizyta

  • Wygrane w rankingu

    232

Treść opublikowana przez xAxee

  1. Do samych funkcji jedynie skript w wersji 2.2 lub wyższej Dzięki za opinie
  2. Cześć Chciałbym wam przedstawić pewien system funkcji. Mianowicie chodzi o system zarządzania cooldownem. Funkcje udostępniam ponieważ wiele użytkowników nie wie jak poprawnie stworzyć cooldown a ten system funkcji powinien im to ułatwić. Funkcje są dostępne tutaj Środowisko: - skript min 2.6 - serwer 1.18.1 Jak używać? Najpierw trzeba stworzyć nasz cooldown funckją createCooldown(nazwa cooldowna, czas) np: on load: createCooldown("heal", 10 second) Następnie w kodzie musimy sprawdzić status cooldowna gracza funkcją: getCooldown(gracz, "nazwa cooldowna") np: command /heal [<text>]: trigger: if getCooldown(player, "heal"): Nastepnie gdy wykonamy kod musimy ustawic cooldown gracza funkcją: setCooldown(gracz, "nazwa cooldowna") np: setCooldown(player, "heal") Opis wszystkich funkcji: createCooldown(%string%, %time span%, %boolean-2%) - Tworzy cooldown deleteCooldown(%string%) - Usuwa cooldown setCooldown(%player%, %boolean%) - Ustawia status cooldownu getCooldown(%player%, %string%) - Zwraca status cooldownu w booleanie (np true) getCooldownBoolean(%player%, %string%) - Zwraca status cooldownu w booleanie (np false) getCooldownDate(%player%, %string%) - Zwraca date wygaśnięcia cooldownu (np 22.08.19 15:00) getCooldownTime(%player%, %string%) - Zwraca czas wygaśnięcia cooldownu (np 10 second) getCooldownText(%player%, %string%, %format%) - Zwraca przetłumaczony czas cooldownu (np 10 minut i 2.34 sekund) Małe wyjaśnienie: %string% - nazwa cooldownu (np "poradnik") %time span% - czas cooldownu (np 10 second) %player% - gracz (np player) %boolean% - status cooldownu (np true) %boolean-2% - czy automatycznie ma ustawić cooldown na true (np true) %boolean-3% - Włączenie bypassa do ominięcia cooldownu (np false) %format% - Customowa lista tłumaczeń (np "lat" and "rok", "miesiecy"...) Przykładowe skrypty z użyciem tych funkcji: Automatyczna aktualizacja Jeżeli chcesz aby ten skrypt aktualizował ci się automatycznie pobierz skrypt AxAutoUpdate
  3. %spawn% zamien na swoja lokalizacje spawna
  4. on damage of player: if "%victim's world%" contain "World": if victim's y-coord < 0: cancel event teleport victim to %spawn% powinno być dobrze
  5. lul zamien if player's world is "World": na if "%player's world%" contain "World":
  6. a no tak zamien player na victim
  7. on damage of player: if player's world is "World": if player's y-coord < 0: cancel event teleport player to %spawn%
  8. uwzględnij który to ma być wykonany loop (1 / 2 / 3)
  9. xAxee

    Premiumcase

    Jeżeli nie ma błędów to żaden nie jest potrzebny chyba że są to podaj je i ci powiem
  10. xAxee

    Błąd skript

    Dodaj On inventory click: If inventory name of current inventory of player is "Nazwa twojego gui": Cancel event #tylko zmień nazwę gui I najlepiej też zamień format slot na set player's current inventory's slot...
  11. xAxee

    Błąd skript

    podaj kod.
  12. xAxee

    Co dziesiaty hit

    on damage of player: add 1 to {dmg::%victim%} if {dmg::%victim%} is 10: set {dmg::%victim%} to 0 apply poison to victim for 10 second #Tylko zmien nazwe potki bo nie pamietam jaka to xD
  13. xAxee

    problem z gui

    W pętli While nie masz żadnego opóźnienia(albo jestem ślepy) wiec pętla wykonuje się ok 20razy na sekundę przez co ci pewnie laguje serwer i nie ustawia dodaj jakiś Wait 1 second
  14. Nanotechnologia
  15. Podaj błędy
  16. xAxee

    Zmiana w skrypcie

    command /repair [<text>]: trigger: if player's tool is any pickaxe or any sword or any shovel or any hoe or any axe or any helmet or any chestplate or any leggings or any boots: repair player's tool send "&7Naprawiono"
  17. xAxee

    Premiumcase

    options: name: &9Premium&6Case on load: clear {dropPremium::*} add beacon to {dropPremium::*} add diamond pickaxe of efficiency 6, unbreaking 3 and fortune 3 to {dropPremium::*} add diamond helmet of protection 4 and unbreaking 3 to {dropPremium::*} add diamond chestplate of protection 4 and unbreaking 3 to {dropPremium::*} add diamond leggings of protection 4 and unbreaking 3 to {dropPremium::*} add diamond boots of protection 4 and unbreaking 3 to {dropPremium::*} add diamond sword of sharpness 5 and knockback 5 to {dropPremium::*} add diamond sword of sharpness 5 and fire aspect 2 to {dropPremium::*} add 64 emerald block to {dropPremium::*} add 32 emerald block to {dropPremium::*} add 16 emerald block to {dropPremium::*} command /premiumdaj [<offlineplayer>] [<integer=1>]: permission: premki trigger: if arg 1 is set: set {_ilosc} to arg 2 if arg 1 is "all": add {_ilosc} of chest named "{@name}" to all players send "&6Caly serwer dostal premium case &7%{_ilosc}%" else: if arg 1 is online: add {_ilosc} of chest named "{@name}" to {_p} send "&6Dostales premium case &7%{_ilosc}%" else: send "&7Ten gracz jest offilne!" else: send "poprawne uzycie: &7/premiumdaj <gracz/all> <ilosc>" on place: if name of player's tool is "{@name}": set event-block to air send "" send "&9Otwierasz premium case" loop (random integer between 1 and 3) times: set {_i} to random element out of {dropPremium::*} drop {_i} at (location of event-block) send "&6Trafiles: &7%{_i}%"
  18. xAxee

    Lista

    command /admincb [<text>] [<text>]: trigger: player has permission "admin.casusbelli": if arg 1 is "list": send "&8>> &6%{sendercb::*}% &7- %{casusbelli1::*}%: %{casusbellireason::*}%" if arg 1 is "accept": if arg 2 is {casusbelli1::%arg-2%}: set {casusbelli1::%arg-2%} to true send "zaakceptowałeś casus belli przeciwko państwu %arg-2%" remove {casusbelli1::%arg-2%} from {casusbelli1::*}
  19. xAxee

    Lista

    command /admincb [<text>] [<text>]: trigger: player has permission "admin.casusbelli": if arg 1 is "list": loop {sendercb::*}: send "&8>> &6%{sendercb::%loop-index%}% &7- %{casusbelli1::%loop-index%}%: %{casusbellireason::%loop-index%}%" chyba o to ci chodzilo
  20. xAxee

    Zmienne

    variables: jest to rejestrowanie zmiennych używa się go aby np każdy gracz początkowo miał 0 kasy. else: jest to warunek sprzeczny ifa pod którym jest np: Command /x: Trigger: If player is op: Send "jesteś opem!" If player has 6 sand: Send "i posiadasz 6 piasku" Else: Send "i nie masz 6 piasku! #biedak" Else: Send "nie jesteś opem!"
  21. On damage: If player's y-coord <= -10: Cancel event Teleport player to %spawn%
  22. Zmienne z funkcji zapisują się jako lokalne czyli nie %name% tylko %{_name}%
  23. xAxee

    gui-lore

    Wyświetl {_lore} i zobacz co się wyświetla
  24. xAxee

    LICZYMY DO MILIONA

    873
  25. Skrypt był tu udostępniony jedynie 4fun dlatego w dziale nauka. I tak config zajmie Ci mniej miejsca(przy paru stronach) niż coś takiego jak ty pokazałeś
×
×
  • Dodaj nową pozycję...