Em, data\talkactions\talkaction.xml
Adicione:
<talkaction words="!comandos" event="script" value="comandos.lua"/>
Em, data\talkactions\scripts
Crie um arquivo com o nome de comandos.lua
Adicione:
local config = {
ingameGuilds = getBooleanFromString(getConfigValue('ingameGuildManagement'))
}
function onSay(cid, words, param, channel)
local playerAccess, t = getPlayerAccess(cid), {}
for i, talk in ipairs(getTalkActionList()) do
if(not talk.hidden and playerAccess >= talk.access) then
local tmp = talk.words:sub(1, 1):trim()
if((config.ingameGuilds or (talk.functionName ~= "guildjoin" and talk.functionName ~= "guildcreate")) and (tmp == "!" or tmp == "/")) then
table.insert(t, talk)
end
end
end
table.sort(t, function(a, b) return a.access > b.access end)
local lastAccess, str = -1, ""
for i, talk in ipairs(t) do
local line = ""
if(lastAccess ~= talk.access) then
if(i ~= 1) then
line = "\n"
end
lastAccess = talk.access
end
str = str .. line .. talk.words .. "\n"
end
doShowTextDialog(cid, 2160, str)
return true
end
Pronto agora para usar o comando utilize !comandos.
Flw :*



info
Grupo: Campones
Registrado: 11/12/10
Posts: 10
Reputação: +2
Tipo do script:Talk action
Protocolo (versão do Tibia): 8.54
Nível de experiência: media alta
Adicionais/Informações:
intao gente, creio que é uma script muito fácil de se fazer, procurei por ai e não achei...
é uma talk action q mostra uma lista de informaçoes.
ficaria muito grato se alguem ajudasse..
abraços
Editado Janeiro 13 por Piporealino