• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

[Request] Help with that script

cuba

New Member
Joined
Feb 24, 2015
Messages
136
Reaction score
2
hello otland can anyone help me to find this script monster change outfit every 1 sec like this
uGBZHAO.png
 
Code:
<defense name="outfit" interval="2000" chance="10" monster="Rat" duration="1000">
            <attribute key="areaEffect" value="energy"/>
</defense>
 
where can i put this script @imkingran

In the monster's XML file, example:
inside the defense tags I've added the change outfit tag

data/monsters/Demons/fury.xml

Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Fury" nameDescription="a fury" race="blood" experience="4000" speed="460" manacost="0">
    <health now="4100" max="4100"/>
    <look type="149" head="94" body="77" legs="96" feet="0" addons="3" corpse="6081"/>
    <targetchange interval="5000" chance="8"/>
    <strategy attack="100" defense="0"/>
    <flags>
        <flag summonable="0"/>
        <flag attackable="1"/>
        <flag hostile="1"/>
        <flag illusionable="1"/>
        <flag convinceable="0"/>
        <flag pushable="0"/>
        <flag canpushitems="1"/>
        <flag canpushcreatures="1"/>
        <flag targetdistance="1"/>
        <flag staticattack="60"/>
        <flag runonhealth="0"/>
    </flags>
    <attacks>
        <attack name="melee" interval="2000" skill="50" attack="170"/>
        <attack name="physical" interval="2000" chance="17" range="7" min="-140" max="-200">
            <attribute key="shootEffect" value="throwingstar"/>
        </attack>
        <attack name="melee" interval="1000" chance="15" range="7" radius="3" target="0" min="-115" max="-155">
            <attribute key="areaEffect" value="blackspark"/>
        </attack>
        <attack name="melee" interval="3000" chance="30" length="8" spread="0" min="-300" max="-420">
            <attribute key="areaEffect" value="redspark"/>
        </attack>
        <attack name="physical" interval="1000" chance="25" range="7" min="-170" max="-200">
            <attribute key="shootEffect" value="snowball"/>
            <attribute key="areaEffect" value="poff"/>
        </attack>
    </attacks>
    <defenses armor="25" defense="30">
        <defense name="healing" interval="1000" chance="25" min="180" max="290">
            <attribute key="areaEffect" value="blueshimmer"/>
        </defense>
        <defense name="outfit" interval="1000" chance="10" monster="Rat" duration="1000">
                    <attribute key="areaEffect" value="energy"/>
        </defense>
    </defenses>
    <elements>
        <element firePercent="100"/>
        <element icePercent="40"/>
        <element holyPercent="40"/>
        <element deathPercent="-20"/>
        <element energyPercent="-20"/>
        <element earthPercent="-15"/>
        <element physicalPercent="-10"/>
    </elements>
    <immunities>
        <immunity paralyze="1"/>
    <immunity invisible="1"/>
    </immunities>
    <voices interval="3000" chance="30">
        <voice sentence="Ahhhhrrrr!"/>
        <voice sentence="Waaaaah!"/>
        <voice sentence="Carnage!"/>
    </voices>
    <loot>
        <item id="2148" countmax="90" chance="43000"/><!-- gold coin -->
        <item id="2148" countmax="75" chance="43000"/><!-- gold coin -->
        <item id="2148" countmax="65" chance="43000"/><!-- gold coin -->
        <item id="6558" countmax="3" chance="25000"/><!-- concentrated demonic blood -->
        <item id="6500" chance="22500"/><!-- demonic essence -->
        <item id="2470" chance="450"/><!-- golden legs -->
        <item id="7591" chance="10000"/><!-- great health potion-->
        <item id="2666" chance="25000"/><!-- meat -->
        <item id="7456" chance="1800"/><!-- noble axe -->
        <item id="5022" countmax="3" chance="1300"/><!-- orichalcum pearl -->
        <item id="2152" countmax="3" chance="2000"/><!-- platinum coin -->
        <item id="5911" chance="3650"/><!-- red piece of cloth -->
        <item id="1987" chance="100000"><!-- bag -->
            <inside>
        <item id="9813" chance="11000"/><!-- rusty legs -->
        <item id="2120" countmax="3" chance="6000"/><!-- small amethyst -->
        <item id="5944" chance="21500"/><!-- soul orb -->
        <item id="2645" chance="1000"/><!-- steel boots -->
        <item id="2181" chance="20000"/><!-- terra rod -->
        <item id="7404" chance="100"/><!-- assassin dagger -->
        <item id="2487" chance="500"/><!-- crown armor -->
        <item id="5944" chance="7368"/><!-- assassin star -->
        <item id="2124" chance="750"/><!-- crystal ring--> 
        <item id="2156" chance="900"/><!-- red gem --> 
            </inside>
        </item>
    </loot>
</monster>
 
In the monster's XML file, example:
inside the defense tags I've added the change outfit tag

data/monsters/Demons/fury.xml

Code:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Fury" nameDescription="a fury" race="blood" experience="4000" speed="460" manacost="0">
    <health now="4100" max="4100"/>
    <look type="149" head="94" body="77" legs="96" feet="0" addons="3" corpse="6081"/>
    <targetchange interval="5000" chance="8"/>
    <strategy attack="100" defense="0"/>
    <flags>
        <flag summonable="0"/>
        <flag attackable="1"/>
        <flag hostile="1"/>
        <flag illusionable="1"/>
        <flag convinceable="0"/>
        <flag pushable="0"/>
        <flag canpushitems="1"/>
        <flag canpushcreatures="1"/>
        <flag targetdistance="1"/>
        <flag staticattack="60"/>
        <flag runonhealth="0"/>
    </flags>
    <attacks>
        <attack name="melee" interval="2000" skill="50" attack="170"/>
        <attack name="physical" interval="2000" chance="17" range="7" min="-140" max="-200">
            <attribute key="shootEffect" value="throwingstar"/>
        </attack>
        <attack name="melee" interval="1000" chance="15" range="7" radius="3" target="0" min="-115" max="-155">
            <attribute key="areaEffect" value="blackspark"/>
        </attack>
        <attack name="melee" interval="3000" chance="30" length="8" spread="0" min="-300" max="-420">
            <attribute key="areaEffect" value="redspark"/>
        </attack>
        <attack name="physical" interval="1000" chance="25" range="7" min="-170" max="-200">
            <attribute key="shootEffect" value="snowball"/>
            <attribute key="areaEffect" value="poff"/>
        </attack>
    </attacks>
    <defenses armor="25" defense="30">
        <defense name="healing" interval="1000" chance="25" min="180" max="290">
            <attribute key="areaEffect" value="blueshimmer"/>
        </defense>
        <defense name="outfit" interval="2000" chance="10" monster="Rat" duration="1000">
                    <attribute key="areaEffect" value="energy"/>
        </defense>
    </defenses>
    <elements>
        <element firePercent="100"/>
        <element icePercent="40"/>
        <element holyPercent="40"/>
        <element deathPercent="-20"/>
        <element energyPercent="-20"/>
        <element earthPercent="-15"/>
        <element physicalPercent="-10"/>
    </elements>
    <immunities>
        <immunity paralyze="1"/>
    <immunity invisible="1"/>
    </immunities>
    <voices interval="3000" chance="30">
        <voice sentence="Ahhhhrrrr!"/>
        <voice sentence="Waaaaah!"/>
        <voice sentence="Carnage!"/>
    </voices>
    <loot>
        <item id="2148" countmax="90" chance="43000"/><!-- gold coin -->
        <item id="2148" countmax="75" chance="43000"/><!-- gold coin -->
        <item id="2148" countmax="65" chance="43000"/><!-- gold coin -->
        <item id="6558" countmax="3" chance="25000"/><!-- concentrated demonic blood -->
        <item id="6500" chance="22500"/><!-- demonic essence -->
        <item id="2470" chance="450"/><!-- golden legs -->
        <item id="7591" chance="10000"/><!-- great health potion-->
        <item id="2666" chance="25000"/><!-- meat -->
        <item id="7456" chance="1800"/><!-- noble axe -->
        <item id="5022" countmax="3" chance="1300"/><!-- orichalcum pearl -->
        <item id="2152" countmax="3" chance="2000"/><!-- platinum coin -->
        <item id="5911" chance="3650"/><!-- red piece of cloth -->
        <item id="1987" chance="100000"><!-- bag -->
            <inside>
        <item id="9813" chance="11000"/><!-- rusty legs -->
        <item id="2120" countmax="3" chance="6000"/><!-- small amethyst -->
        <item id="5944" chance="21500"/><!-- soul orb -->
        <item id="2645" chance="1000"/><!-- steel boots -->
        <item id="2181" chance="20000"/><!-- terra rod -->
        <item id="7404" chance="100"/><!-- assassin dagger -->
        <item id="2487" chance="500"/><!-- crown armor -->
        <item id="5944" chance="7368"/><!-- assassin star -->
        <item id="2124" chance="750"/><!-- crystal ring--> 
        <item id="2156" chance="900"/><!-- red gem --> 
            </inside>
        </item>
    </loot>
</monster>
monster will change outfit automatic?
 
i got that error [01/03/2015 22:34:28] [Spawn::addMonster] Cannot find ""

How did you add it? Which TFS version are you using?

I believe this error comes if you add a monster to your Map which doesn't exist in your folder. In this case it can't find the monsters with the name "".
 
How did you add it? Which TFS version are you using?

I believe this error comes if you add a monster to your Map which doesn't exist in your folder. In this case it can't find the monsters with the name "".
i put that script u gave me it in fury folder
 
Back
Top