112
edycji
Zmiany
Przejdź do nawigacji
Przejdź do wyszukiwania
Utworzono nową stronę "'''Operatory''' służą albo do porównywania liczb(relacyjne) lub do pisania warunków. == Operatory relacyjne == Operatory logiczne służą do porównan..."
'''Operatory''' służą albo do porównywania liczb(relacyjne) lub do pisania [[warunki|warunków]].
== Operatory relacyjne ==
Operatory logiczne służą do porównania liczb.
* '''<''' lub '''is less than''' - mniejsze niż
* '''>''' lub '''is greater than''' - większe niż
* '''=''' lub '''is equal to''' - równe
* '''>=''' lub '''is greater or equal to''' - większe lub równe
* '''<=''' lub '''is less or equal to''' - mniejsze lub równe
* '''!= | !>= | !<''' lub isn't - nie jest
Przykład:
</pre>command /donate:
trigger:
if {kasa::%player%} >= 5000:
remove 5000 from {kasa::%player%}
send "Dziękujemy za donate!"</pre>
== Operatory logiczne ==
Te operatory służą do jego urozmaicenia oraz skrócenia kodu
* '''or''' - lub
* '''and''' - i
* '''not''' - nie jest
Przykład:
<pre>command /ciastko [<player>]:
trigger:
if arg-1 is not online:
send "Ten gracz nie jest online"
else:
if arg-1 is "Libter" or "bvcz":
send "+1"</pre>
[[Kategoria:Skript]]
== Operatory relacyjne ==
Operatory logiczne służą do porównania liczb.
* '''<''' lub '''is less than''' - mniejsze niż
* '''>''' lub '''is greater than''' - większe niż
* '''=''' lub '''is equal to''' - równe
* '''>=''' lub '''is greater or equal to''' - większe lub równe
* '''<=''' lub '''is less or equal to''' - mniejsze lub równe
* '''!= | !>= | !<''' lub isn't - nie jest
Przykład:
</pre>command /donate:
trigger:
if {kasa::%player%} >= 5000:
remove 5000 from {kasa::%player%}
send "Dziękujemy za donate!"</pre>
== Operatory logiczne ==
Te operatory służą do jego urozmaicenia oraz skrócenia kodu
* '''or''' - lub
* '''and''' - i
* '''not''' - nie jest
Przykład:
<pre>command /ciastko [<player>]:
trigger:
if arg-1 is not online:
send "Ten gracz nie jest online"
else:
if arg-1 is "Libter" or "bvcz":
send "+1"</pre>
[[Kategoria:Skript]]