Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

[Problem] ze skryptem...


Rekomendowane odpowiedzi

Opublikowano

Witam,

Mam problem z moim skryptem. Napisałem go i chyba coś zwaliłem. Próbowałem już wszystkiego, lecz nadal nie działa.

 

Errory:

>skript reload all
19:40:54 [INFO] [Skript] Reloading the config and all scripts...
19:40:55 [INFO] Loaded a total of 10567 english aliases
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 4 spaces (kody promocyjne.sk, line 4: 'variables:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 4 spaces (kody promocyjne.sk, line 7: 'trigger:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 6 spaces (kody promocyjne.sk, line 8: 'if {use.%player%} is true:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 14 spaces (kody promocyjne.sk, line 9: 'send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 6 spaces (kody promocyjne.sk, line 10: 'if {use.%player%} is false:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 14 spaces (kody promocyjne.sk, line 11: 'arg 1 is not empty:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 18 spaces (kody promocyjne.sk, line 12: 'arg 1 is "{@kod1}":')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 13: 'add 1 diamond named "&bZ kodu promocyjnego." to player')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 14: 'send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 15: 'set {use.%player%} to true')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 16: 'wait 24 hours')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 17: 'set {use.%player%} to false')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 18 spaces (kody promocyjne.sk, line 18: 'else:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 19: 'send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 18 spaces (kody promocyjne.sk, line 20: 'else:')
19:40:55 [SEVERE] indentation error: expected 8 spaces, but found 22 spaces (kody promocyjne.sk, line 21: 'send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b')
19:40:55 [SEVERE] '{use.%player%}=false' is not an entry (like 'name : value') (kody promocyjne.sk, line 5: '{use.%player%}=false')
19:40:55 [SEVERE] Required entry 'trigger' is missing in 'command /kod [<text>]' (kody promocyjne.sk, starting at line 6) (kody promocyjne.sk, line 6: 'command /kod [<text>]:')
19:40:55 [INFO] loaded 20 scripts with a total of 9 triggers and 23 commands in 0.38 seconds
19:40:55 [INFO] [Skript] Encountered 33 errors while reloading the config and all scripts!

A skrypt wygląda następująco:

options:
#Kody, za które otrzymujemy diament.
        kod1: 588515611
    variables:
        {use.%player%}=false
command /kod [<text>]:
    trigger:
      if {use.%player%} is true:
              send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"
      if {use.%player%} is false:
              arg 1 is not empty:
                  arg 1 is "{@kod1}":
                      add 1 diamond named "&bZ kodu promocyjnego." to player
                      send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"
                      set {use.%player%} to true
                      wait 24 hours
                      set {use.%player%} to false
                  else:
                      send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"
                  else:
                      send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b

Mam nadzieje, że ktoś pomoże. :)

 

(To "<remove>" sam dodałem. Teraz, bo tam była nazwa serwera. :))

 

sygnatura.png

Opublikowano

źle spacje porobiłeś, gdy pisze coś takiego

expected 8 spaces, but found 6 spaces

 

znaczy to że powinno być 8 spacji a znaleziono ich 6 :D

Opublikowano

Ok, trochę poprawiłem. Teraz wychodzi takie coś:

20:20:25 [INFO] [Skript] Reloading kody promocyjne.sk...
20:20:25 [WARNING] Empty configuration section! You might want to indent one or more of the subsequent lines to make them belong to this section or remove the colon at the end of the line if you don't want this line to start a section. (kody promocyjne.sk, line 4: 'variables:')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 8: 'if {use.%player%} is true:')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 9: 'send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 10: 'if {use.%player%} is false:')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 11: 'arg 1 is not empty:')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 9 spaces (kody promocyjne.sk, line 12: 'arg 1 is "{@kod1}":')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 13: 'add 1 diamond named "&bZ kodu promocyjnego." to player')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 14: 'send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 15: 'set {use.%player%} to true')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 16: 'wait 24 hours')
20:20:25 [SEVERE] indentation error: expected 16 spaces, but found 12 spaces (kody promocyjne.sk, line 17: 'set {use.%player%} to false')
20:20:25 [WARNING] Empty configuration section! You might want to indent one or more of the subsequent lines to make them belong to this section or remove the colon at the end of the line if you don't want this line to start a section. (kody promocyjne.sk, line 7: 'trigger:')
20:20:25 [WARNING] Empty configuration section! You might want to indent one or more of the subsequent lines to make them belong to this section or remove the colon at the end of the line if you don't want this line to start a section. (kody promocyjne.sk, line 18: 'else:')
20:20:25 [WARNING] Empty configuration section! You might want to indent one or more of the subsequent lines to make them belong to this section or remove the colon at the end of the line if you don't want this line to start a section. (kody promocyjne.sk, line 20: 'else:')
20:20:25 [SEVERE] '{use.%player%}=false' is not an entry (like 'name : value') (kody promocyjne.sk, line 5: '{use.%player%}=false')
20:20:25 [SEVERE] invalid line in options (kody promocyjne.sk, line 4: 'variables:')
20:20:25 [SEVERE] can't understand this event: 'command: /kod [<text>]' (kody promocyjne.sk, line 6: 'command: /kod [<text>]:')
20:20:25 [INFO] [Skript] Encountered 13 errors while reloading kody promocyjne.sk!
>

 

sygnatura.png

Opublikowano

A sprobuj to:

options:
#Kody, za które otrzymujemy diament.
		kod1: 588515611
	variables:
		{use.%player%}=false
command /kod [<text>]:
	trigger:
		if {use.%player%} is true:
			send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"
		if {use.%player%} is false:
			arg 1 is not empty:
				arg 1 is "{@kod1}":
					add 1 diamond named "&bZ kodu promocyjnego." to player
					send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"
					set {use.%player%} to true
					wait 24 hours
					set {use.%player%} to false
				else:
					send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"
			else:
				send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b

585051449511123978085.jpeg

Opublikowano

Powinno być dobrze

options:
        #Kody, za które otrzymujemy diament.
        kod1: 588515611
   
variables:
        {use.%player%}=false
 
command /kod [<text>]:
        trigger:
                if {use.%player%} is true:
                        send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"
                        if {use.%player%} is false:
                arg 1 is not empty:
                        arg 1 is "{@kod1}":
                                add 1 diamond named "&bZ kodu promocyjnego." to player
                                send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"
                                set {use.%player%} to true
                                wait 24 hours
                                set {use.%player%} to false
                        else:
                                send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"
                else:
                        send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b

Lub

http://pastebin.com/eH1FgJgq

1394047278-U990178.png

Opublikowano

Teraz mam jeden błąd:

20:36:39 [INFO] [Skript] Reloading kody promocyjne.sk...
20:36:39 [WARNING] Empty configuration section! You might want to indent one or more of the subsequent lines to make them belong to this section or remove the colon at the end of the line if you don't want this line to start a section. (kody promocyjne.sk, line 33: 'if {use.%player%} is false:')
20:36:39 [INFO] [Skript] Successfully reloaded kody promocyjne.sk.

Sorki, że piszę byle co, ale jestem dopiero początkującym skrypterem. :)

 

sygnatura.png

Opublikowano

A teraz powinno dzialac :D

options:
#Kody, za które otrzymujemy diament.
		kod1: 588515611
	variables:
		{use.%player%}=false
command /kod [<text>]:
	trigger:
		if {use.%player%} is true:
			send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"
		if {use.%player%} is false:
			arg 1 is not empty:
				arg 1 is "{@kod1}":
					add 1 diamond named "&bZ kodu promocyjnego." to player
					send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"
					set {use.%player%} to true
					wait 24 hours
					set {use.%player%} to false
				else:
					send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"
			else:
				send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b"

585051449511123978085.jpeg

Opublikowano

Hardstyl3r ty bambusie. ;d Masz:

options:
#Kody, za które otrzymujemy diament.
    kod1: 588515611
variables:
    {use.%player%}=false
command /kod [<text>]:
    trigger:
        if {use.%player%} is true:
            send "&9[<remove>] &bPoczekaj 24godz. aby ponownie uzyc tego kodu!"
        if {use.%player%} is false:
            arg 1 is empty:
                send "&9[<remove>] &bPoprawne uzycie to: &a/kod <kod>&b"
            arg 1 is "{@kod1}":
                add 1 diamond named "&bZ kodu promocyjnego." to player
                send "&9[<remove>] &bKod &a&l%arg%&b zostal &apomyslnie &bzatwierdzony!"
                set {use.%player%} to true
                wait 24 hours
                set {use.%player%} to false
            else:
                send "&9[<remove>] &bKod &a&l%arg%&b zostal &cblednie &bzatwierdzony!"

//EDIT: Skoro twoje hobby to niby Java to byś plugin napisał, a nie skrypty. ^^

//EDIT2: Nie polecam jego serwera, dostałem bana za mówienie prawdy (spawn z neta, nawet linka dałem a oni mnie zbanowali :D).

img.jpg

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...