function onUse(cid, item, fromPosition, itemEx, toPosition)
local pos1 = {x=1000, y=1000, z=6} ---------- For Demons--------
local pos2 = {x=1000, y=998, z=6} ----------- for Undead Dragon-----------
local pos3 = {x=1000, y=999, z=6} ------------for Dragon Lord ------------
if item.itemid == 1945 then
doTransformItem(item.uid, item.itemid + 1)
doCreateMonster("demon", pos1)
doCreateMonster("undead dragon", pos2)
doCreateMonster("dragon lord", pos3)
doPlayerSendTextMessage(cid, 21, "you Have Summoned Monsters")
else
if item.itemid == 1946 then
doTransformItem(item.uid, item.itemid - 1)
doCreateMonster("demon", pos1)
doCreateMonster("undead dragon", pos2)
doCreateMonster("dragon lord", pos3)
doPlayerSendTextMessage(cid, 21, "you Have Summoned Monsters")
end
end
end
<action actionid="1212" script="lever1.lua"/>
function onUse(cid, item, fromPosition, itemEx, toPosition)
local pos1 = {x=1000, y=1000, z=6}
local pos2 = {x=1000, y=998, z=6}
local pos3 = {x=1000, y=999, z=6}
if (item.itemid == 1945) then
doCreateMonster("demon", pos1)
doCreateMonster("undead dragon", pos2)
doCreateMonster("dragon lord", pos3)
doPlayerSendTextMessage(cid, 21, "you Have Summoned Monsters")
doTransformItem(item.uid, item.itemid + 1)
elseif item.itemid == 1946 then
doTransformItem(item.uid, item.itemid-1)
doCreateMonster("demon", pos1)
doCreateMonster("undead dragon", pos2)
doCreateMonster("dragon lord", pos3)
doPlayerSendTextMessage(cid, 21, "you Have Summoned Monsters")
end
return TRUE
end