addCommandHandler(\"setlevel\",function (source, commandName, otherPlayer, level)if otherPlayer and level then if isElement(getPlayerFromName(otherPlayer)) then if type(level) == \"string\" or tonumber(level) < 0 or tonumber(level) > 5 then outputChatBox(\"#E74C3CNincs ilyen szint!\", source, 0, 0, 0, true) else outputChatBox(\"Jó szint\") end else outputChatBox(\"#E74C3CNincs ilyen játékos!\", source, 0, 0, 0, true) endelse outputChatBox(\"#00B7FFHasználat: #FFFFFF/setlevel <Játékos> <Szint>\", source, 0, 0, 0, true)endend)
type(level) == \"string\"
addCommandHandler(\"promote\",function (source, commandName, otherPlayer)if otherPlayer then if isElement(getPlayerFromName(otherPlayer)) then if playerszint == 5 then outputChatBox(\"#E74C3CEzt a játékost nem fokozhatod fel!\", source, 0, 0, 0, true) else local oldlevel = getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\") setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", getElementData(getPlayerFromName(otherPlayer)) + 1) outputChatBox(\"#FFFFFF\".. getPlayerName(source) ..\" #00B7FFmegváltoztatta #FFFFFF\".. getPlayerName(getPlayerFromName(otherPlayer)) ..\" #00B7FFjátékos adminisztrátori szintjét. #FFFFFF(\".. oldlevel ..\" => \".. getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\") ..\")\") end else outputChatBox(\"#E74C3CNincs ilyen játékos!\", source, 0, 0, 0, true) endelse outputChatBox(\"#00B7FFHasználat: #FFFFFF/promote <Játékos>\", source, 0, 0, 0, true)endend)addCommandHandler(\"demote\",function (source, commandName, otherPlayer)if otherPlayer then if isElement(getPlayerFromName(otherPlayer)) then if getElementData(getPlayerFromName(otherPlayer, \"AdminLevel\")) == 0 then outputChatBox(\"#E74C3CEzt a játékost nem fokozhatod le!\", source, 0, 0, 0, true) else local oldlevel = getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\") setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", getElementData(getPlayerFromName(otherPlayer)) - 1) outputChatBox(\"#FFFFFF\".. getPlayerName(source) ..\" #00B7FFmegváltoztatta #FFFFFF\".. getPlayerName(getPlayerFromName(otherPlayer)) ..\" #00B7FFjátékos adminisztrátori szintjét. #FFFFFF(\".. oldlevel ..\" => \".. getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\") ..\")\") end else outputChatBox(\"#E74C3CNincs ilyen játékos!\", source, 0, 0, 0, true) endelse outputChatBox(\"#00B7FFHasználat: #FFFFFF/demote <Játékos>\", source, 0, 0, 0, true)endend)
setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", getElementData(getPlayerFromName(otherPlayer)) + 1)
setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\") + 1)
setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", oldlevel + 1)
setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", oldlevel + 1)setElementData(getPlayerFromName(otherPlayer), \"AdminLevel\", oldlevel - 1)
attempt to perform aritmetic on local \'oldlevel\' (a boolean value)
local oldlevel = getElementData(getPlayerFromName(otherPlayer), \"AdminLevel\")