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

Desperately searching for a solution this "creature dead create tp" script

Status
Not open for further replies.

christiandb

Member
Joined
Feb 5, 2008
Messages
2,469
Reaction score
5
Location
010
Hey.

I hope someone can finally help me since I've tried like 5 different scripts and it still doesn't want to work. If you need more info about some scripts or somethin please add me on msn ([email protected])
Here is my inquisition.lua:
Code:
local config = {
	message = "Go into the teleporter in 3 minutes, else it will disappear.",
	timeToRemove = 180, -- seconds
	teleportId = 1387,
	bosses = { -- Monster Name, Teleport To Position, Teleport Position
		["Ushuriel"] = { { x = 33137, y = 31502, z = 7 }, { x = 33094, y = 31453, z = 10, stackpos = 1 } },
		["Annihilon"] = { { x = 33846, y = 31282, z = 7 }, { x = 33718, y = 31271, z = 8, stackpos = 1 } },
		["Hellgorak"] = { { x = 33641, y = 31275, z = 7 }, { x = 33655, y = 31156, z = 7, stackpos = 1 } },
		["Madareth"] = { { x = 33306, y = 31368, z = 7 }, { x = 33410, y = 31385, z = 7, stackpos = 1 } },
		["Zugurosh"] = { { x = 33263, y = 31446, z = 7 }, { x = 33344, y = 31435, z = 7, stackpos = 1 } },
		["Latrivan"] = { { x = 33598, y = 31426, z = 7 }, { x = 33629, y = 31305, z = 7, stackpos = 1 } }
	}
}

local function removal(position)
	if getThingfromPos(position).itemid == config.teleportId then
		doRemoveItem(getThingfromPos(position).uid)
	end
	return TRUE
end

function onDeath(cid, corpse, killer)
	local position = getCreaturePosition(cid)
	for name, pos in pairs(config.bosses) do
		if name == getCreatureName(cid) then
			teleport = doCreateTeleport(config.teleportId, pos[1], pos[2])
			doCreatureSay(cid, config.message, TALKTYPE_ORANGE_1)
			addEvent(removal, config.timeToRemove * 1000, pos[2])
		end
	end
	return TRUE
end
My createscripts.xml:
Code:
	<event type="death" name="Inquisition" script="inquisition.lua"/>
One of my bosses:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Hellgorak" nameDescription="Hellgorak" race="blood" experience="10000" speed="360" manacost="0">
<health now="40000" max="40000"/>
<look type="12" head="19" body="96" legs="21" feet="81" corpse="6068"/>
<targetchange interval="5000" chance="8"/>
<strategy attack="100" defense="0"/>
<flags>
	<flag summonable="0"/>
	<flag attackable="1"/>
	<flag hostile="1"/>
	<flag illusionable="0"/>
	<flag convinceable="0"/>
	<flag pushable="0"/>
	<flag canpushitems="1"/>
	<flag canpushcreatures="1"/>
	<flag targetdistance="1"/>
	<flag staticattack="85"/>
	<flag runonhealth="0"/>
</flags>
<attacks>
    <attack name="melee" interval="2000" skill="130" attack="130"/>
    <attack name="energy" interval="1000" chance="11" length="8" spread="0" min="-250" max="-819">
        <attribute key="areaEffect" value="purpleenergy"/>
    </attack>
    <attack name="manadrain" interval="2000" chance="14" radius="5" target="0" min="-90" max="-500">
        <attribute key="areaEffect" value="stun"/>
    </attack>
    <attack name="fire" interval="1000" chance="11" radius="5" target="1" min="-50" max="-520">
        <attribute key="areaEffect" value="firearea"/>
    </attack>
	<attack name="lifedrain" interval="2000" chance="5" radius="7" target="0" min="0" max="-150">
		<attribute key="areaEffect" value="poff"/>
	</attack>
</attacks>
<defenses armor="70" defense="65">
	<defense name="healing" interval="1000" chance="11" min="400" max="900">
		<attribute key="areaEffect" value="greenshimmer"/>
	</defense>
</defenses>
<elements>
    <element icePercent="99"/>
	<element energyPercent="99"/>
	<element earthPercent="99"/>
    <element holyPercent="99"/>
    <element deathPercent="99"/>
    <element firePercent="99"/>
	<element drownPercent="-50"/>
</elements>
<immunities>
	<immunity lifedrain="1"/>
	<immunity paralyze="1"/>
	<immunity invisible="1"/>
</immunities>
<voices interval="5000" chance="0">
	<voice sentence="??" yell="1"/>
	<voice sentence="??" yell="1"/>
</voices>
<loot>
	<item id="2148" countmax="100" chance1="80000" chancemax="8"/>
	<item id="2148" countmax="100" chance1="80000" chancemax="10"/>
	<item id="2160" countmax="3" chance1="100000" chancemax="0"/>
	<item id="2143" countmax="7" chance1="3000" chancemax="0"/> --White pearl
	<item id="2514" chance="1650"/> --mastermind shield
	<item id="7590" chance="7000"/> --great mana potion
	<item id="7591" chance="7000"/> --great health potion
	<item id="1987" chance="100000">
		<inside>
			<item id="7431" chance="1400"/> --Demonbone
			<item id="2421" chance="1100"/> --thunder hammer
			<item id="7368" countmax="25" chance="100000"/> --stars
		</inside>
	</item>
</loot>
</monster>

Thanks in advance,

Chris~
 
Last edited:
Maybe in data/creaturescripts/login.lua, under onLogin put " registerCreatureEvent(cid, "Inquisition")"

Note: ^ I don't now if that is necessary, i'm trying to help you
Note2: Sorry my bad english!
Note3: Nappy new year!
 
Status
Not open for further replies.
Back
Top