Ir para conteúdo

Featured Replies

Postado
  • Autor

Exatamente. Eu tentei isso só que eu não consegui. Você poderia fazer a do addon citizen e do hunter para eu ter uma noção de como fazer as outras? Obrigado ai.

olha oq eu fiz.   o hunter está funcionando só que usando o item que era pra ser do citizen  e o citizen está dando item não encontrado!!!

 

 

 

 

 <talkaction words="!addon" script="Addoncitizen.lua"/>
    <talkaction words="!addon" script="Addonhunter.lua"/>

 

 

 

 

 

 

female = { ["hunter"]={137} }

male = { ["hunter"]={129} }

msg = {"Addon nao encontrado!", "Voce n&#227;o tem o Addon Doll!", "Falta parametros!", "Voc&#234; recebeu seu addon!"} -- Mensagems

itemID = 11138 -- ITEM

function onSay(cid, words, param)if (not isPremium(cid)) then

doPlayerSendCancel(cid, "Desculpe, apenas jogadores premium account podem comprar addons!.")

return TRUE

end

if(getPlayerItemCount(cid, 11138) > 0) then

if(param ~= "" and male[param] and female[param]) then

doPlayerRemoveItem(cid, 11138, 1)

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[4])

doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)

if(getPlayerSex(cid) == 0)then

doPlayerAddOutfit(cid, female[param][1], 3)

else

doPlayerAddOutfit(cid, male[param][1], 3)

end

else

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[1])

end

else

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[2])

end

end

 

 

 

female = { ["citizen"]={136} }

male = { ["citizen"]={128} }

msg = {"Addon nao encontrado!", "Voce n&#227;o tem o Addon Doll!", "Falta parametros!", "Voc&#234; recebeu seu addon!"} -- Mensagems

itemID = 2112 -- ITEM

function onSay(cid, words, param)if (not isPremium(cid)) then

doPlayerSendCancel(cid, "Desculpe, apenas jogadores premium account podem comprar addons!.")

return TRUE

end

if(getPlayerItemCount(cid, 2112) > 0) then

if(param ~= "" and male[param] and female[param]) then

doPlayerRemoveItem(cid, 2112, 1)

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[4])

doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)

if(getPlayerSex(cid) == 0)then

doPlayerAddOutfit(cid, female[param][1], 3)

else

doPlayerAddOutfit(cid, male[param][1], 3)

end

else

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[1])

end

else

doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, msg[2])

end

end

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

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

  • Respostas 13
  • Visualizações 1.8k
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • posta ai o teu script, deve ter configurado errado!!   eu arrumo ----------------------- edited ---------------------------     vou editar aqui e ja te mando, vc colocou

  • Teria que fazer pra cada item uma talkaction diferente...

  • female = { ["citizen"]={136}, ["hunter"]={137}, ["mage"]={138}, ["knight"]={139}, ["nobleman"]={140}, ["summoner"]={141}, ["warrior"]={142}, ["barbarian"]={147}, ["druid"]={148}, ["wizard"]={149}, ["o

Postado

vai terminando a lista dos addons

 

local addons = {
["citizen"] = {id = 2520, sex = {[0] = 136,[1] = 128}},
["hunter"] = {id = 2173, sex = {[0] = 137,[1] = 129}},
["mage"] = {id = 2493, sex = {[0] = 138,[1] = 130}}
}
function onSay(cid, words, param)
local param = param:lower()
if param == "" or not addons[param] then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Not A Good Param.") return true
end
local var =  addons[param]
if not doPlayerRemoveItem(cid, var.id, 1) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You need a "..getItemNameById(var.id)..".") return true
end
doPlayerAddOutfit(cid, var.sex[getPlayerSex(cid)], 3)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Full Addon "..param.." Set sucesfully added!")
return true
end

 

vodkart_logo.png

[*Ninguém será digno do sucesso se não usar suas derrotas para conquistá-lo.*]

 

DISCORDvodkart#6090

 

Postado
  • Autor
  Em 11/01/2017 em 18:00, Vodkart disse:

vai terminando a lista dos addons

 


local addons = {
["citizen"] = {id = 2520, sex = {[0] = 136,[1] = 128}},
["hunter"] = {id = 2173, sex = {[0] = 137,[1] = 129}},
["mage"] = {id = 2493, sex = {[0] = 138,[1] = 130}}
}
function onSay(cid, words, param)
local param = param:lower()
if param == "" or not addons[param] then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Not A Good Param.") return true
end
local var =  addons[param]
if not doPlayerRemoveItem(cid, var.id, 1) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You need a "..getItemNameById(var.id)..".") return true
end
doPlayerAddOutfit(cid, var.sex[getPlayerSex(cid)], 3)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Full Addon "..param.." Set sucesfully added!")
return true
end

Obrigado, deu certo!!

 

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

Postado
  • Autor

eu editei só que nem todos addons estão funcionando. oque tem de errado?

 

 

 

local addons = {
["citizen"] = {id = 2110, sex = {[0] = 136,[1] = 128}},
["hunter"] = {id = 10529, sex = {[0] = 137,[1] = 129}},
["mage"] = {id = 5903, sex = {[0] = 138,[1] = 130}},
["knight"]= {id = 11205, sex = {[0] = 139,[1] = 131}},
["Nobleman"]= {id = 10530, sex = {[0] = 140,[1] = 132}},
["Summoner"]= {id = 2322, sex = {[0] = 141,[1] = 133}},
["Warrior"]= {id = 10542, sex = {[0] = 142,[1] = 134}},
["Barbarian"]= {id = 10543, sex = {[0] = 147,[1] = 143}},
["Druid"]= {id = 11330, sex = {[0] = 148,[1] = 144}},
["Wizard"]= {id = 11250, sex = {[0] = 149,[1] = 145}},
["Oriental"]= {id = 11201, sex = {[0] = 150,[1] = 146}},
["Pirate"]= {id = 5810, sex = {[0] = 155,[1] = 151}},
["Assassin"]= {id = 6579, sex = {[0] = 156,[1] = 152}},
["Beggar"]= {id = 2108, sex = {[0] = 157,[1] = 153}},
["Shaman"]= {id = 6512, sex = {[0] = 138,[1] = 130}},
["Norsewoman"]= {id = 8982, sex = {[0] = 158,[1] = 154}},
["Nightmare"]= {id = 9019, sex = {[0] = 269,[1] = 268}},
["Jester"]= {id = 9693, sex = {[0] = 270,[1] = 273}},
["BrotherHood"]= {id = 11249, sex = {[0] = 279,[1] = 278}},
["DemonHunter"]= {id = 11138, sex = {[0] = 288,[1] = 289}},
["Yalaharian"]= {id = 2194, sex = {[0] = 324,[1] = 325}}
}
function onSay(cid, words, param)
local param = param:lower()
if param == "" or not addons[param] then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Not A Good Param.") return true
end
local var =  addons[param]
if not doPlayerRemoveItem(cid, var.id, 1) then
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You need a "..getItemNameById(var.id)..".") return true
end
doPlayerAddOutfit(cid, var.sex[getPlayerSex(cid)], 3)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Full Addon "..param.." Set sucesfully added!")
return true
end

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

Informação Importante

Confirmação de Termo