DakotaCoty
The behemoth
- Joined
- May 24, 2015
- Messages
- 46
- Reaction score
- 13
Hello all,
version: TFS 1.2
Client version: 10.78
Scripts:
Creaurescript
BazirKill.lua
Bazir monster
He dies, but the orange text nor the teleport comes up despite him being the target. If I'm missing something else that needs to be here, let me know. Cheers.
version: TFS 1.2
Client version: 10.78
Scripts:
Creaurescript
Code:
<event type="kill" name="BazirKill" script="quests/donor quest/BazirKill.lua" />
BazirKill.lua
Code:
local teleportToPosition = Position(31951, 32202, 13)
local function removeTeleport(position)
local teleportItem = Tile(position):getItemById(1387)
if teleportItem then
teleportItem:remove()
position:sendMagicEffect(CONST_ME_POFF)
end
end
function onKill(creature, target)
local targetMonster = target:getMonster()
if not targetMonster or targetMonster:getName():lower() ~= 'bazir' then
return true
end
local position = targetMonster:getPosition()
position:sendMagicEffect(CONST_ME_TELEPORT)
local item = Game.createItem(1387, 1, position)
if item:isTeleport() then
item:setDestination(teleportToPosition)
end
targetMonster:say('Bazir has been defeated, claim your rewards, mortals! It will disappear in 2 minutes.', TALKTYPE_MONSTER_SAY, 0, 0, position)
--remove portal after 1 min
addEvent(removeTeleport, 2 * 30 * 1000, position)
return true
end
Bazir monster
Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Bazir" nameDescription="Bazir" race="fire" experience="30000" speed="530" manacost="0">
<health now="110000" max="110000"/>
<look type="35" head="0" body="0" legs="0" feet="0" corpse="0"/>
<targetchange interval="2000" chance="10"/>
<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 runonhealth="3000"/>
</flags>
<attacks>
<attack name="melee" interval="2000" skill="200" attack="250"/>
<attack name="manadrain" interval="1000" chance="7" range="7" min="-100" max="-1000">
<attribute key="shootEffect" value="energy"/>
<attribute key="areaEffect" value="poff"/>
</attack>
<attack name="drunk" interval="1000" chance="7" range="7">
<attribute key="shootEffect" value="energy"/>
<attribute key="areaEffect" value="energyarea"/>
</attack>
<attack name="strength" interval="1000" chance="9" range="7">
<attribute key="shootEffect" value="largerock"/>
<attribute key="areaEffect" value="energyarea"/>
</attack>
<attack name="lifedrain" interval="1000" chance="13" radius="8" target="0" min="-400" max="-700">
<attribute key="areaEffect" value="bluebubble"/>
</attack>
<attack name="manadrain" interval="1000" chance="10" radius="8" target="0" min="-400" max="-700">
<attribute key="areaEffect" value="greenshimmer"/>
</attack>
<attack name="speed" interval="1000" chance="12" radius="6" target="0" speedchange="-1900" duration="60000">
<attribute key="areaEffect" value="poison"/>
</attack>
<attack name="strength" interval="1000" chance="8" radius="5" target="0">
<attribute key="areaEffect" value="blackspark"/>
</attack>
<attack name="outfit" interval="1000" chance="2" radius="8" target="0" monster="demon" duration="5000">
<attribute key="areaEffect" value="bluebubble"/>
</attack>
<attack name="outfit" interval="1000" chance="2" radius="8" target="0" item="3058" duration="5000">
<attribute key="areaEffect" value="bluebubble"/>
</attack>
<attack name="fire" interval="1000" chance="34" range="7" radius="7" target="1" min="-100" max="-900">
<attribute key="shootEffect" value="fire"/>
<attribute key="areaEffect" value="firearea"/>
</attack>
<attack name="lifedrain" interval="1000" chance="15" length="8" spread="0" min="-500" max="-850">
<attribute key="areaEffect" value="redshimmer"/>
</attack>
</attacks>
<defenses armor="160" defense="160">
<defense name="healing" interval="1000" chance="15" min="5000" max="10000">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
<defense name="healing" interval="1000" chance="25" min="2000" max="3000">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
<defense name="speed" interval="1000" chance="8" speedchange="1901" duration="5000">
<attribute key="areaEffect" value="redshimmer"/>
</defense>
<defense name="invisible" interval="1000" chance="4" duration="10000">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
<defense name="invisible" interval="1000" chance="17" duration="2000">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
<defense name="outfit" interval="1000" chance="2" item="2916" duration="7000">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
</defenses>
<immunities>
<immunity physical="0"/>
<immunity energy="1"/>
<immunity fire="1"/>
<immunity poison="1"/>
<immunity lifedrain="1"/>
<immunity paralyze="1"/>
<immunity outfit="1"/>
<immunity drunk="1"/>
<immunity invisible="1"/>
</immunities>
<summons maxSummons="1">
<summon name="demon" interval="1000" chance="15" max="2"/>
</summons>
<voices interval="5000" chance="10">
<voice sentence="COME HERE! FREE ITEMS FOR EVERYONE!" yell="1"/>
<voice sentence="BOW TO THE POWER OF THE RUTHLESS SEVEN!"/>
<voice sentence="Slay your friends and I will spare you!" yell="1"/>
<voice sentence="DON'T BE AFRAID! I AM COMING IN PEACE!" yell="1"/>
</voices>
</monster>
He dies, but the orange text nor the teleport comes up despite him being the target. If I'm missing something else that needs to be here, let me know. Cheers.