JDB
OtLand Veteran
- Joined
- Jun 1, 2009
- Messages
- 4,145
- Solutions
- 2
- Reaction score
- 115
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local cfg = {}
cfg.outfit = { lookType = 35, lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0 }
cfg.storage = 10101
cfg.time = 5 -- Minutes
if(exhaustion.get(cid, cfg.storage) == true) then
doPlayerSendCancel(cid, "You can only use this once every " .. cfg.time .. " minutes.")
return true
end
if(getPlayerSex(cid) == PLAYERSEX_FEMALE) then
doSendAnimatedText(getCreaturePosition(cid), 'GiRl', TEXTCOLOR_GOLD)
elseif(getPlayerSex(cid) == PLAYERSEX_MALE) then
doSendAnimatedText(getCreaturePosition(cid), 'MaLe', TEXTCOLOR_GOLD)
end
doSetCreatureOutfit(cid, cfg.outfit, cfg.time * 60 * 1000)
exhaustion.set(cid, cfg.storage, cfg.time * 60 * 1000)
return true
end
Last edited: