God Mythera
Veteran OT User
Hello and i am trying to get help with a script, i need it to give Jersey outfit for male & female and i need it so it is only 1 use only, also i am using TFS 1.0
The script i have:
The script i have:
Code:
local config = {
looktype_male = 620, -- looktype of the outfit for male.
looktype_female = 619, -- looktype of the outfit for female
addons = 0, -- how many addons you get.
storage = 5012 -- storage value used.
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if getPlayerStorageValue(cid,config.storage) < 1 then
if getPlayerSex(cid) == 0 then
doPlayerAddOutfit(cid,config.looktype_female,config.addons)
doPlayerSendTextMessage(cid,20,'You got an outfit.')
doSendMagicEffect(getThingPos(cid),12)
elseif getPlayerSex(cid) == 1 then
doPlayerAddOutfit(cid,config.looktype_male,config.addons)
doPlayerSendTextMessage(cid,20,'You got an outfit.')
doSendMagicEffect(getThingPos(cid),12)
end
else
doPlayerSendTextMessage(cid,20,'You already have this outfit.')
doSendMagicEffect(getThingPos(cid),2)
end
return true
end