Ir para conteúdo

Finalizar Script De Addon


Posts Recomendados

Pessoal,

 

eu dei uma editada em um script da inquisition, coloquei para ela dar como prêmio um addon. Só que preciso diferenciar o addon feminino

do masculino. Pq ele ta passando apenas o masculino.

 

Se alguem puder me ajudar.

 

O codigo que eu editei ficou assim.

 

function onUse(cid, item, frompos, item2, topos)

      if item.uid == 8560 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Emerald Sword.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8930,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3) 
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8561 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Spellbook of dark Mysteries.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8918,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8562 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Master Archer's Armor.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8888,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8563 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Robe of the Underworld")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8890,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8564 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Fireborn Giant Armor.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8881,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8565 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Obsidian Truncheon.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8928,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8566 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Royal Crossbow.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8851,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8567 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Warsinger Bow.")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8854,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end
      elseif item.uid == 8568 then
          queststatus = getPlayerStorageValue(cid,8560)
          if queststatus == -1 then
              doPlayerSendTextMessage(cid,22,"You have found a Hellforged axe")
              doPlayerSendTextMessage(cid,22,"Congratulations you won a Warmaster Addon")
              doPlayerAddItem(cid,8924,1)
              doPlayerAddOutfit(cid,336,3) 
              doPlayerAddOutfit(cid,335,3)
              setPlayerStorageValue(cid,8560,1)
          else
              doPlayerSendTextMessage(cid,22,"It is empty.")
          end

   else
       return 0
      end

      return 1
end

Link para o comentário
Compartilhar em outros sites

Opa, tudo bom?

Sou novo em script, mas pelo que sei tenta isso:

Ali onde você bota

 

doPlayerAddOutfit(cid,336,3) 
doPlayerAddOutfit(cid,335,3)

 

Tenta add isso:

 

 
elseif getPlayerSex(cid) == 0 then
doPlayerAddOutfit(cid,336,3)
elseif getPlayerSex(cid) == 1 then
doPlayerAddOutfit(cid,335,3)
end

 

Valeu, se der certo posta ai, e se puder da +REP to precisando UASHDUASHD

Editado por XJhoow
Link para o comentário
Compartilhar em outros sites

Velho.

 

Vc acredita que já estava dando os addon do jeito que eu fiz aí?

 

Não precisava editar nada.

 

acho que o 335 e o 336 são os addons 1 e 2.

 

Mas mesmo assim obrigado. vou te dar um REP+.

 

 

 

 

Podem fechar o topic pls.

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...