Blood BlvD Ot
Member
- Joined
- Jun 12, 2010
- Messages
- 243
- Reaction score
- 7
Well on my ot, I have a vocation called the Elementalist. And I wanted him to morph into an element and get a magic level buff.
After learning that there is so many different complicated versions of this script. I decided to release this easy one for the noober scripters out there like me
On here you can play around with different :
Lighting colors and brightness
Outfits. With change of colors or plain monster.
Add different buffs with ease.
Well
, this is my first post. Hope the script works awsome for u.
After learning that there is so many different complicated versions of this script. I decided to release this easy one for the noober scripters out there like me

create@ actions/scripts/buffitem.lua
Code:
-- Blood BlvD Ot
-- Simple Productions
-- By Daniel Couillard.
-- [email protected]
local condition = createConditionObject(CONDITION_ATTRIBUTES) -- >>> LOCALS <<<
setConditionParam(condition, CONDITION_PARAM_TICKS, 50000) -- The Lenght of this entire proccess.
setConditionParam(condition, CONDITION_PARAM_STAT_MAGICLEVELPERCENT, 350) -- -
-- | \/ Should Be The Same /\
local conditionRed = createConditionObject(CONDITION_OUTFIT) -- -
setConditionParam(conditionRed, CONDITION_PARAM_TICKS, 50000) -- The Lenght of this entire proccess.
addOutfitCondition(conditionRed, {lookType = 286, lookHead = 94, lookBody = 94, lookLegs = 94, lookFeet = 94}) -- The Outfit that you want to change into.
local condition2 = createConditionObject(CONDITION_LIGHT) -- If you want, you can add a lighting effect.
setConditionParam(condition2, CONDITION_PARAM_LIGHT_LEVEL, 10) -- The Strenght of the light. Goes Down Over Time.
setConditionParam(condition2, CONDITION_PARAM_LIGHT_COLOR, 144) -- The Color, This one is darkRed.
setConditionParam(condition2, CONDITION_PARAM_TICKS, 75000) -- Try and balance this one out with the others.. Balanced with the other times,
function onUse(cid, item, frompos, item2, topos)
if(isInArray({18,22,26,30}, getPlayerVocation(cid)) == TRUE) then -- The Vocations of wich u want to be able to use this.
var = numberToVariant(cid)
doTargetCombatCondition(0, cid, condition, CONST_ME_MAGIC_RED) -- The Magic Effect that happens on use.
doAddCondition(cid, conditionRed) -- |
doAddCondition(cid, condition2) -- |>>> ADDING THE LOCALS <<<
doAddCondition(cid, condition) -- |
doSendAnimatedText(getPlayerPosition(cid),"ROAARRR", math.random(01,255)) -- The text that you want to pop up :D
doRemoveItem(item.uid, 1) -- Keep this here, if u want the item to be removed upon its use.
else
doPlayerSendTextMessage(cid,22,"Hmm.. This stone only seems to glow around the area of an Elementalist.") -- And of course, the failed attempt message.
return 1
end
end
Add Into actions.xml
Code:
<action itemid="#" script="buffitem.lua"/>
On here you can play around with different :
Lighting colors and brightness
Outfits. With change of colors or plain monster.
Add different buffs with ease.
Well
