Jump to content

Gengo

Cavaleiro
  • Posts

    177
  • Joined

  • Last visited

  • Days Won

    53

Gengo last won the day on December 3 2024

Gengo had the most liked content!

About Gengo

Perfil

  • Gênero
    Masculino

Informações

  • Char no Tibia
    stor akia
  • Forma que conheci o xTibia
    Otservs
  • Sou
    Programador

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Gengo's Achievements

Single Status Update

See all updates by Gengo

  1. Ei sobre aquele que você me mandou de item 

    Eu não consegui usar com item de use with dá "Você só pode usar em players" mesmo em players.

    1. Show previous comments  5 more
    2. mrlhsl

      mrlhsl

      Tá como item nos actions

    3. Gengo

      Gengo

      local kamui = {
      	posTeleport = { x = 1111, y = 1231, z = 7}, -- Posição onde será teleportado
      	tempo = 10, -- tempo para voltar 
      	exaust = 34455 -- Exaust para usar novalmente, adicionado esta linha.
      }
      
      function onUse(cid, item, fromPosition, itemEx, toPosition)
      
      	if ( isPlayer( getCreatureTarget(cid) ) and getPlayerStorageValue(cid, kamui.exaust) < os.time() ) then  -- Modificado esta linha
      	  target = getCreatureTarget(cid)
      	  addEvent(doTeleportThing, 1000*kamui.tempo, target, getThingPos(target), true)
      	  addEvent(doSendMagicEffect, 1000*kamui.tempo, getThingPos(target), 10)
      	  doSendMagicEffect(getThingPos(target), 50)
      	  doTeleportThing(target, kamui.posTeleport)
      	  setPlayerStorageValue(cid, kamui.exaust, 2 + os.time()) -- Adicionado esta linha
      	  
      		if isCreature(cid) then
      		 doPlayerSendTextMessage(target, 27, "Você foi teleportado pelo kamui do jogador: ".. getCreatureName(cid) ..".")
      		end
      		if isPlayer(cid) and isCreature(target) then
      		 doPlayerSendTextMessage(cid, 27, "Você teletransportou: ".. getCreatureName(target) .."!")
      		end
      		
      		for i = 1,config.tempo  do
      		addEvent( 
      					function()
      						if isCreature(target) then
      						 doPlayerSendTextMessage(target,25,"Voce estara de volta" .. kamui.tempo -i +1 .. " segundos(s)")
      						end
      					end, 1000*i
      				)
      		end
      	else
      		doPlayerSendCancel(cid, "Voce so pode usar esse feitico nos jogadores")
      	end
        return true
      end

      Comentei a linha que adicionei, acho melhor vc remover o item do player ficando "100 - Kamui, usou remove: 99 - Kamui" e assim vai indo, igual potion quando vai usando ele vai acabando.

    4. mrlhsl

      mrlhsl

      =) Muito obrigado novamente kk 

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...