Ir para conteúdo

Featured Replies

Postado

TFS 0,4

Protocolo: 8.60

Pedido: Spell

Olá, será que alguem poderia me ajudar?

Gostaria de colocar em meu servidor um spell que impeça o adversário de encher a mana por 5 segundos.

A ideia era que o player ficasse sem soltar nenhum spell, até encontrei um codigo de spell de muted, nao funcionou em meu servidor, mas se alguem conseguir fazer o spell de impedir a mana de encher melhor ainda.

Segue abaixo o spell de muted que nao funcionou.

local condition = createConditionObject(CONDITION_MUTED)
setConditionParam(condition, CONDITION_PARAM_TICKS, 2000)

local chance = 60

function silence(tar, text)
    if(isCreature(tar) == true) then
        doSendAnimatedText(getCreaturePosition(tar), text, 215)
        doAddCondition(tar, condition)
    end
    return true
end


function onCastSpell(cid, var)
    local tar = getCreatureTarget(cid)
    if hasCondition(tar, CONDITION_MUTED) == true then
        return false
    else
        if isCreature(tar) == true then
if math.random(1,100) <= chance then
local text = "SILENCE"
                    silence(tar, text)     
else
local text = "MISS"
doSendAnimatedText(getCreaturePosition(tar), text, 215)
end
        else
            if isPlayer(cid) == true then
                doPlayerSendCancel(cid, "Silence can be cast only on other creatures.")
            end
            return false
        end
    end
    return true
end 

 

Encontrei esse spell neste link: https://tibiaking.com/forums/topic/39212-spell-que-da-muted-no-target/

Spell com erro: Silence.lua

spell.PNG

Editado por underpunk (veja o histórico de edições)

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.

Conteúdo Similar

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.9k

Informação Importante

Confirmação de Termo