Ir para conteúdo
  • Cadastre-se

(Resolvido)ao logar receber msg estilo pm


Ir para solução Resolvido por WooX,

Posts Recomendados

7 minutos atrás, Way20 disse:

Poste seu login.lua

local config = {
    loginMessage = getConfigValue('loginMessage'),
    useFragHandler = getBooleanFromString(getConfigValue('useFragHandler'))
}

function onLogin(cid)
    local loss = getConfigValue('deathLostPercent')
    if(loss ~= nil) then
        doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
        doPlayerAddBlessing(cid, 1)
        doPlayerAddBlessing(cid, 2)
        doPlayerAddBlessing(cid, 3)
        doPlayerAddBlessing(cid, 4)
        doPlayerAddBlessing(cid, 5)
        doPlayerAddPremiumDays(cid, 2)
        
    end

    local accountManager = getPlayerAccountManager(cid)
    if(accountManager == MANAGER_NONE) then
        local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage
        if(lastLogin > 0) then
            doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
            str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."
        else
            str = str .. " Please choose your outfit."
            doPlayerSendOutfitWindow(cid)
        end

        doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
    elseif(accountManager == MANAGER_NAMELOCK) then
        addEvent(valid(doCreatureSay), 500, cid, "Hello, it appears that your character has been locked for name violating rules, what new name would you like to have?", TALKTYPE_PRIVATE_NP, true, cid)
    elseif(accountManager == MANAGER_ACCOUNT) then
        addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to manage your account. If you would like to start over, type {cancel} anywhere.", TALKTYPE_PRIVATE_NP, true, cid)
    else
        addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to create an account or {recover} to recover an account.", TALKTYPE_PRIVATE_NP, true, cid)
    end

    if(not isPlayerGhost(cid)) then
        doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
    end
 
     registerCreatureEvent(cid, "AntiMC")
     registerCreatureEvent(cid, "FragReward")
     registerCreatureEvent(cid, "CheckVip")
     registerCreatureEvent(cid, "onPrepareDeath")
     registerCreatureEvent(cid, "PlayerLogout")
     registerCreatureEvent(cid, "onPrepareDeath")
     registerCreatureEvent(cid, "deathBroadcast")
registerCreatureEvent(cid, "LevelMax")
     registerCreatureEvent(cid, "DeathBroadcast")
         registerCreatureEvent(cid, "StartSkills")
    registerCreatureEvent(cid, "Idle")
    if(config.useFragHandler) then
        registerCreatureEvent(cid, "SkullCheck")
      registerCreatureEvent(cid, "zombieevent")
      registerCreatureEvent(cid, "ProtectMl")
      registerCreatureEvent(cid, "Protectskill")
      registerCreatureEvent(cid, "IconMap")
registerCreatureEvent(cid, "deathchannel")
doPlayerOpenChannel(cid, 9)
doPlayerOpenChannel(cid, 15)
    end
    registerCreatureEvent(cid, "ReportBug")
registerCreatureEvent(cid, "fraglook")

if getPlayerName(cid) == "Account Manager" and #getPlayersByIp(getPlayerIp(cid)) > 10 then
        return false
    end

    return true
end

Link para o post
Compartilhar em outros sites
  • Respostas 21
  • Created
  • Última resposta

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) local loginmsg = "[DOUBLE POINTS]: Receba pontos em dobro para qualquer valores acima de R$10,00! Promoção estendida até dia 06/05!." doCreatureSay(getCreatureByName(getCreatureName(cid)), loginmsg, TALKTYPE_PRIVATE, false, cid) local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlayerSetLossPercent(cid, PLAYE

local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10) doPlayerAddBlessing(cid, 1) doPlayerAddBlessing(cid, 2) doPlayerAddBlessing(cid, 3) doPlayerAddBlessing(cid, 4) doPlayerAddBlessing(cid, 5) doPlayerAddPremiumDays(cid, 2) end local acc

Agora sim, testa ai. local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) local loginmsg = "[DOUBLE POINTS]: Receba pontos em dobro para qualquer valores acima de R$10,00! Promoção estendida até dia 06/05!." doCreatureSay(getCreatureByName("[Server Information]"), loginmsg, TALKTYPE_PRIVATE, false, cid) local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlay

Posted Images

Posta dentro

 

 

 

 

 

Nós somos aquilo que fazemos repetidamente. Excelência, não é um modo de agir, mas um hábito.

                                                                                                                                                                                                                                        Aristóteles 

Link para o post
Compartilhar em outros sites
5 minutos atrás, Way20 disse:

Posta dentro



 

ei pow está em branco kkk

 

ei pow está em branco kkk

Link para o post
Compartilhar em outros sites
Agora, helix758 disse:

 

ei pow está em branco kkk

Sim, postei apenas para que você possa ver e copiar, posta seu código dentro disto.

 

 

 

Nós somos aquilo que fazemos repetidamente. Excelência, não é um modo de agir, mas um hábito.

                                                                                                                                                                                                                                        Aristóteles 

Link para o post
Compartilhar em outros sites
local config = {
	loginMessage = getConfigValue('loginMessage'),
	useFragHandler = getBooleanFromString(getConfigValue('useFragHandler'))
}

function onLogin(cid)
	local loss = getConfigValue('deathLostPercent')
	if(loss ~= nil) then
		doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
		doPlayerAddBlessing(cid, 1)
		doPlayerAddBlessing(cid, 2)
		doPlayerAddBlessing(cid, 3)
		doPlayerAddBlessing(cid, 4)
		doPlayerAddBlessing(cid, 5)
		doPlayerAddPremiumDays(cid, 2)
		
	end

	local accountManager = getPlayerAccountManager(cid)
	if(accountManager == MANAGER_NONE) then
		local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage
		if(lastLogin > 0) then
			doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
			str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."
		else
			str = str .. " Please choose your outfit."
			doPlayerSendOutfitWindow(cid)
		end

		doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
	elseif(accountManager == MANAGER_NAMELOCK) then
		addEvent(valid(doCreatureSay), 500, cid, "Hello, it appears that your character has been locked for name violating rules, what new name would you like to have?", TALKTYPE_PRIVATE_NP, true, cid)
	elseif(accountManager == MANAGER_ACCOUNT) then
		addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to manage your account. If you would like to start over, type {cancel} anywhere.", TALKTYPE_PRIVATE_NP, true, cid)
	else
		addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to create an account or {recover} to recover an account.", TALKTYPE_PRIVATE_NP, true, cid)
	end



	if(not isPlayerGhost(cid)) then
		doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
	end
 
     registerCreatureEvent(cid, "AntiMC")
     registerCreatureEvent(cid, "FragReward")
     registerCreatureEvent(cid, "CheckVip")
     registerCreatureEvent(cid, "onPrepareDeath")
     registerCreatureEvent(cid, "PlayerLogout")
     registerCreatureEvent(cid, "onPrepareDeath")
     registerCreatureEvent(cid, "deathBroadcast")
registerCreatureEvent(cid, "LevelMax")
     registerCreatureEvent(cid, "DeathBroadcast")
         registerCreatureEvent(cid, "StartSkills")
	registerCreatureEvent(cid, "Idle")
	if(config.useFragHandler) then
		registerCreatureEvent(cid, "SkullCheck")
      registerCreatureEvent(cid, "zombieevent")
      registerCreatureEvent(cid, "ProtectMl")
      registerCreatureEvent(cid, "Protectskill")
      registerCreatureEvent(cid, "IconMap")
registerCreatureEvent(cid, "deathchannel")
doPlayerOpenChannel(cid, 9)
doPlayerOpenChannel(cid, 15)
	end
	registerCreatureEvent(cid, "ReportBug")
registerCreatureEvent(cid, "fraglook")



if getPlayerName(cid) == "Account Manager" and #getPlayersByIp(getPlayerIp(cid)) > 10 then
		return false
	end

	return true
end

 

@Way20

Link para o post
Compartilhar em outros sites

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

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

  • Estatísticas dos Fóruns

    96847
    Tópicos
    519607
    Posts



×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo