Ir para conteúdo

Featured Replies

Postado
  • Autor
  Em 21/02/2017 em 19:41, xWhiteWolf disse:

vai em data/lib/constant.lua e dá ctrl f em "MESSAGE_STATUS_CONSOLE_ORANGE"

se não achar nada vc já tem sua resposta, esse tipo de mensagem não existe, aí vc dá ctr f em MESSAGE e vai achar algo parecido com isso aqui:

MESSAGE_FIRST = 18
MESSAGE_STATUS_CONSOLE_RED = MESSAGE_FIRST
MESSAGE_EVENT_ORANGE = 19
MESSAGE_STATUS_CONSOLE_ORANGE = 20
MESSAGE_STATUS_WARNING = 21
MESSAGE_EVENT_ADVANCE = 22
MESSAGE_EVENT_DEFAULT = 23
MESSAGE_STATUS_DEFAULT = 24
MESSAGE_INFO_DESCR = 25
MESSAGE_STATUS_SMALL = 26
MESSAGE_STATUS_CONSOLE_BLUE = 27
MESSAGE_LAST = MESSAGE_STATUS_CONSOLE_BLUE

escolha uma "cor" e substitua, vc pode colocar ou o nome OU o numero.

 

Eu achei uma parte assim igual voce colocou. estranho que antes a mensagem pegava com esse script

 

local config = 
{
    segundos = 5,
    lerIP = "yes"
}
config.lerIP = getBooleanFromString(config.lerIP)
local m_lastLogin, m_lastIP = 0, 0
function onLogout(cid)
doPlayerSendTextMessage(cid, 20, "Por favor espere 5 segundos para usar a função Logout.")
    local timeNow, playerIP = os.time(), getPlayerIp(cid)
        if(m_lastLogin + config.segundos >= timeNow and
            (config.lerIP == FALSE or m_lastIP == playerIP)) then
            return false
        end
    m_lastIP = playerIP
    m_lastLogin = timeNow
    return true
end

 

  Em 21/02/2017 em 20:06, Gustavo Ntos disse:

 


local config =
{
    storage = 23567,
    tempo = 5,
    lerIP = "yes"
}
config.lerIP = getBooleanFromString(config.lerIP)
local m_lastLogin, m_lastIP = 0, 0
function onLogout(cid)
    if exhaustion.check(cid, config.storage) then
        doPlayerSendTextMessage(cid, 18, "Aguarde " .. exhaustion.get(cid, config.storage) .. " segundos para usar esse comando novamente.")
        return true
    end
    local timeNow, playerIP = os.time(), getPlayerIp(cid)
    if(m_lastLogin + config.tempo >= timeNow and
    (config.lerIP == FALSE or m_lastIP == playerIP)) then
        return false
    end
    
    m_lastIP = playerIP
    m_lastLogin = timeNow
    exhaustion.set(cid, config.storage, config.tempo*60)
    
    return true
end

 

 

Vou testar

 @Gustavo Ntos mesma coisa, não desloga mas tbm não manda a mensagem

  • Respostas 6
  • Visualizações 562
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • Estou deduzindo que sua tfs seja 1.x + então tente isto no lugar de "doPlayerSendTextMessage"  

  • vai em data/lib/constant.lua e dá ctrl f em "MESSAGE_STATUS_CONSOLE_ORANGE" se não achar nada vc já tem sua resposta, esse tipo de mensagem não existe, aí vc dá ctr f em MESSAGE e vai achar algo pa

  • local config = {     storage = 23567,     tempo = 5,     lerIP = "yes" } config.lerIP = getBooleanFromString(config.lerIP) local m_lastLogin, m_lastIP = 0, 0 function onLogout(cid)     if exhaustion.c

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.6k

Informação Importante

Confirmação de Termo