Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local femaleOutfits = {["citizen"]={136}, ["hunter"]={137}, ["mage"]={138}, ["knight"]={139}, ["noblewoman"]={140}, ["summoner"]={141}, ["warrior"]={142}, ["barbarian"]={147}, ["druid"]={148}, ["wizard"]={149}, ["oriental"]={150}, ["pirate"]={155}, ["assassin"]={156}, ["beggar"]={157}, ["shaman"]={158}, ["norsewoman"]={252}, ["nightmare"]={269}, ["jester"]={270}, ["brotherhood"]={279}, ["demonhunter"]={288}, ["yalaharian"]={324}, ["warmaster"]={336}}
- local maleOutfits = {["citizen"]={128}, ["hunter"]={129}, ["mage"]={130}, ["knight"]={131}, ["nobleman"]={132},["summoner"]={133}, ["warrior"]={134}, ["barbarian"]={143}, ["druid"]={144}, ["wizard"]={145}, ["oriental"]={146}, ["pirate"]={151}, ["assassin"]={152}, ["beggar"]={153}, ["shaman"]={154}, ["norsewoman"]={251}, ["nightmare"]={268}, ["jester"]={273}, ["brotherhood"]={278}, ["demonhunter"]={289}, ["yalaharian"]={325}, ["warmaster"]={335}, ["wayfarer"]={366}}
- local addonDoll = 9693
- local addonParam = {
- ["first"] = 1,
- ["second"] = 2,
- }
- function onSay(cid, words, param)
- local paramtwo = string.explode(param, ",")
- local sex = nil
- if getPlayerSex(cid) > 0 then
- sex = femaleOutfits
- else
- sex = maleOutfit
- end
- if not sex[paramtwo[1]:lower()] then
- doPlayerSendCancel(cid, "Esta outfit não existe.")
- return true
- end
- if not isInArray({"first", "second"}, paramtwo[2]) then
- doPlayerSendCancel(cid, "Voce não está executando um parametro válido.")
- return true
- end
- if(doPlayerRemoveItem(cid, addonDoll, 1) == true) then
- doPlayerAddOutfit(cid, sex[paramtwo[1]:lower], addonParam[paramtwo[2]:lower)
- doPlayerSendCancel(cid, "Voce adicionou um novo addon.")
- doSendMagicEffect(getCreaturePosition(cid), CONST_ME_GIFT_WRAPS)
- return true
- else
- doPlayerSendCancel(cid, "Voce não tem um addon doll.")
- doSendMagicEffect(getThingPos(cid), 2)
- return true
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement