Ir para conteúdo

Líderes

Conteúdo Popular

Exibindo conteúdo com a maior reputação em 03/13/23 em todas áreas

  1. (Resolvido)Spell kamui

    koyotestark reagiu a xWhiteWolf por uma resposta no tópico

    1 ponto
    a de se teleportar eu ja fiz.. a outra eu não vou fazer porque ela requer um nível de detalhes que eu não to afim de ficar discutindo com você até você me explicar. local config = { pos = {x=42, y=234, z=7}, -- posição da aegis dimension tempo = 15, -- tempo pra voltar effect1 = 66, -- efeito ao ser teleportado effect2 = 10, -- efeito ao voltar storage = 19329 } local cooldown = 60 function onCastSpell(cid, var) if isPlayer(cid) then if os.time() - getPlayerStorageValue(cid, config.storage) >= cooldown then doPlayerSetStorageValue(cid, config.storage, os.time()) addEvent(doTeleportThing, 1000*config.tempo, cid, getThingPos(cid), true) addEvent(doSendMagicEffect, 1000*config.tempo, getThingPos(cid), config.effect2) doSendMagicEffect(getThingPos(cid), config.effect1) doTeleportThing(cid, config.pos) if isCreature(cid) then doPlayerSendTextMessage(cid, 27, "You were teleported by yourself.") end for i = 1,config.tempo do addEvent(function() if isCreature(cid) then doPlayerSendTextMessage(cid,25,"You'll be back in " .. config.tempo -i +1 .. " second(s)") end end, 1000*i) end else doPlayerSendCancel(cid, "Your skill is in cooldown, you must wait "..(cooldown - (os.time() - getPlayerStorageValue(cid, config.storage))).." seconds.") end end return true end
  2. (Resolvido)Spell kamui

    koyotestark reagiu a xWhiteWolf por uma resposta no tópico

    1 ponto
    local config = { pos = {x=42, y=234, z=7}, -- posição da aegis dimension tempo = 15, -- tempo pra voltar effect1 = 66, -- efeito ao ser teleportado effect2 = 10 -- efeito ao voltar } function onCastSpell(cid, var) if isPlayer(getCreatureTarget(cid)) then target = getCreatureTarget(cid) addEvent(doTeleportThing, 1000*config.tempo, target, getThingPos(target), true) addEvent(doSendMagicEffect, 1000*config.tempo, getThingPos(target), config.effect2) doSendMagicEffect(getThingPos(target), config.effect1) doTeleportThing(target, config.pos) if isCreature(cid) then doPlayerSendTextMessage(target, 27, "You were teleported by ".. getCreatureName(cid) ..".") end if isPlayer(cid) and isCreature(target) then doPlayerSendTextMessage(cid, 27, "You teleported ".. getCreatureName(target) .."!") end for i = 1,config.tempo do addEvent(function() if isCreature(target) then doPlayerSendTextMessage(target,25,"You'll be back in " .. config.tempo -i +1 .. " second(s)") end end, 1000*i) end else doPlayerSendCancel(cid, "You can only use this spell in players") end return true end
Líderes está configurado para São Paulo/GMT-03:00

Informação Importante

Confirmação de Termo