Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local config = {
- --[vocation id] = { level, nova voc, looktype, efeito}
- [9] = { 25, 10, 66, 53}, --9 é a vocação que pede, 25 é o level que pede, 10 é a nova vocação, 66 é o looktype que vai setar, 53 é o efeito que vai sair.
- [10] = { 50, 11, 91, 53},
- [11] = { 75, 12, 18, 53},
- [12] = { 100, 13, 31, 53},
- [13] = { 125, 14, 92, 53},
- [14] = { 150, 15, 77, 53},
- [15] = { 175, 16, 49, 66},
- [16] = { 200, 17, 25, 54},
- [17] = { 250, 18, 179, 66}
- }
- function onSay(cid, words, param, channel)
- doPlayerSay(cid, "transformar")
- local voc = config[getPlayerVocation(cid)]
- if voc then
- if getPlayerLevel(cid) >= voc[1] then
- doPlayerSetVocation(cid, voc[2])
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Você se Transformou!")
- local outfit = {lookType = voc[3]}
- doCreatureChangeOutfit(cid, outfit)
- doSendMagicEffect(getCreaturePosition(cid), voc[4])
- else
- doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "You need Level " .. voc[1] .. " to Transform.")
- end
- else
- doPlayerSendCancel(cid, "You can not Transform!")
- end
- return true
- end
Advertisement
Add Comment
Please, Sign In to add comment