• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

Summon Tiles for quests

Ninkobi

Owner /Founder of Syphera
Joined
Apr 5, 2008
Messages
206
Reaction score
1
Location
England
Well I made a quest which has tiles that which will summon monsters where you want, it has a storage value so if you want to go back or die you can go and try again.

The script:
Code:
function onStepIn(cid, item, pos)
    if item.actionid == 13677 then
        if getPlayerStorageValue(cid,132567) == -1 then
            setPlayerStorageValue(cid,132567,1)
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'GUARDS! Kill him!')
monster1pos = {x=20031, y=20410, z=9} --Juggetnaut
monster2pos = {x=20031, y=20407, z=9} --Juggernaut
monster3pos = {x=20032, y=20408, z=9} --hand
monster4pos = {x=20032, y=20409, z=9} --nightmare
monster5pos = {x=20037, y=20407, z=9} --demon
monster6pos = {x=20037, y=20410, z=9} --demon
monster7pos = {x=20039, y=20409, z=9} --hand
doSummonCreature("Juggernaut", monster1pos)
doSummonCreature("Juggernaut", monster2pos)
doSummonCreature("Hand of Cursed Fate", monster3pos)
doSummonCreature("Nightmare", monster4pos)
doSummonCreature("Demon", monster5pos)
doSummonCreature("Demon", monster6pos)
doSummonCreature("Hand of Cursed Fate", monster7pos)
else
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'You have already killed the first guards!')
end

Just change the pos and monster name to add a new monster jus add and change the number in pink to a number not used:
Code:
monster[COLOR="Magenta"]7[/COLOR]pos = {x=20039, y=20409, z=9} --hand
doSummonCreature("Juggernaut", monster[COLOR="Magenta"]1[/COLOR]pos)
 
This is a nice script but not usefull. everyone have to edit it because of the 'spawn places' maybe they spawn on the middle of the town or just somewhere on water.

If you're going to use this script you must edit the positions and you have got an awesome script!
 
This script doesn't work anyway, it's missing 2 ends.
Code:
    local monster1pos = {x=20031, y=20410, z=9} --Juggetnaut
    local monster2pos = {x=20031, y=20407, z=9} --Juggernaut
    local monster3pos = {x=20032, y=20408, z=9} --hand
    local monster4pos = {x=20032, y=20409, z=9} --nightmare
    local monster5pos = {x=20037, y=20407, z=9} --demon
    local monster6pos = {x=20037, y=20410, z=9} --demon
    local monster7pos = {x=20039, y=20409, z=9} --hand

function onStepIn(cid, item, pos)
    if item.actionid == 13677 then
        if getPlayerStorageValue(cid,132567) == -1 then
            setPlayerStorageValue(cid,132567,1)
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'GUARDS! Kill him!')
            doSummonCreature("Juggernaut", monster1pos)
            doSummonCreature("Juggernaut", monster2pos)
            doSummonCreature("Hand of Cursed Fate", monster3pos)
            doSummonCreature("Nightmare", monster4pos)
            doSummonCreature("Demon", monster5pos)
            doSummonCreature("Demon", monster6pos)
            doSummonCreature("Hand of Cursed Fate", monster7pos)
        else
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'You have already killed the first guards!')
        end
    end
end

This one should work tho. ;)
 
This script doesn't work anyway, it's missing 2 ends.
Code:
    local monster1pos = {x=20031, y=20410, z=9} --Juggetnaut
    local monster2pos = {x=20031, y=20407, z=9} --Juggernaut
    local monster3pos = {x=20032, y=20408, z=9} --hand
    local monster4pos = {x=20032, y=20409, z=9} --nightmare
    local monster5pos = {x=20037, y=20407, z=9} --demon
    local monster6pos = {x=20037, y=20410, z=9} --demon
    local monster7pos = {x=20039, y=20409, z=9} --hand

function onStepIn(cid, item, pos)
    if item.actionid == 13677 then
        if getPlayerStorageValue(cid,132567) == -1 then
            setPlayerStorageValue(cid,132567,1)
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'GUARDS! Kill him!')
            doSummonCreature("Juggernaut", monster1pos)
            doSummonCreature("Juggernaut", monster2pos)
            doSummonCreature("Hand of Cursed Fate", monster3pos)
            doSummonCreature("Nightmare", monster4pos)
            doSummonCreature("Demon", monster5pos)
            doSummonCreature("Demon", monster6pos)
            doSummonCreature("Hand of Cursed Fate", monster7pos)
        else
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'You have already killed the first guards!')
        end
    end
end

This one should work tho. ;)

Thanks for fixing, kinda forgot about the ends :thumbup:

This is a nice script but not usefull. everyone have to edit it because of the 'spawn places' maybe they spawn on the middle of the town or just somewhere on water.

If you're going to use this script you must edit the positions and you have got an awesome script!
You can't expect me to know the co ordinates on peoples maps XD
 
Added player check + more configurable (monster list ; o)
functions.lua: (function which summon creatures from a list
Code:
function doSummonCreaturesFromList(list)
	for name, pos in pairs(list) do
		doSummonCreature(name, pos)
	end
end

And your movement:
Code:
local monstersToSummon =
{
	["Juggernaut"] =		{x=137, y=59, z=7},
	["Hand of Cursed Fate"] =	{x=139, y=59, z=7},
	["Demon"] =			{x=139, y=59, z=7}
}


function onStepIn(cid, item, pos)
	if isPlayer(cid) == TRUE then
		if getPlayerStorageValue(cid, item.actionid) == -1 then
			setPlayerStorageValue(cid, item.actionid,1)
			doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'GUARDS! Kill him!')
			doSummonCreaturesFromList(monstersToSummon)
		else
			doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'You have already killed the first guards!')
        	end
	end
end

Now, item.actionid = storageValue used for player.
 
Back
Top