I have an error with my function: doPlayerAddWisdomSkill(cid, add)
What's wrong?
Lib:
Talkaction:
Please help-me
Bump.
What's wrong?
Lib:
Code:
SKILL_WISDOM = 5000
function doPlayerAddWisdomSkill(cid, add)
local skill = getPlayerStorageValue(cid, SKILL_WISDOM)
setPlayerStorageValue(cid, SKILL_WISDOM, skill+add)
return TRUE
end
Talkaction:
Code:
function onSay(cid, words, param, channel)
if(param == '') then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Command param required.")
return true
end
local pid = getPlayerByNameWildcard(param)
if isPlayer(pid) == TRUE then
doPlayerAddWisdomSkill(pid, 1)
doPlayerSendTextMessage(cid, MESSAGE_EVENT_ADVANCE, "You gave one skill points to "..param..".")
doPlayerSendTextMessage(pid, MESSAGE_EVENT_ADVANCE, "You advanced to wisdom level "..getPlayerWisdomSkill(pid)..".")
end
return TRUE
end
Please help-me
Bump.
Last edited by a moderator: