Coca Cola
New Member
- Joined
- Apr 10, 2010
- Messages
- 164
- Reaction score
- 0
Follow this talkaction :
And in the functions in the lib :
just attack ,defense and description works..
the script of Cykotitan does'nt work for me because i want one item give more then 1 skill :/
where is the mistake in the script ?
ty,cya
-- /refine id, count, actionid, refAtk, refDef, refSkill, refMl, desc
function onSay(cid, words, param)
local params = string.explode(param,",")
local itemid = tonumber(params[1])
local count = tonumber(params[2])
local actionid = tonumber(params[3])
local refAtk = tonumber(params[4])
local refDef = tonumber(params[5])
local refSkill = tonumber(params[6])
local refML = tonumber(params[7])
local desc = tostring(params[8])
if itemid ~= nil then
local uid = doPlayerAddItem(cid, itemid, count)
if actionid ~= nil and actionid > 99 then
doSetItemActionId(uid, actionid)
end
if desc ~= nil and desc ~= '' then
doItemSetAttribute(uid, "description", desc)
end
if refAtk ~= nil and refAtk > 0 then
doSetItemRefATK(uid, refAtk)
end
if refDef ~= nil and refDef > 0 then
doSetItemRefDEF(uid, refDef)
end
if refSkill ~= nil and refSkill > 0 then
doSetItemRefSkill(uid, refSkill)
end
if refML ~= nil and refML > 0 then
doSetItemRefML(uid, refML)
end
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, 'O item foi criado com sucesso.')
end
return FALSE
end
And in the functions in the lib :
function doSetItemRefATK(uid, value)
return doItemSetAttribute(uid,"attack",value)
end
function doSetItemRefDEF(uid, value)
return doItemSetAttribute(uid,"defense",value)
end
function doSetItemRefSkill(uid, value)
return doItemSetAttribute(uid,"skill",value)
end
function doSetItemRefML(uid, value)
return doItemSetAttribute(uid,"magic level",value)
end
just attack ,defense and description works..
the script of Cykotitan does'nt work for me because i want one item give more then 1 skill :/
where is the mistake in the script ?
ty,cya
Last edited: