Skocz do zawartości
  • 0

GILDIE- TAG oraz Nazwa


franio3321

Pytanie

"Pisze" sobie taki sk na gildie, na swój serwer i pomyślałem:

Jeżeli jest komenda /zaloz [TAG] [NAZWA]

I jeżeli ktoś w miejscu TAG'u wpiszę nazwę a w miejsce Nazwy TAG skrypt tego nie uzna za błąd.

Więc jeżeli wprowadzę limit znaków na tag gildii problem zostanie rozwiązany problem w tym że nie mam pojęcia jak zastosować poradnik Dzikosyk'a pod mój sk.

       xxx TEN KOD JEST JUŻ ZBĘDNY :) xxx

Poradnik dzikosyka dot. limitu argumentów:

http://bukkit.pl/threads/tut-mini-length-checker-sprawdzanie-d%C5%82ugo%C5%9Bci-argumentu-skript-2-0.7359/'>>http://bukkit.pl/threads/tut-mini-length-checker-sprawdzanie-d%C5%82ugo%C5%9Bci-argumentu-skript-2-0.7359/

Podsumowując:

Chcę żeby limit TAGu wynosił 5 znaków (w tym liczby 0-9) a nazwa  15 znaków, za pomoc dziękuje i like ;)

Edytowane przez franio3321
Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/
Udostępnij na innych stronach

13 odpowiedzi na to pytanie

Rekomendowane odpowiedzi

  • 0
Gość DonFallingCookie

A nie lepiej:

if length of arg 1 is more than 5:	send "tag gildii jest za dlugi"	stopif length of arg 2 is more than 15:	send "nazwa gildii jest za dluga"	stop

? ;F

Edytowane przez DonFallingCookie
Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8542
Udostępnij na innych stronach

  • 0
Gość DonFallingCookie

Pozamieniaj sobie potem spacje na taby ;F

command /zaloz [<text&gt] [<text&gt]:        trigger:                if arg 1 is not set:                        send "{@t} poprawne uzycie /zaloz <TAG> <NAZWA>"                        stop                if {gildia.tag.%arg 1%} is true:                        send "&6GILDIA O PODANYM TAGU JUZ ISTNIEJE!"                        stop                if {gildia.%player%.owner} is true:                        send "{@t} posiadasz juz gildie!"                        stop                if {gildia.%player%.member} is true:                        send "{@t} jestes juz w gildi!"                        stop                if arg 1 is not empty:                        if arg 2 is not empty:								length of arg 1 is more than 5:								    	send "tag gildii jest za dlugi"									    stop								length of arg 2 is more than 15:									    send "nazwa gildii jest za dluga"									    stop                                player don't have {@item1}:                                        send "&6Nie posiadasz itemow na gildie !&oaby zalozyc gildie musisz posiadac 2 zlote jablka 5 prochu 5 diamentow 3 enderperly"                                        stop                                player don't have {@item2}:                                        send "&6Nie posiadasz {@item2}"                                        stop                                player don't have {@item3}:                                        send "&6Nie posiadasz {@item3}"                                        stop                                player don't have {@item4}:                                        send "&6Nie posiadasz {@item4}"                                        stop                                player cannot build at block under player:                                        send "&4Teren pod toba jest zajety :P"                                        stop                                player cannot build at block 100 meters northwest:                                        send "&4Teren na polnocny zachod jest zajety"                                        stop                                player cannot build at block 100 meters north:                                        send "&4Teren na polnoc jest zajety"                                        stop                                player cannot build at block 100 meters northeast:                                        send "&4Teren na polnocny wschod jest zajety"                                        stop                                player cannot build at block 100 meters west:                                        send "&4Teren na zachod jest zajety"                                        stop                                player cannot build at block 100 meters east:                                        send "&4Teren na wschod jest zajety"                                        stop                                player cannot build at block 100 meters southwest:                                        send "&4Teren na poludniowy zachud jest zajety"                                        stop                                player cannot build at block 100 meters south:                                        send "&4Teren na poludnie jest zajety"                                        stop                                player cannot build at block 100 meters southeast:                                        send "&4Teren na poludniowy wschod jest zajety"                                        stop                                if distance between {spawn} and location of player is greater than 150+50/2:                                        send "{@t} tworzenie zabezpieczen....."                                        execute console command "pex user %name of player% add worldedit.*"                                        execute console command "pex user %name of player% add worldguard.*"                                        wait 1 tick                                        execute player command "//pos1"                                        execute player command "//pos2"                                        execute player command "//expand 50 w"                                        execute player command "//expand 50 n"                                        wait 3 tick                                        execute player command "//expand 50 e"                                        execute player command "//expand 50 s"                                        execute player command "//expand vert"                                        execute player command "region define gildia-%arg 1%"                                        execute player command "region flag gildia-%arg 1% chest-access allow"                                        execute player command "region flag gildia-%arg 1% use allow"                                        wait 3 tick                                        execute player command "region addowner gildia-%arg 1% %name of player%"                                        execute console command "pex user %name of player% remove worldedit.*"                                        execute console command "pex user %name of player% remove worldguard.*"                                        loop 98 times:                                                send ""                                        message "&6Zalozyles Gildie!"                                        set block under the player to dragon egg                                        broadcast "&aGracz %name of player% powiekszyl cuboid o 50 kratek!"                                        send "{@t} tworzenie zabezpieczen....."                                        set {gildia.tag.%name of player%} to arg 1                                        message "&6Zalozyles Gildie!"                                        set {gildia.%name of player%.owner} to true                                        set {gildia.home.%arg 1%} to location of player                                        broadcast "{@t} Gracz %name of player% zalozyl gildie o nazwie %arg 2% o tagu %arg 1%"                                        set {gildia.%name of player%} to true                                        set {_cos} to "%{gildia.tag.%name of player%}%"                                        add player to {gildia.ownerklanu.%{_cos}%::*}                                        add arg 1 to {listagildii::*}                                        wait 1 seconds                                        remove {@item1} from the player's inventory                                        remove {@item2} from the player's inventory                                        remove {@item3} from the player's inventory                                        remove {@item4} from the player's inventory                                        set {gildia.tag.%arg 1%} to true                                        wait 2 tick                                        set {baza.%arg 1%} to true                                else:                                        send "&6Zbyt blisko spawnu!"
Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8553
Udostępnij na innych stronach

  • 0

DZIĘKI DZIAŁA, co do zakładania gildii, jest błąd gdzie kolwiek założę gildie pisze zbyt blisko spawnu, jest to porzucony skrypt, który znalazłem i staram się go przywrócić do użytku.

Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8570
Udostępnij na innych stronach

  • 0

A nie lepiej:

if length of arg 1 is more than 5:	send "tag gildii jest za dlugi"	stopif length of arg 2 is more than 15:	send "nazwa gildii jest za dluga"	stop
? ;F
Nope, on używa WorldGuarda, jeden dziwny znaczek i wszystko zdycha.

#// Wykarmione z Panda Phone

Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8575
Udostępnij na innych stronach

  • 0

Dzikosyk a masz lepszy pomysł?

Nie, nie mam zmiennej spawn bo jak mówiłem jest to porzucony skrypt autora "nope" napisałby ktoś mi ową?

Tu masz UC1 z limitem tagu, w razie czego sobie skopiujesz xd

http://pastebin.com/raw.php?i=Ww1vgsPc

 

if {_zmienna} contains "#" or "$" or "%" or "^" or "?":

    stop

α в ß ÑŒ ¢ ∂ Ñ” Ò“ Æ’ g н i × Ò› к â„“ м и η σ ø Ï Ñ Ï‚ § Ñ‚ υω × χ Â¥ үά έ ή ί ΰ α β ε η ικ λ μ ν ξ Ï Ï‚ σ Ï„ Ï… ω Ï‹ ÏŒ ÏÏŽ ÏŠ Ђ Ѓ Є Ñ Ñ‘ Ñ’ Ñ“ Ñ” Ñ• Ñ— ј à áâ ã ä Ã¥ ç è é ê ì í î ï ð ñ ò ôα β γ δ ε ζ η θ ι κ λ μ ν ξ οπ Ï Ïƒ Ï„ Ï… φ χ ψ ωα в ¢ ∂ Ñ”f g н ι ×  к â„“ м и σ Ï q Ñ Ñ• тχ у z Ï… ν ωά έ ή ί ΰ α βε η ικ λ μ ν ξ Ï Ï‚ σ Ï„ Ï…§ Ï‹ ÏŒÏ ÏŽÏŠ Ђ Ѓ Є Ñ Ñ‘ Ñ’ Ñ“ єѕ Ñ— ј α в c ∂α в ¢ ∂ Ñ” f g н ι ×  к â„“ м и σ Ï…Ï Ñ Ñ• Ñ‚ ó ω у z ź żÂ°à® Â© ◠·. · â—¦ εïз ♥ ღ ♂ ♀ ๑ â—Š â–’ â™  ♣ →↠∞≈ ¤ ♪ •ิ . • ® â„¢ † » ૪૪૪◊ ♥ â•  â• â•â–«â–  â–¡ Û© Ûž ๑ » « ૪஠† εïз ♪ ღ ♣ ♠• ± Ò— Û Â° •ิ . • ஠இ *×◊ â—¦ â™  ♣ ♪ ã® →°■ ♀ Ψ №↠∑ ξ ζ ω âˆâˆš ∩ ¤∞≡ â–„ ≠ ^_^ ─ = ≈ ≌ ﺴ۩๑ ๑ Û©ÛžÛ© ๑ â–“ ♨ ☎ ☠☆ ★ â–³ â–² â™  ♣ â™§ ღ ♂ ♀ ♥ ↔↕ â–ª ๑ â–„ â–ˆ ★◎≧ °¹²³∙ ▒« Ë‹ ▂ˊ  Ë‹ï¼ËŠã€€ ˋ︿ˊ  ˋωˊ  ˋï¹ËŠã€€Ë‹â–³ËŠã€€Ë‹ ▽ˊ ♥஠ღ ★☆♂♀εїз â–’ ¹ ² ³† ® ©™๑ Û© ↠↑→↓ â—Š ※ » «①②③④⑤⑥⑦⑧⑨⑩˙▂˙ ˙ï¼Ë™ã€€Ë™ï¸¿Ë™ ˙ω˙ ˙ï¹Ë™ã€€Ë™â–³Ë™ã€€Ë™â–½Ë™Â° ஠© ◠·.· â—¦ εïз ♥ ღ ♂ ♀ ๑ â—Š â–’ â™  ♣ →↠∞ ≈ ¤ ♪ •ิ . • ® â„¢ † »◊ ♥ â•  â• â•â–« â–  â–¡ Û© Ûž ๑ » « ஠† εïз ♪ ღ♣ â™  • ± Ò— Û Â° • ิ . • ஠இ *×▲ γ Ł ╦ â•© ε ┘ ┌ śž â–¡ 〓≡ â•╚╔ ╗╬ â•â•“ â•© â”  ┨┯ â”· ┓┗ ┛┳⊥﹃﹄┌ â”â”” ┘∟「ã€â†‘↓→↠↘↙♀♂┇┅◊ â—¦ â™  ♣ ♪ ã® →°■♀ Ψ №↠∑ ξ ζ ω âˆâˆšâˆ© ¤ ∞≡ â–„ ≠ ^_^ ─ = ≈≌ ﺴ۩๑ ๑۩۞۩๑ â–“â—Š â—¦ â™  ♣ ♪ ã® →° ■♀ Ψ №↠∑ ξ ζ ω âˆâˆšâˆ© ¤ ∞≡ â–„ ≠ ^_^ ─ = ≈≌ ﺴ ۩๑ ๑۩۞♨ ☎ ☠☆ ★ â–³ â–² â™  ♣ ♧ღ ♂ ♀ ♥↔ ↕ â–ª ๑ â—Ž ★◎≧※°¹²³ ∙ ▒♥à®áƒ¦ ★☆♂♀ εїз â–’ ¹ ² ³ ® ©™๑ Û©â†â†‘→↓ â—Š ※ » « â‘  ②③④⑤⑥⑦⑧⑨⑩♪â—◦○◊▼▲▫╰☆╮▓ ▒▌☜ ♡☞ ☎ ૪☠⊙ ◎╬╫ ∫∞∙∑∆• Û£ÛžÛ˚˜̃΅Ш â—¦ â–« □ˇ۰•â—Û© ® © εïз•ิ « ₪ â•  â• â•â–« ¶ Ò— Ûஇ * ツ â—‹ ↔ ♬ღ ♥ Û©Ûž Û© ¤ Ëœ ๑۩.♥.۩๑˜ .: ۞๑۩۞۩๑ ҳ̸Ҳ̸ҳ ♣ † »-(¯`v´¯) -»× (¯` v´¯ ) • â„¢ εïз °â—• •◠ஓ ஠Ю ÑŽ Ω ௫ â–²Û© ☻ → ↠↑ ↓ ﻬ ж Ψ √ ¤ ≠█ â–„ â–  â–¡ ∮ ∠♀ ♂ â–“ â–’ ∞ ₪Θ ≡ ξ ζ •´¯`° •. «(¨`v´ ¨)» ¦¦.·´¯`·.¸> ค α в ß ÑŒ ¢ ∂ Ñ” Ò“ Æ’ g н ι ×  Ò› к â„“ м и η σ ø Ï Ñ Ï‚ § Ñ‚ Ï… ω × χ Â¥ үά έ ή ί ΰ α β ε η ι κ λ μ ν ξ Ï Ï‚ σ Ï„ Ï… ω Ï‹ ÏŒ Ï ÏŽ ÏŠ Ђ Ѓ Є Ñ Ñ‘ ђѓє Ñ• Ñ— ј à á â ã ä Ã¥ ç è é ê ì í î ï ð ñ ò ô α β γ δ ε ζ η θ ι κ λ μ ν ξ ο Ï€ Ï Ïƒ Ï„ Ï… φ χ ψ ωα в ¢ ∂ Ñ” f g н ι ×  к â„“ м и σ Ï q Ñ Ñ• Ñ‚ χ у z Ï… ν ωά έ ή ί ΰ α βε η ι κ λ μ ν ξ Ï Ï‚ σ Ï„ Ï… ω Ï‹ ÏŒÏ ÏŽ ÏŠ Ђ Ѓ Є Ñ Ñ‘ Ñ’ Ñ“ єѕ Ñ— јα в c ∂ â„¢ ☢ ☣ ☤ ☥ ☦ ☧ ☨ ☩ ☪ ☫ ☬ ☭☮☯ Ûž ✪ ♆♰ â™± ✠✞ ✟♔ ♕ â™– â™— ♘ â™™ ♚ â™› ♜ ♠♞ ♟☀ ☠☂ ☃ ☄ ☾ ☽ ☼ ☀ âœºâœ¹âœ¸âœ·âœ¶âœµâœ´â„ â… â†â‡âˆ ≠⊠â‹âœ¦â‚⋆â„â…â‚✦✧✩✫✬✭✮✯✰✫☆★✩ ☆ ✡☿ ♀ ♠♂ ♅⦠§âœŽ ✠✠✑ ✒ ✉⢠⣠⤠⥠ღâ ✿ â€âƒâ˜Ž â˜âœ† ✄ ✠✂ ✃✗✘✖〤 ✓✔â âž â› âœà®ï»¬ εїз✈ ➸ ♨∙†◊™© ® ¤ ∆ â—Š ∞ √ £ • ≈ â—Š â–« â–¡ ∠۩ Ûž Û â™¥ ♪ ○♣ â™  ☼ ♂ ♀ ₪ ☻☺ ♫ ♦ Θ Φ ‡ † ¤ ๛ ๑ ๓ ๕ â—Œ ♦ ⌂ â—˜ ◙¤ Ë¿ Ó¿Ù­ • â„— √ ♯ â—„ â–¼ â–º â–² â–ª â–« © ® ¤ ∆ â—Š ∞ √ £ • ≈ â—Š â–« â–¡ ∠۩ Ûž Û â™¥ ♪ â—‹ ♣ â™  ☼ ♂ ♀ ₪ ☻☺ ♫ ♦ Θ Φ ‡ † ¤ ๛ ๑ ๓ ๕ â—Œ ♦ ⌂ â—˜ â—™ ¤ Ë¿ Ó¿Ù­ • â„— √ ♯ â—„ â–¼ â–º â–² â–ª

Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8787
Udostępnij na innych stronach

  • 0
Gość DonFallingCookie

No to dobra, wklepałem kod z tutoriala Dzikoyska xd

command /zaloz [<text&gt] [<text&gt]:        trigger:                if arg 1 is not set:                        send "{@t} poprawne uzycie /zaloz <TAG> <NAZWA>"                        stop                if {gildia.tag.%arg 1%} is true:                        send "&6GILDIA O PODANYM TAGU JUZ ISTNIEJE!"                        stop                if {gildia.%player%.owner} is true:                        send "{@t} posiadasz juz gildie!"                        stop                if {gildia.%player%.member} is true:                        send "{@t} jestes juz w gildi!"                        stop                if arg 1 is not empty:                        if arg 2 is not empty:						# Length Checker by Dzikoysk							set {_ver} to arg 1							replace all "1" with "1" in {_ver}							replace all "0" with "1" in {_ver}							replace all "2" with "1" in {_ver}							replace all "3" with "1" in {_ver}							replace all "4" with "1" in {_ver}							replace all "5" with "1" in {_ver}							replace all "6" with "1" in {_ver}							replace all "7" with "1" in {_ver}							replace all "8" with "1" in {_ver}							replace all "9" with "1" in {_ver}							replace all "q" with "1" in {_ver}							replace all "w" with "1" in {_ver}							replace all "e" with "1" in {_ver}							replace all "r" with "1" in {_ver}							replace all "t" with "1" in {_ver}							replace all "y" with "1" in {_ver}							replace all "u" with "1" in {_ver}							replace all "i" with "1" in {_ver}							replace all "o" with "1" in {_ver}							replace all "p" with "1" in {_ver}							replace all "a" with "1" in {_ver}							replace all "s" with "1" in {_ver}							replace all "d" with "1" in {_ver}							replace all "f" with "1" in {_ver}							replace all "g" with "1" in {_ver}							replace all "h" with "1" in {_ver}							replace all "j" with "1" in {_ver}							replace all "k" with "1" in {_ver}							replace all "l" with "1" in {_ver}							replace all "z" with "1" in {_ver}							replace all "x" with "1" in {_ver}							replace all "c" with "1" in {_ver}							replace all "v" with "1" in {_ver}							replace all "b" with "1" in {_ver}							replace all "n" with "1" in {_ver}							replace all "m" with "1" in {_ver}							if {_ver} is "1" or "11" or "111" or "1111" or "1111" or "11111":                                player don't have {@item1}:                                        send "&6Nie posiadasz itemow na gildie !&oaby zalozyc gildie musisz posiadac 2 zlote jablka 5 prochu 5 diamentow 3 enderperly"                                        stop                                player don't have {@item2}:                                        send "&6Nie posiadasz {@item2}"                                        stop                                player don't have {@item3}:                                        send "&6Nie posiadasz {@item3}"                                        stop                                player don't have {@item4}:                                        send "&6Nie posiadasz {@item4}"                                        stop                                player cannot build at <span class="z3b9f7bvb" id="z3b9f7bvb_9">block</span> under player:                                        send "&4Teren pod toba jest zajety :P"                                        stop                                player cannot build at block 100 meters northwest:                                        send "&4Teren na polnocny zachod jest zajety"                                        stop                                player cannot build at block 100 meters north:                                        send "&4Teren na polnoc jest zajety"                                        stop                                player cannot build at block 100 meters northeast:                                        send "&4Teren na polnocny wschod jest zajety"                                        stop                                player cannot build at block 100 meters west:                                        send "&4Teren na zachod jest zajety"                                        stop                                player cannot build at block 100 meters east:                                        send "&4Teren na wschod jest zajety"                                        stop                                player cannot build at block 100 meters southwest:                                        send "&4Teren na poludniowy zachud jest zajety"                                        stop                                player cannot build at block 100 meters south:                                        send "&4Teren na poludnie jest zajety"                                        stop                                player cannot build at block 100 meters southeast:                                        send "&4Teren na poludniowy wschod jest zajety"                                        stop                                if distance between {spawn} and location of player is greater than 150+50/2:                                        send "{@t} tworzenie zabezpieczen....."                                        execute console command "pex user %name of player% add worldedit.*"                                        execute console command "pex user %name of player% add worldguard.*"                                        wait 1 tick                                        execute player command "//pos1"                                        execute player command "//pos2"                                        execute player command "//expand 50 w"                                        execute player command "//expand 50 n"                                        wait 3 tick                                        execute player command "//expand 50 e"                                        execute player command "//expand 50 s"                                        execute player command "//expand <span class="z3b9f7bvb" id="z3b9f7bvb_7">vert</span>"                                        execute player command "region define gildia-%arg 1%"                                        execute player command "region flag gildia-%arg 1% chest-access allow"                                        execute player command "region flag gildia-%arg 1% use allow"                                        wait 3 tick                                        execute player command "region addowner gildia-%arg 1% %name of player%"                                        execute console command "pex user %name of player% remove worldedit.*"                                        execute console command "pex user %name of player% remove worldguard.*"                                        loop 98 times:                                                send ""                                        message "&6Zalozyles Gildie!"                                        set block under the player to dragon egg                                        broadcast "&aGracz %name of player% powiekszyl cuboid o 50 kratek!"                                        send "{@t} tworzenie zabezpieczen....."                                        set {gildia.tag.%name of player%} to arg 1                                        message "&6Zalozyles Gildie!"                                        set {gildia.%name of player%.owner} to true                                        set {gildia.home.%arg 1%} to location of player                                        broadcast "{@t} Gracz %name of player% zalozyl gildie o nazwie %arg 2% o tagu %arg 1%"                                        set {gildia.%name of player%} to true                                        set {_cos} to "%{gildia.tag.%name of player%}%"                                        add player to {gildia.ownerklanu.%{_cos}%::*}                                        add arg 1 to {listagildii::*}                                        wait 1 seconds                                        remove {@item1} from the player's inventory                                        remove {@item2} from the player's inventory                                        remove {@item3} from the player's inventory                                        remove {@item4} from the player's inventory                                        set {gildia.tag.%arg 1%} to true                                        wait 2 tick                                        set {baza.%arg 1%} to true                                else:                                        send "&6Zbyt blisko spawnu!"							else:								send "&6Tag gildii jest za dlugi!"
Odnośnik do komentarza
https://skript.pl/temat/1108-gildie-tag-oraz-nazwa/#findComment-8830
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ę...