Ola, estou criando esse tutorial mostrando como fazer o Sistema de AFK em seu OTServ, Entao vamos la Va Na Pasta De Seu OTServ / Data / Talkactions / Scripts - Copie qualquer arquivo .lua que esta la, tire tudo que a dentro dele e renomeie como 'afk'Coloque isso :Codigo:local time = 5 -- 1 = 1 sec, 2 = 2 sec, ...local say_events = {}local function SayText(cid)if isPlayer(cid) == TRUE thenif say_events[getPlayerGUID(cid)] ~= nil thenif isPlayer(cid) == TRUE thendoSendAnimatedText(getPlayerPosition(cid),"Ausente !", math.random(01,255))endsay_events[getPlayerGUID(cid)] = addEvent(SayText, time * 100 / 2, cid) end endreturn TRUEendfunction onSay(cid, words, param, channel) if(param == '') thendoPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Command param required.")return trueendif param == "on" thenif isPlayer(cid) == TRUE thendoSendAnimatedText(getPlayerPosition(cid),"Ausente !", math.random(01,255))endsay_events[getPlayerGUID(cid)] = addEvent(SayText, time * 1000, cid)doPlayerSendTextMessage(cid,MESSAGE_STATUS_WARNING ,"You Now Stated you are (afk).")elseif param == "off" thenstopEvent(say_events[getPlayerGUID(cid)])say_events[getPlayerGUID(cid)] = nildoPlayerSendTextMessage(cid,MESSAGE_STATUS_WARNING ,"You Now stated your are not (afk).")endreturn TRUEendDepois va em Pasta De Seu OTServ / Data / Talkactions / Talkactions.XMLProcure A Parte dos PlayersBote Isso :<talkaction words="!afk on" event="script" value="afk.lua"/>Obs : falando !afk off acaba com !afk on comeca!Gente entao e isso salve feche e useAbracos,Victor Morin /Ban com nick, hora e comentarioNome:(Um Novo Modo De Banir... ).Versao: (tfs 0.3.4+).Tipo do script: (talkactions.xml(talkaction.).Servidor Testado: (tfs 0.3.4+)Creditos: (Gesior.Pl) .Comentario: Como Ele Funciona.../ban Nick - Banir O jogador de tempo predefinido/ban Nick,12 - Banir O jogador por 12 horas/ban Nick,35,AFK BOT - Banir jogador de 35 horas com o comentario "AFK BOT"Voce pode Banir O Player offline jogadores!Adicone Istotalkactions.xmlCodigo:<talkaction log="yes" words="/ban" access="3" event="script" value="ban.lua"/>Crie O Nome Do Arquivo ban.luaCodigo:local default_comment = ""local default_lenght = 1 -- ban time in hoursfunction onSay(cid, words, param) local parametres = string.explode(param, ",") if(parametres[1] ~= nil) then local accId = getAccountIdByName(parametres[1]) if(accId > 0) then local lenght = default_lenght local comment = default_comment if(parametres[2] ~= nil and tonumber(parametres[2]) > 0) then lenght = tonumber(parametres[2]) end if(parametres[3] ~= nil) then comment = parametres[3] end doAddBanishment(accId, lenght * 3600, 23, ACTION_BANISHMENT, comment, getPlayerGUID(cid), comment) local player = getPlayerByNameWildcard(parametres[1]) if(isPlayer(player) == TRUE) then doRemoveCreature(player) end else doPlayerSendCancel(cid, "Player with name " .. parametres[1] .. " doesn't exist.") end else doPlayerSendCancel(cid, "You must enter name.") end return trueend Caso o 1o Script Nao Funcione Use Esse... Por: HermesCodigo:<?xml version="1.0" encoding="UTF-8"?><mod name="/ban command" version="1.0" author="Gesior.pl & modded by Hermes" contact="otland.net" enabled="yes"> <description> This mod will add new command for server staff - /ban. Usage: /ban Nick - ban player for default time (set in config) /ban Nick,12 - ban player for 12 hours /ban Nick,35,AFK BOT - ban player for 35 hours with comment "AFK BOT" </description> <config name="banishment_config"><![CDATA[ banconfig = { default_comment = "" default_lenght = 1 -- ban time in hours } ]]></config> <talkaction log="yes" words="/ban" access="3" event="buffer"><![CDATA[ domodlib('banishment_config') function onSay(cid, words, param) local parametres = string.explode(param, ",") if(parametres[1] ~= nil) then local accId = getAccountIdByName(parametres[1]) if(accId > 0) then local lenght = banconfig.default_lenght local comment = banconfig.default_comment if(parametres[2] ~= nil and tonumber(parametres[2]) > 0) then lenght = tonumber(parametres[2]) end if(parametres[3] ~= nil) then comment = parametres[3] end doAddBanishment(accId, lenght * 3600, 23, ACTION_BANISHMENT, comment, getPlayerGUID(cid), comment) local player = getPlayerByNameWildcard(parametres[1]) if(isPlayer(player) == TRUE) then doRemoveCreature(player) end else