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

Solved [Spawn::addMonster] Cannot find

Blysco

New Member
Joined
Oct 12, 2013
Messages
163
Reaction score
2
Hey, I`ve tried alot and was searching a lot in the world wide web but I found anything that helped me. Now im going to ask you how to add a "Monster" how to get that error.
I importet the monster with RME and I was able to place the monster on the map but when I start the server it says it cannt find it. I hope someone can help me. Here is the XML

Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Demon Guard" nameDescription="a Demon Guard" race="fire" experience="5000" speed="260" manacost="0">
    <health now="7200" max="7200"/>
    <look type="35" corpse="5995"/>
    <targetchange interval="5000" chance="8"/>
    <strategy attack="80" 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="1800" skill="70" attack="120"/>
        <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="1500" chance="15" range="7" radius="1" target="1">
            <attribute key="shootEffect" value="fire"/>
        </attack>
        <attack name="energy" interval="3500" 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="2000" 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>

    <immunities>
        <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="Your soul will be mine!"/>
        <voice sentence="MUHAHAHAHA!"/>
        <voice sentence="CHAMEK ATH UTHUL ARAK!"/>
        <voice sentence="I SMELL FEEEEAAAAAR!"/>
        <voice sentence="Your resistance is futile!"/>
    </voices>
    <loot>
        <item id="2148" countmax="100" chance="100000"/><!-- gold coin -->
        <item id="2148" countmax="99" chance="100000"/><!-- gold coin -->
        <item id="2152" chance="50000"/><!-- platinum coin -->
        <item id="2795" countmax="5" chance="20000"/><!-- fire mushroom -->
        <item id="8473" countmax="3" chance="20000"/><!-- ultimate health potion -->
        <item id="7590" countmax="3" chance="14285"/><!-- great mana potion -->
        <item id="2387" chance="14285"/><!-- double axe -->
        <item id="2149" chance="10000"/><!-- small emerald -->
        <item id="7368" countmax="5" chance="5263"/><!-- assassin star -->
        <item id="2432" chance="3703"/><!-- fire axe -->
        <item id="2151" chance="3571"/><!-- talon -->
        <item id="2176" chance="2854"/><!-- orb -->
        <item id="2393" chance="2000"/><!-- giant sword -->
        <item id="2418" chance="1428"/><!-- golden sickle -->
        <item id="2165" chance="1333"/><!-- stealth ring -->
        <item id="2462" chance="1204"/><!-- devil helmet -->
        <item id="1982" chance="1190"/><!-- purple tome -->
        <item id="2179" chance="1010"/><!-- gold ring -->
        <item id="2171" chance="813"/><!-- platinum amulet -->
        <item id="2396" chance="666"/><!-- ice rapier -->
        <item id="2520" chance="649"/><!-- demon shield -->
        <item id="2214" chance="473"/><!-- ring of healing -->
        <item id="5954" chance="467"/><!-- demon horn -->
        <item id="2470" chance="413"/><!-- golden legs -->
        <item id="2514" chance="389"/><!-- mastermind shield -->
        <item id="2164" chance="170"/><!-- might ring -->
        <item id="7393" chance="78"/><!-- demon trophy -->
        <item id="7382" chance="60"/><!-- demonrage sword -->
    </loot>
</monster>

H7eu124.png



Solved !
The problem was that the Monster.xml was write secured.... Always so easy but always need so long to get it & there was a fail I forgott the /> at the end :/
 
Last edited:
How did you added it in monsters.xml?
I fixed it. Now it works but I have another problem. I hope you cann help me there.

I want that a Teleporter create after I kill a monster and it works but the Teleporter dont works. He dosnt teleports me.

I already had it working but after I wanted more than 2 nothing worked anymore.

Code:
local config = {
   timeToRemove = 60, -- seconds
   message = "TELEPORT HAS BEEN OPENED FOR 60 SECONDS",
   teleportId = 1387,
   bosses = {
   ["Demon Guard"] = {pos ={x = 32354, y = 32287, z = 8, stackpos=1}, aid=1096}
  
  
  
   }
}
local function removal(position)
   doRemoveThing(getTileItemById(position, config.teleportId).uid, 1)
   return true
end

function onStepIn(cid, item, pos)

local tam = {x = 32353, y = 32286, z = 15}

    if item.actionid == 1096 then
        doTeleportThing(cid,tam)
        doSendMagicEffect(getCreaturePosition(cid),1)
        local tp = doRemoveItem(item.uid, 1387)
        end
    return 1
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 * 600, position)
     end
   return true
end
 
Change local teleport = doCreateItem(config.teleportId, t.pos) to
Code:
doCreateTeleport(config.teleportId, {x = 32353, y = 32286, z = 15}, t.pos)
And remove doItemSetAttribute(teleport, "aid", t.aid) and
Code:
function onStepIn(cid, item, pos)

local tam = {x = 32353, y = 32286, z = 15}

if item.actionid == 1096 then
doTeleportThing(cid,tam)
doSendMagicEffect(getCreaturePosition(cid),1)
local tp = doRemoveItem(item.uid, 1387)
end
return 1
end
 
You are amazing thanks :)

Cann I add more monster to this script or I need to make a new for each monster ?
 
In the table bosses you can add another line for an other monster. Don't forget to add a comma at the end of the line, table values are separated with commas.
~~
bosses = {
["Demon Guard"] = {pos ={x = 32354, y = 32287, z = 8}, topos = {x = 32353, y = 32286, z = 15}},
["Other Monster"] = {pos ={x = 32454, y = 32287, z = 8}, topos = {x = 32453, y = 32286, z = 15}}​
}

Code:
doCreateTeleport(config.teleportId, t.topos, t.pos)
 
In the table bosses you can add another line for an other monster. Don't forget to add a comma at the end of the line, table values are separated with commas.
~~
bosses = {
["Demon Guard"] = {pos ={x = 32354, y = 32287, z = 8}, topos = {x = 32353, y = 32286, z = 15}},
["Other Monster"] = {pos ={x = 32454, y = 32287, z = 8}, topos = {x = 32453, y = 32286, z = 15}}​
}

Code:
doCreateTeleport(config.teleportId, t.topos, t.pos)
I hope that I will be good as you in a few years :DDD
Thank you very much you helped me a lot !
 
Back
Top