• 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!

inq bosses question

Calon

Experienced Member
Joined
Feb 6, 2009
Messages
1,070
Reaction score
21
when a boss of inq die the coppers disappear and the tp spawn in xxxx
can i let the coppers appear also tp ?
thanks
reP+
here is inq portal
PHP:
function onDeath(cid, corpse, killer)

registerCreatureEvent(cid, "inquisitionPortals")

local creaturename = getCreatureName(cid)

local ushuriel_in_position = {x=246, y=351, z=12, stackpos=2}
local annihilon_in_position = {x=637, y=472, z=13, stackpos=2}
local hellgorak_in_position = {x=335, y=581, z=10, stackpos=2}
local madareth_in_position = {x=340, y=460, z=13, stackpos=2}
local zugurosh_in_position = {x=390, y=525, z=13, stackpos=2}
local brothers_in_position = {x=505, y=345, z=13, stackpos=1}

local ushuriel_to_position = {x=172, y=559, z=13, stackpos=1}
local annihilon_to_position = {x=294, y=681, z=13, stackpos=1}
local hellgorak_to_position = {x=255, y=467, z=13, stackpos=1}
local madareth_to_position = {x=287, y=365, z=13, stackpos=1}
local zugurosh_to_position = {x=314, y=474, z=13, stackpos=1}
local brothers_to_position = {x=408, y=413, z=13, stackpos=1}

local time_to_pass = 180
local tpID = 5023
local doEffect = CONST_ME_ENERGYHIT
local message = "You now have 3 minutes to exit this room through the teleporter. It will bring you to the next room only during his time or the teleporter will disappear."

if creaturename == 'Ushuriel' then

teleport = doCreateTeleport(tpID, ushuriel_to_position, ushuriel_in_position)

doSendMagicEffect(ushuriel_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInUshurielWard, (1000*time_to_pass))

elseif creaturename == 'Annihilon' then

teleport = doCreateTeleport(tpID, annihilon_to_position, annihilon_in_position)

doSendMagicEffect(annihilon_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInAnnihilonWard, (1000*time_to_pass))

elseif creaturename == 'Madareth' then

teleport = doCreateTeleport(tpID, madareth_to_position, madareth_in_position)

doSendMagicEffect(madareth_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInMadarethWard, (1000*time_to_pass))

elseif creaturename == 'Hellgorak' then

teleport = doCreateTeleport(tpID, hellgorak_to_position, hellgorak_in_position)

doSendMagicEffect(hellgorak_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInHellgorakWard, (1000*time_to_pass))

elseif creaturename == 'Zugurosh' then

teleport = doCreateTeleport(tpID, zugurosh_to_position, zugurosh_in_position)

doSendMagicEffect(zugurosh_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInZuguroshWard, (1000*time_to_pass))

elseif creaturename == 'Latrivan' then

teleport = doCreateTeleport(tpID, brothers_to_position, brothers_in_position)

doSendMagicEffect(brothers_in_position, CONST_ME_ENERGYHIT)

doCreatureSay(cid, message, TALKTYPE_ORANGE_1)

addEvent(removeTeleportInBrothersWard, (1000*time_to_pass))


end
end

function removeTeleportInUshurielWard()
if getThingfromPos({x=246, y=351, z=12, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=246, y=351, z=12, stackpos=1}).uid,1)
doSendMagicEffect({x=246, y=351, z=12, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end

function removeTeleportInAnnihilonWard()
if getThingfromPos({x=637, y=472, z=13, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=637, y=472, z=13, stackpos=1}).uid,1)
doSendMagicEffect({x=637, y=472, z=13, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end

function removeTeleportInHellgorakWard()
if getThingfromPos({x=335, y=581, z=10, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=335, y=581, z=10, stackpos=1}).uid,1)
doSendMagicEffect({x=335, y=581, z=10, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end

function removeTeleportInMadarethWard()
if getThingfromPos({x=340, y=460, z=13, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=340, y=460, z=13, stackpos=1}).uid,1)
doSendMagicEffect({x=340, y=460, z=13, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end

function removeTeleportInZuguroshWard()
if getThingfromPos({x=390, y=525, z=13, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=390, y=525, z=13, stackpos=1}).uid,1)
doSendMagicEffect({x=390, y=525, z=13, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end

function removeTeleportInBrothersWard()
if getThingfromPos({x=505, y=345, z=13, stackpos=1}).itemid == 5023 then
doRemoveItem(getThingfromPos({x=505, y=345, z=13, stackpos=1}).uid,1)
doSendMagicEffect({x=505, y=345, z=13, stackpos=1}, CONST_ME_POFF)
return TRUE
end
end
 
use this one, I USE IT AND Works perfect
Code:
local config = {
        timeToRemove = 60, -- seconds
		message = "Go into the teleport in 60 seconds, else it will disappear.",
        teleportId = 9773,
        bosses = { -- Monster Name,  Teleport Position
                ["Ushuriel"] = {  pos={ x=1400, y=615, z=11, stackpos=2 }, aid=1001 },
				["Zugurosh"] = {  pos={ x=1434, y=614, z=11, stackpos=2 }, aid=1002},
				["Madareth"] = {  pos={ x=1398, y=642, z=11, stackpos=2 }, aid=1003},
                ["Annihilon"] = {  pos={ x=1473, y=599, z=11, stackpos=2 }, aid=1005},
                ["Hellgorak"] = {  pos={ x=1478, y=641, z=11, stackpos=2 }, aid=1006}
				},
		brothers ={
        ["Golgordan"] = {pos={ x=1433, y=645, z=11, stackpos=1 },aid=1004, brother = "Latrivan"},
        ["Latrivan"] = {pos={ x=1433, y=645, z=11, stackpos=1 },aid=1004, brother = "Golgordan"},
        brothersArea ={
                fromPos = {x = 1425, y = 645, z = 11},
                toPos = {x = 1441, y = 655, z = 11}	}	}
}
local function removal(position)
	doRemoveThing(getTileItemById(position, config.teleportId).uid, 1)
    return TRUE
end

function onKill(cid, target, lastHit)
    if(config.bosses[getCreatureName(target)]) then
		local t = config.bosses[getCreatureName(target)]
	    local teleport = doCreateItem(config.teleportId, t.pos)
		local position = t.pos
		doItemSetAttribute(teleport, "aid", t.aid)
        doCreatureSay(cid, config.message, TALKTYPE_ORANGE_1)
		addEvent(removal, config.timeToRemove * 1000, position)
	elseif(config.brothers[getCreatureName(target)]) then
		local t = config.brothers[getCreatureName(target)]
        local brother = getCreatureByName(t.brother)
		if(isMonster(brother) == true) then
            if(isInRange(getCreaturePosition(brother), config.brothers.brothersArea.fromPos, config.brothers.brothersArea.toPos) == true) then
                return TRUE
			end
        else
			local teleport = doCreateItem(config.teleportId, t.pos)
			local position = t.pos
			doItemSetAttribute(teleport, "aid", t.aid)
			doCreatureSay(cid, config.message, TALKTYPE_ORANGE_1)
			addEvent(removal, config.timeToRemove * 1000, position)
		end
	end
	return TRUE
end

EDIT::s it also set a aid in the tp for this moveevent
local config = {
bosses={---aid of portal, position where it sends, value it sets, text it shows
[1001] = {pos={x=1460, y=540, z=11, stackpos=1}, value=1, text="Entering The Crystal Caves"},
[1002] = {pos={x=1414, y=550, z=11, stackpos=1}, value=2, text="Entering The Blood Halls"},
[1003] = {pos={x=1331, y=606, z=12, stackpos=1}, value=3, text="Entering The Vats"},
[1004] = {pos={x=1439, y=595, z=12, stackpos=1}, value=4, text="Entering The Arcanum"},
[1005] = {pos={x=1532, y=697, z=11, stackpos=1}, value=5, text="Entering The Hive"},
[1006] = {pos={x=1350, y=709, z=12, stackpos=1}, value=6, text="Entering The Shadow Nexus"}
},
mainroom={---aid, position, lowest value that can use this portal, text
[2001] = {pos={x=1460, y=540, z=11, stackpos=1}, value=1, text="Entering The Crystal Caves"},
[2002] = {pos={x=1414, y=550, z=11, stackpos=1}, value=2, text="Entering The Blood Halls"},
[2003] = {pos={x=1331, y=606, z=12, stackpos=1}, value=3, text="Entering The Vats"},
[2004] = {pos={x=1439, y=595, z=12, stackpos=1}, value=4, text="Entering The Arcanum"},
[2005] = {pos={x=1532, y=697, z=11, stackpos=1}, value=5, text="Entering The Hive"} },
portals={---aid, position, text
[3000] = {pos={x=1349, y=486, z=13}, text="Entering Inquisition Portals Room"},
[3001] = {pos={x=1384, y=615, z=11}, text="Entering The Ward of Ushuriel"},
[3002] = {pos={x=1472, y=469, z=11}, text="Entering The Undersea Kingdom"},
[3003] = {pos={x=1417, y=614, z=11}, text="Entering The Ward of Zugurosh"},
[3004] = {pos={x=1434, y=528, z=11}, text="Entering The Foundry"},
[3005] = {pos={x=1398, y=654, z=11}, text="Entering The Ward of Madareth"},
[3006] = {pos={x=1329, y=534, z=12}, text="Entering The Battlefield"},
[3007] = {pos={x=1434, y=655, z=11}, text="Entering The Ward of The Demon Twins"},
[3008] = {pos={x=1526, y=539, z=11}, text="Entering The Soul Wells"},
[3009] = {pos={x=1473, y=614, z=13}, text="Entering The Ward of Annihilon"},
[3010] = {pos={x=1478, y=656, z=11}, text="Entering The Ward of Hellgorak"} },
storage=56123,---storage used in boss and mainroom portals
walkback="You don't have enough energy to enter this portal",---message if you cannot use mainroom portal
e={} }----dunno whats this but have to be like this to make doCreatureSayWithDelay working, DON'T TOUCH}
function onStepIn(cid, item, position, fromPosition)
if isPlayer(cid) == TRUE then
if(config.bosses[item.actionid]) then
local t= config.bosses[item.actionid]
if getPlayerStorageValue(cid, config.storage)< t.value then
setPlayerStorageValue(cid, config.storage, t.value)
end
doTeleportThing(cid, t.pos)
doCreatureSayWithDelay(cid,t.text,19,1, config.e)
elseif(config.mainroom[item.actionid]) then
local t= config.mainroom[item.actionid]
if getPlayerStorageValue(cid, config.storage)>=t.value then
doTeleportThing(cid, t.pos)
doCreatureSayWithDelay(cid,t.text,19,1,config.e)
else
doTeleportThing(cid, fromPosition)
doCreatureSay(cid, config.walkback, 19)
end
elseif(config.portals[item.actionid]) then
local t= config.portals[item.actionid]
doTeleportThing(cid, t.pos)
doCreatureSayWithDelay(cid,t.text,19,1,config.e)
end
end
end
if u wan't use both scripts works perfect and its cool whit the moveevent
credits to zakius
 
Last edited:
use this one, I USE IT AND Works perfect
Code:
local config = {
        timeToRemove = 60, -- seconds
		message = "Go into the teleport in 60 seconds, else it will disappear.",
        teleportId = 9773,
        bosses = { -- Monster Name,  Teleport Position
                ["Ushuriel"] = {  pos={ x=1400, y=615, z=11, stackpos=2 }, aid=1001 },
				["Zugurosh"] = {  pos={ x=1434, y=614, z=11, stackpos=2 }, aid=1002},
				["Madareth"] = {  pos={ x=1398, y=642, z=11, stackpos=2 }, aid=1003},
                ["Annihilon"] = {  pos={ x=1473, y=599, z=11, stackpos=2 }, aid=1005},
                ["Hellgorak"] = {  pos={ x=1478, y=641, z=11, stackpos=2 }, aid=1006}
				},
		brothers ={
        ["Golgordan"] = {pos={ x=1433, y=645, z=11, stackpos=1 },aid=1004, brother = "Latrivan"},
        ["Latrivan"] = {pos={ x=1433, y=645, z=11, stackpos=1 },aid=1004, brother = "Golgordan"},
        brothersArea ={
                fromPos = {x = 1425, y = 645, z = 11},
                toPos = {x = 1441, y = 655, z = 11}	}	}
}
local function removal(position)
	doRemoveThing(getTileItemById(position, config.teleportId).uid, 1)
    return TRUE
end

function onKill(cid, target, lastHit)
    if(config.bosses[getCreatureName(target)]) then
		local t = config.bosses[getCreatureName(target)]
	    local teleport = doCreateItem(config.teleportId, t.pos)
		local position = t.pos
		doItemSetAttribute(teleport, "aid", t.aid)
        doCreatureSay(cid, config.message, TALKTYPE_ORANGE_1)
		addEvent(removal, config.timeToRemove * 1000, position)
	elseif(config.brothers[getCreatureName(target)]) then
		local t = config.brothers[getCreatureName(target)]
        local brother = getCreatureByName(t.brother)
		if(isMonster(brother) == true) then
            if(isInRange(getCreaturePosition(brother), config.brothers.brothersArea.fromPos, config.brothers.brothersArea.toPos) == true) then
                return TRUE
			end
        else
			local teleport = doCreateItem(config.teleportId, t.pos)
			local position = t.pos
			doItemSetAttribute(teleport, "aid", t.aid)
			doCreatureSay(cid, config.message, TALKTYPE_ORANGE_1)
			addEvent(removal, config.timeToRemove * 1000, position)
		end
	end
	return TRUE
end

EDIT::s it also set a aid in the tp for this moveevent

if u wan't use both scripts works perfect and its cool whit the moveevent
credits to zakius

please enter your script between
PHP:
 "HERE"
 
All of this was posted by darkhaos

Lua:
local monsters = 
{
	["Ushuriel"] = {teleportPos = {x = 100, y = 100, z = 7, stackpos = 1}, toPos = {x = 100, y = 100, z = 100}},
	["Annihilon"] = {teleportPos = {x = 100, y = 100, z = 7, stackpos = 1}, toPos = {x = 100, y = 100, z = 100}},
	["Hellgorak"] = {teleportPos = {x = 100, y = 100, z = 7, stackpos = 1}, toPos = {x = 100, y = 100, z = 100}},
	["Madareth"] = {teleportPos = {x = 100, y = 100, z = 7, stackpos = 1}, toPos = {x = 100, y = 100, z = 100}},
	["Zugurosh"] = {teleportPos = {x = 100, y = 100, z = 7, stackpos = 1}, toPos = {x = 100, y = 100, z = 100}}
}

local brothers = 
{
	["Golgordan"] = {teleportPos = {x = 100, y = 100, z = 7}, toPos = {x = 100, y = 100, z = 100}, brother = "Latrivan"},
	["Latrivan"] = {teleportPos = {x = 100, y = 100, z = 7}, toPos = {x = 100, y = 100, z = 100}, brother = "Golgordan"},

	brothersArea =
	{
		fromPos = {x = 500, y = 500, z = 7},
		toPos = {x = 550, y = 550, z = 7}
	}
}
local time = 180 --seconds(3 minutes)

function onKill(cid, target, lastHit)

	if(monsters[getCreatureName(target)]) then
		local t = monsters[getCreatureName(target)]
		doCreateTeleport(1387, t.toPos, t.teleportPos)
		doSendMagicEffect(t.teleportPos, CONST_ME_POFF)
		doCreatureSay(cid, "You now have 3 minutes to exit this room through the teleporter. It will bring you to the next room only during his time or the teleporter will disappear", TALKTYPE_MONSTER, getCreaturePosition(target))
		addEvent(doRemoveTeleport, time * 1000, t.teleportPos)
	elseif(brothers[getCreatureName(target)]) then
		t = brothers[getCreatureName(target)]
		local brother = getCreatureByName(t.brother)
		if(isMonster(brother) == true) then
			if(isInRange(getCreaturePosition(brother), brothers.brothersArea.fromPos, brothers.brothersArea.toPos) == true) then
				return true
			else
				doCreateTeleport(1387, t.toPos, t.teleportPos)
				doSendMagicEffect(t.teleportPos, CONST_ME_POFF)
				doCreatureSay(cid, "You now have 3 minutes to exit this room through the teleporter. It will bring you to the next room only during his time or the teleporter will disappear", TALKTYPE_MONSTER, getCreaturePosition(target))
				addEvent(doRemoveTeleport, time * 1000, t.teleportPos)
			end
		end
	end
	return true
end

function doRemoveTeleport(position)
	if(getTileThingByPos(position).itemid > 0) then
		doRemoveItem(getTileThingByPos(position).uid)
		doSendMagicEffect(position, CONST_ME_POFF)
	end
end

data/creaturescripts/scripts/login.lua
Lua:
registerCreatureEvent("Inquisition")

data/creaturescripts/creaturescripts.xml
PHP:
	<event type="kill" name="Inquisition" script="inquisition.lua"/>

monsterfile.xml(Ex: Zugurosh.xml)
After "</flags"> add:
PHP:
	<script>
		<event name="Inquisition"/>
	</script>

Just edit the teleportPos and toPos coordinates.. this should do it :peace:
 
the ones i post works perfect even whit stogare in main room and the msg "entering blah.. room" :3
 
coppers, i tihnk you mean corpse right if so then use this,[it is edit to your script]rep++ :p
Lua:
function onDeath(cid, corpse, killer) 

registerCreatureEvent(cid, "inquisitionPortals") 

local creaturename = getCreatureName(cid) 

local ushuriel_in_position = {x=246, y=351, z=12, stackpos=2} 
local annihilon_in_position = {x=637, y=472, z=13, stackpos=2} 
local hellgorak_in_position = {x=335, y=581, z=10, stackpos=2} 
local madareth_in_position = {x=340, y=460, z=13, stackpos=2} 
local zugurosh_in_position = {x=390, y=525, z=13, stackpos=2} 
local brothers_in_position = {x=505, y=345, z=13, stackpos=1} 

local ushuriel_to_position = {x=172, y=559, z=13, stackpos=1} 
local annihilon_to_position = {x=294, y=681, z=13, stackpos=1} 
local hellgorak_to_position = {x=255, y=467, z=13, stackpos=1} 
local madareth_to_position = {x=287, y=365, z=13, stackpos=1} 
local zugurosh_to_position = {x=314, y=474, z=13, stackpos=1} 
local brothers_to_position = {x=408, y=413, z=13, stackpos=1} 

local time_to_pass = 180 
local tpID = 5023 
local doEffect = CONST_ME_ENERGYHIT 
local message = "You now have 3 minutes to exit this room through the teleporter. It will bring you to the next room only during his time or the teleporter will disappear." 

if creaturename == 'Ushuriel' then 

teleport = doCreateTeleport(tpID, ushuriel_to_position, ushuriel_in_position) 

doSendMagicEffect(ushuriel_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInUshurielWard, (1000*time_to_pass)) 

elseif creaturename == 'Annihilon' then 

teleport = doCreateTeleport(tpID, annihilon_to_position, annihilon_in_position) 

doSendMagicEffect(annihilon_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInAnnihilonWard, (1000*time_to_pass)) 

elseif creaturename == 'Madareth' then 

teleport = doCreateTeleport(tpID, madareth_to_position, madareth_in_position) 

doSendMagicEffect(madareth_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInMadarethWard, (1000*time_to_pass)) 

elseif creaturename == 'Hellgorak' then 

teleport = doCreateTeleport(tpID, hellgorak_to_position, hellgorak_in_position) 

doSendMagicEffect(hellgorak_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInHellgorakWard, (1000*time_to_pass)) 

elseif creaturename == 'Zugurosh' then 

teleport = doCreateTeleport(tpID, zugurosh_to_position, zugurosh_in_position) 

doSendMagicEffect(zugurosh_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInZuguroshWard, (1000*time_to_pass)) 

elseif creaturename == 'Latrivan' then 

teleport = doCreateTeleport(tpID, brothers_to_position, brothers_in_position) 

doSendMagicEffect(brothers_in_position, CONST_ME_ENERGYHIT) 

doCreatureSay(cid, message, TALKTYPE_ORANGE_1) 

addEvent(removeTeleportInBrothersWard, (1000*time_to_pass)) 


end 
return true
end 

function removeTeleportInUshurielWard() 
if getThingfromPos({x=246, y=351, z=12, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=246, y=351, z=12, stackpos=1}).uid,1) 
doSendMagicEffect({x=246, y=351, z=12, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end 
end 

function removeTeleportInAnnihilonWard() 
if getThingfromPos({x=637, y=472, z=13, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=637, y=472, z=13, stackpos=1}).uid,1) 
doSendMagicEffect({x=637, y=472, z=13, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end 
end 

function removeTeleportInHellgorakWard() 
if getThingfromPos({x=335, y=581, z=10, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=335, y=581, z=10, stackpos=1}).uid,1) 
doSendMagicEffect({x=335, y=581, z=10, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end 
end 

function removeTeleportInMadarethWard() 
if getThingfromPos({x=340, y=460, z=13, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=340, y=460, z=13, stackpos=1}).uid,1) 
doSendMagicEffect({x=340, y=460, z=13, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end 
end 

function removeTeleportInZuguroshWard() 
if getThingfromPos({x=390, y=525, z=13, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=390, y=525, z=13, stackpos=1}).uid,1) 
doSendMagicEffect({x=390, y=525, z=13, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end 
end 

function removeTeleportInBrothersWard() 
if getThingfromPos({x=505, y=345, z=13, stackpos=1}).itemid == 5023 then 
doRemoveItem(getThingfromPos({x=505, y=345, z=13, stackpos=1}).uid,1) 
doSendMagicEffect({x=505, y=345, z=13, stackpos=1}, CONST_ME_POFF) 
return TRUE 
end
 
Back
Top