command /exp-give [] [] [] [] []: usage: /exp-give [-s] [-n] [-c] permission: * permission message: {@msg-no-perm} executable by: console and player trigger: if arg 1 is not set: send "&f/exp-give &c &f [-s] [-n] [-c]" stop set {_p} to arg 1 if {lv::%{_p}%} is not set: send "{@msg-not-found}" stop if arg 2 is not set: send "&f/exp-give &c &f[-s] [-n] [-c]" stop if arg 2 > {@max-exp-give-limit}: send "&cPodana ilość expa jest zbyt duża." stop if arg 2 < -{@max-exp-give-limit}: send "&cPodana ilość expa jest zbyt duża." stop if {lv::%{_p}%} > {@max-lvl}: set {lv::%{_p}%} to {@max-lvl}-1 execute console command "maxexpchange %{_p}%" set {xp::%{_p}%} to {mxp::%{_p}%} set {lv::%{_p}%} to {@max-lvl} if {lv::%{_p}%} = {@max-lvl}: if {xp::%{_p}%} is not {mxp::%{_p}%}: execute console command "maxexpchange %{_p}%" set {xp::%{_p}%} to {mxp::%{_p}%} if {lv::%{_p}%} < {@max-lvl}: if {xp::%{_p}%} = {mxp::%{_p}%}: set {xp::%{_p}%} to 0 execute console command "maxexpchange %{_p}%" if {dxppl.%{_p}%} < now: delete {dxppl.%{_p}%} {lv::%{_p}%} < {@max-lvl} set {_arg2} to arg 2 if {@exp-rounding} is true: set {xp::%{_p}%} to round {xp::%{_p}%} set {_arg2} to round up {_arg2} if {expmultiplier} is not set: if arg 3 or arg 4 or arg 5 is "-n": set {_x2} to 1 set {_exp} to "{@exp-name}" else: set {_x2} to 1 set {_exp} to "{@exp-name}" if {dxppl.%{_p}%} is set: set {_x2} to {@exp-multiplier-1} set {_exp} to "{@multiplier-1-name}" if {expmultiplier} is set: if arg 3 or arg 4 or arg 5 is "-n": set {_x2} to 1 set {_exp} to "{@exp-name}" else: set {_x2} to {@exp-multiplier-1} set {_exp} to "{@multiplier-1-name}" if {@allow-multiplier-2} is true: if {dxppl.%{_p}%} is set: set {_x2} to {@exp-multiplier-2} set {_exp} to "{@multiplier-2-name}" if {_arg2} < 0: if {@multiplier-negative-exp} is false: set {_x2} to 1 set {_exp} to "{@exp-name}" set {_prexp::%{_p}%} to {xp::%{_p}%} if {xp::%{_p}%} < {mxp::%{_p}%}: add {_arg2}*{_x2} to {xp::%{_p}%} set {_ilosc} to "%{_arg2}*{_x2}%" if {_arg2} > 0: set {_znak} to "{@exp-give-plus}" if {_arg2} <= 0: set {_znak} to "{@exp-give-minus}" if {xp::%{_p}%} < 0: if {@max-negative-exp} <= 0: if {xp::%{_p}%} < {@max-negative-exp}: if {_prexp::%{_p}%} < {@max-negative-exp}: set {xp::%{_p}%} to {_prexp::%{_p}%} else: set {xp::%{_p}%} to {@max-negative-exp} if {xp::%{_p}%} >= {mxp::%{_p}%}: if {@large-exp-mode} is 1: set {_iloscgl.%{_p}%} to {_ilosc}-{mxp::%{_p}%}-{xp::%{_p}%} add 1 to {lv::%{_p}%} if {@RPG-system-integration} is true: execute console command "umiejetnosci %{_p}% add" execute console command "maxexpchange %{_p}%" loop {@max-lvl} times: if {_iloscgl.%{_p}%} >= {mxp::%{_p}%}: set {_iloscgl.%{_p}%} to {_iloscgl.%{_p}%}-{mxp::%{_p}%} add 1 to {lv::%{_p}%} if {@RPG-system-integration} is true: execute console command "umiejetnosci %{_p}% add" execute console command "maxexpchange %{_p}%" if {lv::%{_p}%} >= {@max-lvl}: stop loop if {_iloscgl.%{_p}%} < {mxp::%{_p}%}: set {xp::%{_p}%} to {_iloscgl.%{_p}%} stop loop if {@large-exp-mode} is 2: add 1 to {lv::%{_p}%} if {@RPG-system-integration} is true: execute console command "umiejetnosci %{_p}% add" execute console command "maxexpchange %{_p}%" if {lv::%{_p}%} >= {@max-lvl}: set {xp::%{_p}%} to {mxp::%{_p}%} set {lv::%{_p}%} to {@max-lvl} else: if {@large-exp-mode} is 2: set {xp::%{_p}%} to 0 send "{@msg-lvl-up}" to {_p} if {@lvlup-lighting-effect} is true: strike lightning effect at location of {_p} execute console command "levels-set-nick %{_p}%" if {@head-level-enabled} is true: execute console command "scoreboard players set %{_p}% Levels %{lv::%{_p}%}%" if {@broadcast-lvlup} is true: if {@bc-each-level} is true: set {_bclvlup} to true if {lv::%{_p}%} is {@distinction-levels}: set {_bclvlup} to true if {_bclvlup} is set: loop all players: if {_p} is not loop-player: send "{@msg-lvl-up-bc}" to loop-player if {xp::%{_p}%} is -0: set {xp::%{_p}%} to 0 if {@use-levels-bar} is true: if {lv::%{_p}%} is set: if {_p}'s level progress is not {xp::%{_p}%}/{mxp::%{_p}%}: if {xp::%{_p}%} <= 0: set {_p}'s level progress to 0 else: set {_p}'s level progress to {xp::%{_p}%}/{mxp::%{_p}%} if {_p}'s level is not {lv::%{_p}%}: set {_p}'s level to {lv::%{_p}%} if executor is player: if player is not {_p}: send "{@msg-exp-other}" if arg 3 or arg 4 or arg 5 is "-c": send "{@msg-exp-other}" to console if arg 3 or arg 4 or arg 5 is "-s": stop else: send "{@msg-exp}" to {_p}