This Is War
Member
- Joined
- Aug 22, 2013
- Messages
- 123
- Reaction score
- 11
Hello and im here to re-host another useful script! a item that Promotes you to another vocation, If you are good at changing scripts this script can be used as a VIP Promotion or any other type of promotion.
This script has not been tested!
Data/Actions/Actions.xml
Lua:
<action itemid="5952" script="promotion.lua"/>
Data/Actions/Scripts/Promotion.lua
Code:
local mageffect = 55 -- choose an effect to use (you can change this look in lib for magic effects)
local level = 1 -- level needed to use the script.
function onUse(cid, item, fromPosition, itemEX, toPosition)
local voc = getPlayerVocation(cid)
local vocname = getPlayerVocationName(cid)
if(getPlayerVocation(cid) >= 1 and getPlayerVocation(cid) <= 4 and getPlayerLevel(cid) >= level) then
setPlayerPromotionLevel(cid, 1)
local vocnamenew = getPlayerVocationName(cid)
doSendAnimatedText(getPlayerPosition(cid), "Transform!", TEXTCOLOR_RED)
doPlayerSendTextMessage(cid,19, "You have been promoted from "..vocname.." to "..vocnamenew.."!")
doRemoveItem(item.uid,1)
else
doPlayerSendCancel(cid, "Your vocation may not use this scroll.")
end
return TRUE
end
Last edited: