Ir para conteúdo
Banner com Efeitos

Featured Replies

Postado

Nossa, desculpa. Tinha esquecido dessa dúvida. Me mande PM pra eu te adicionar skype e te ajudar melhor.

Teste o script agora e me mande todos os prints que deu no console:

 

local function Teleport(cid)
    doSendAnimatedText(getPlayerPosition(cid), "Aaaaah...", TEXTCOLOR_BLUE)

    local templo = {x = 442, y = 549, z = 7}

    for j = 0, 60 do
        starting = {x = 839 + j, y = 952, z = 7, stackpos = 253}

        for i = 0, 60 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 61 do
        starting = {x = 1128 + j, y = 1120, z = 6, stackpos = 253}

        for i = 0, 6 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 14 do
        starting = {x = 1151 + j, y = 1115, z = 6, stackpos = 253}

        for i = 0, 5 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 14 do
        starting = {x = 1151 + j, y = 1127, z = 6, stackpos = 253}

        for i = 0, 5 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 49 do
        starting = {x = 1134 + j, y = 1120, z = 5, stackpos = 253}

        for i = 0, 6 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 14 do
        starting = {x = 1151 + j, y = 1115, z = 5, stackpos = 253}

        for i = 0, 5 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    for j = 0, 14 do
        starting = {x = 1151 + j, y = 1127, z = 5, stackpos = 253}

        for i = 0, 5 do
            checking = {x = starting.x, y = starting.y + i, z = starting.z, stackpos = starting.stackpos}
            creature = getThingfromPos(checking)

            if isPlayer(creature.uid) then
                doTeleportThing(creature.uid, templo)
            end
        end
    end

    return true
end

function onKill(cid, target, lastHit)
    local monstros = {
            "Gran Tower",
            "gran tower"
        }

    local nome = getCreatureTarget(cid) and getCreatureName(getCreatureTarget(cid)) or ""

    print("Creatuer name: " .. nome)

    if isInArray(monstros, nome) and isMonster(target) then
        if getPlayerStorageValue(cid, 13340) ~= 1 then
            print("Player storage ~= 1")

            setGlobalStorageValue(13340, getPlayerGuildId(cid))
            granEffect(cid)

            if getPlayerStorageValue(cid, 13340) == 0 then
                print("Player storage == 0")

                stopEvent(events[cid])

                print("Error? " .. events[cid])

                doSendMagicEffect(getCreaturePosition(cid), 47)
                broadcastMessage("O player ".. getPlayerName(cid) .." conquistou o Gran Castle, e todos membros da guild ".. getPlayerGuildName(cid) .." acabam de receber a Gran Aura.")
            end

            addEvent(Teleport, 1000, cid)
        end
    end

    return true
end

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

  • Respostas 10
  • Visualizações 1.2k
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • Posta a função granEffect junto com onde é definido uma tabela com nome granEffect também

  • Troca stopEvent(granEffect[cid]) por stopEvent(events[cid])

  • Você mudou algo a mais. Mande o script de como está agora. Ou é possível que tenha dado erro no console. Veja se tem algum erro no console.

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.7k

Informação Importante

Confirmação de Termo