function onUse(cid, item, frompos, item2, topos)
local price = 900000
local outfit_male = {lookType=309,lookHead=0,lookAddons=0,lookLegs=0,lookBody=0,lookFeet=0}
local outfit_female = {lookType=310,lookHead=0,lookAddons=0,lookLegs=0,lokBody=0,lookFeet=0}
local time = 1 -- em minutos
local storage = getPlayerStorageValue(cid,52525) -- n mexa
local male = 309
local female = 310 -- ?
local addon = 1
if storage == -1 then
if(doPlayerRemoveMoney(cid,price) == TRUE) then
if(getPlayerSex(cid) == 1) then
doPlayerAddOutfit(cid, male, addon)
doSetCreatureOutfit(cid, outfit_male, time*60*1000)
doPlayerSetStorageValue(cid,52525,1)
doPlayerSendTextMessage (cid, 22, 'Traje especial comprado! Você perdeu 90 crystal coins')
elseif(getPlayerSex(cid) == 0) then
doPlayerAddOutfit(cid, female, addon)
doSetCreatureOutfit(cid, outfit_female, time*60*1000)
doPlayerSetStorageValue(cid,52525,1)
doPlayerSendTextMessage (cid, 22, 'Traje especial comprado! Você perdeu 90 crystal coins')
end
else
doPlayerSendTextMessage (cid, 22, 'Você não tem dinheiro suficiente para comprar o traje, 90 crystal coins')
end
else
doPlayerSendTextMessage (cid, 22, 'Você já possui essa outfit')
end
return TRUE
end