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

Monsters can't die

Piechu

New Member
Joined
Oct 10, 2008
Messages
113
Reaction score
0
Location
Poland/Jasło
Monsters and Players can't death where is problem ? Please fix that... I use tfs 0.3.4

Screen:




Please help i give rep++
 
My Demon.xml hmm this isn't problem maybe :


<?xml version="1.0" encoding="UTF-8"?>
<monster name="demon" nameDescription="a demon" 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>
<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" chance1="100000" chancemax="0"/>
<item id="2148" countmax="25" chance1="100000" chancemax="0"/>
<item id="2393" chance="1428"/>
<item id="2514" chance="500"/>
<item id="2432" chance="1200"/>
<item id="2472" chance="130"/>
<item id="5906" countmax="1" chance="1000"/>
<item id="5954" countmax="1" chance="1000"/>
<item id="2164" chance="200"/>
<item id="2176" chance="3000"/>
<item id="1982" chance="1300"/>
<item id="7368" countmax="4" chance="1200"/>
<item id="2165" chance="1400"/>
<item id="1987" chance="100000">
<inside>
<item id="2214" chance="500"/>
<item id="2396" chance="600"/>
<item id="2179" chance="1100"/>
<item id="2795" countmax="6" chance="20000"/>
<item id="2678" countmax="3" chance1="10000" chancemax="0"/>
<item id="2148" countmax="100" chance1="100000" chancemax="0"/>
<item id="2151" countmax="4" chance1="4000" chancemax="0"/>
<item id="2462" chance="1200"/>
<item id="2149" countmax="3" chance1="11000" chancemax="0"/>
<item id="2171" chance="800"/>
<item id="2387" chance="20000"/>
<item id="2470" chance="400"/>
<item id="2520" chance="700"/>
<item id="2418" chance="1500"/>
<item id="7382" chance="4100"/>
<item id="2377" chance="3333"/>
</inside>
</item>
</loot>
</monster>
 
function onKill(cid, target)
local monster = getCreatureName(target)
local room = getArenaMonsterIdByName(monster)
if room > 0 then
setPlayerStorageValue(cid, room, 1)
doPlayerSendTextMessage(cid,MESSAGE_EVENT_DEFAULT,'Mozesz wejsc do kolejnego pokoju areny!')
end
end

Kill.lua ? This is for arena :> My Kill.lua up ^
 
There's your problem. You need to add a return TRUE.

Use this instead:
LUA:
function onKill(cid, target)
local monster = getCreatureName(target)
local room = getArenaMonsterIdByName(monster)
if room > 0 then
setPlayerStorageValue(cid, room, 1)
doPlayerSendTextMessage(cid,MESSAGE_EVENT_DEFAULT, 'Mozesz wejsc do kolejnego pokoju areny!')
end
return TRUE
end

Also next time use lua tags to post scripts :p don't put them in quotes.

Like this:
[ lua] script here menz [ /lua] without the spaces :)
 
Back
Top