<?xml version="1.0" encoding="UTF-8"?>
<mod name="Custom Runes" author="C" contact="otland.net" enabled="yes">
<config name="rune_config">
<![CDATA[
storage = 13356
restore = function(cid)
return isPlayer(cid) and doCreatureSetStorage(cid, storage, 0), doCreatureSetNoMove(cid, false)
end
]]>
</config>
<event type="cast" name="cast" event="buffer">
<![CDATA[
domodlib('rune_config')
if getCreatureStorage(cid, storage) > 0 then
return false, doPlayerSendCancel(cid, 'You are paralyzed.')
end
]]>
</event>
<event type="login" name="registering" event="buffer">
<![CDATA[
domodlib('rune_config')
registerCreatureEvent(cid, "cast")
doCreatureSetStorage(cid, storage, 0)
]]>
</event>
<action default="yes" event="script">
<![CDATA[
domodlib('rune_config')
function onUse(cid, item, fromPosition, itemEx, toPosition)
if getCreatureStorage(cid, storage) > 0 then
return doPlayerSendCancel(cid, 'You are paralyzed.')
end
local item = getItemInfo(item.itemid)
if(item.weaponType == WEAPON_SWORD or item.weaponType == WEAPON_CLUB or item.weaponType == WEAPON_AXE) then
return destroyItem(cid, itemEx, toPosition)
end
return false
end
]]>
</action>
<rune name="Freezer Rune" id="2312" allowfaruse="1" charges="3" lvl="14" maglv="4" exhaustion="2000" needtarget="1" blocktype="solid" event="script">
<text>
<![CDATA[
local condition = createConditionObject(CONDITION_FREEZING, 10000)
setConditionParam(condition, CONDITION_PARAM_DELAYED, 1)
addDamageCondition(condition, 5, 2000, -10)
domodlib('rune_setup')
function onCastSpell(cid, var)
if not isPlayer(getCreatureTarget(cid)) then
return false, doPlayerSendCancel(cid, 'Your target is not a player.')
end
if getCreatureStorage(getCreatureTarget(cid), storage) > 0 then
return false, doPlayerSendCancel(cid, 'Your target is already paralyzed.')
end
addEvent(restore, 10000, cid)
doAddCondition(cid, condition)
doCreatureSetStorage(getCreatureTarget(cid), storage, 1)
doSendMagicEffect(getThingPos(target), CONST_ME_MAGIC_RED)
doPlayerSendCancel(cid,'You\'ve been paralyzed and are unable to use actions or spells.')
return true
end
]]>
</text>
</rune>
<rune name="Ultra Paralize" id="2294" allowfaruse="1" charges="3" lvl="14" maglv="4" exhaustion="2000" needtarget="1" blocktype="solid" event="script">
<text>
<![CDATA[
local condition = createConditionObject(CONDITION_PARALYZE, 10000)
setConditionParam(condition, CONDITION_PARAM_SPEED, -999)
domodlib('rune_setup')
function onCastSpell(cid, var)
if not isPlayer(getCreatureTarget(cid)) then
return false, doPlayerSendCancel(cid, 'Your target is not a player.')
end
if getCreatureStorage(getCreatureTarget(cid), storage) > 0 then
return false, doPlayerSendCancel(cid, 'Your target is already paralyzed.')
end
addEvent(restore, 10000, cid)
doCreatureSetNoMove(cid, true)
doAddCondition(cid, condition)
doCreatureSetStorage(getCreatureTarget(cid), storage, 1)
doSendMagicEffect(getThingPos(target), CONST_ME_MAGIC_RED)
doPlayerSendCancel(cid,'You\'ve been paralyzed and are unable to use actions or spells.')
return true
end
]]>
</text> </rune>
<conjure name="Freezer Rune" words="exevo freeze" lvl="14" mana="200" soul="1" reagentId="2260" conjureId="2312" conjureCount="3" exhaustion="1000" needlearn="0" event="function" value="conjureRune">
<vocation id="2"/>
<vocation id="6"/>
</conjure>
<conjure name="Ultra Paralize" words="exevo paralyze" lvl="14" mana="200" soul="1" reagentId="2260" conjureId="2294" conjureCount="3" exhaustion="1000" needlearn="0" event="function" value="conjureRune">
<vocation id="2"/>
<vocation id="6"/>
</conjure>
<item id="2312" article="a" name="Freezer Rune" override="yes">
<attribute key="runeSpellName" value="exevo freeze" />
<attribute key="type" value="rune" />
<attribute key="weight" value="25" />
</item>
<item id="2294" article="a" name="Ultra Paralize" override="yes">
<attribute key="runeSpellName" value="exevo paralyze" />
<attribute key="type" value="rune" />
<attribute key="weight" value="20" />
</item>
</mod>