kaspertje100
Member
- Joined
- May 8, 2008
- Messages
- 236
- Reaction score
- 7
Hello everyone,
I´m using this script:
data/creaturescripts/scripts/bossdeath.lua
the XML in creaturescripts:
in demongate.xml (the monster)
error in console:
[07/10/2012 13:39:08] [Warning - Monster::Monster] Unknown event name - bossdeath
I´m using this script:
data/creaturescripts/scripts/bossdeath.lua
Code:
function onDeath(cid, corpse, deathList)
local f = getTileItemById({x=1168, y=1158, z=7}, 2776).uid
if f ~= 0 then
doRemoveItem(f)
doRemoveItem(getTileItemById({x=1169, y=1158, z=7}, 2776).uid)
doRemoveItem(getTileItemById({x=1170, y=1158, z=7}, 2774).uid)
doRemoveItem(getTileItemById({x=1171, y=1157, z=7}, 2776).uid)
doRemoveItem(getTileItemById({x=1171, y=1154, z=7}, 2774).uid)
doRemoveItem(getTileItemById({x=1165, y=1153, z=7}, 2776).uid)
doRemoveItem(getTileItemById({x=1169, y=1152, z=7}, 2774).uid)
doRemoveItem(getTileItemById({x=1165, y=1157, z=7}, 2776).uid)
end
return true
end
the XML in creaturescripts:
Code:
<event type="ondeath" name="Bossdeath" event="script" value="bossdeath.lua"/>
in demongate.xml (the monster)
Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="DemonGate" nameDescription="a demongate" race="fire" experience="6000" speed="280" manacost="0">
<health now="8200" max="8200"/>
<look type="35" corpse="5995"/>
<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="40"/>
<flag runonhealth="0"/>
</flags>
<script>
<event name="bossgate."/>
</script>
<attacks>
<attack name="melee" interval="2000" min="-60" max="-500"/>
<attack name="manadrain" interval="3000" chance="13" range="7" min="-80" max="-300"/>
<attack name="fire" interval="2000" chance="14" range="7" radius="7" target="1" min="-160" max="-350">
<attribute key="shootEffect" value="fire"/>
<attribute key="areaEffect" value="firearea"/>
</attack>
<attack name="firefield" interval="1000" chance="15" range="7" radius="1" target="1">
<attribute key="shootEffect" value="fire"/>
</attack>
<attack name="energy" interval="3000" chance="30" length="8" spread="0" min="-220" max="-460">
<attribute key="areaEffect" value="energy"/>
</attack>
</attacks>
<defenses armor="50" defense="55">
<defense name="healing" interval="1000" chance="15" min="90" max="200">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
<defense name="speed" interval="1000" chance="15" speedchange="200" duration="20000">
<attribute key="areaEffect" value="redshimmer"/>
</defense>
</defenses>
<elements>
<element firePercent="100"/>
<element physicalPercent="25"/>
<element earthpercent="20"/>
<element energyPercent="20"/>
<element deathPercent="20"/>
<element icePercent="-25"/>
<element holyPercent="-10"/>
</elements>
<immunities>
<immunity lifedrain="1"/>
<immunity paralyze="1"/>
<immunity invisible="1"/>
</immunities>
<summons maxSummons="2">
<summon name="fire elemental" interval="2000" chance="10" max="2"/>
</summons>
<voices interval="5000" chance="10">
<voice sentence="MUHAHAHAHA!" yell="1"/>
<voice sentence="I SMELL FEEEEEAAAR!" yell="1"/>
<voice sentence="CHAMEK ATH UTHUL ARAK!" yell="1"/>
<voice sentence="Your resistance is futile!"/>
<voice sentence="Your soul will be mine!" yell="0"/>
</voices>
<loot>
<item id="2148" countmax="100" chance="100000"/><!-- gold coin -->
<item id="2148" countmax="25" chance="100000"/><!-- gold coin -->
<item id="2393" chance="1428"/><!-- giant sword -->
<item id="2514" chance="500"/><!-- mastermind shield -->
<item id="2432" chance="1200"/><!-- fire axe -->
<item id="2472" chance="130"/><!-- magic plate armor -->
<item id="5906" countmax="1" chance="1000"/><!-- demon dust -->
<item id="5954" countmax="1" chance="1000"/><!-- demon horn -->
<item id="2164" chance="200"/><!-- might ring -->
<item id="2176" chance="3000"/><!-- orb -->
<item id="1982" chance="1300"/><!-- purple tome -->
<item id="7368" countmax="4" chance="1200"/><!-- assassin star -->
<item id="2165" chance="1400"/><!-- stealth ring -->
<item id="1987" chance="100000"><!-- bag -->
<inside>
<item id="2214" chance="500"/><!-- ring of healing -->
<item id="2396" chance="600"/><!-- ice rapier -->
<item id="2179" chance="1100"/><!-- gold ring -->
<item id="2795" countmax="6" chance="20000"/><!-- fire mushroom -->
<item id="2678" countmax="3" chance="10000"/><!-- coconut -->
<item id="2148" countmax="100" chance="100000"/><!-- gold coin -->
<item id="2151" countmax="4" chance="4000"/><!-- talon -->
<item id="2462" chance="1200"/><!-- devil helmet -->
<item id="2149" countmax="3" chance="11000"/><!-- small emerald -->
<item id="2171" chance="800"/><!-- platinum amulet -->
<item id="2387" chance="20000"/><!-- double axe -->
<item id="2470" chance="400"/><!-- golden legs -->
<item id="2520" chance="700"/><!-- demon shield -->
<item id="2418" chance="1500"/><!-- golden sickle -->
<item id="7382" chance="4100"/><!-- demonrage sword -->
<item id="2377" chance="3333"/><!-- two handed sword -->
</inside>
</item>
</loot>
</monster>
error in console:
[07/10/2012 13:39:08] [Warning - Monster::Monster] Unknown event name - bossdeath