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

Elements...

EvulMastah

๏̯͡๏﴿
Premium User
Joined
Aug 19, 2007
Messages
4,941
Solutions
11
Reaction score
352
Well, many people around here didnt notice that you can already use them in TFS' monsters, just paste it in your monster_name.xml
Code:
<elements>
<element firePercent="10"/>
<element icePercent="-10"/>
<element earthPercent="10"/>
<element energyPercent="-10"/>
<element holyPercent="10"/>
<element deathPercent="-10"/>
</elements>

+10% strong against fire, earth, holy and 10% weak against ice, energy, death.
 
Last edited:
Here is my Dragon Lord with yours Elements :p And It doesnt works for me , Could you help?


<?xml version="1.0" encoding="UTF-8"?>
<monster name="Dragon Lord" nameDescription="a dragon lord" race="blood" experience="2100" speed="200" manacost="0">
<health now="1900" max="1900"/>
<look type="39" head="0" body="0" legs="0" feet="0" corpse="2881"/>
<targetchange interval="2000" chance="5"/>
<strategy attack="70" defense="10"/>
<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 runonhealth="300"/>
</flags>
<attacks>
<attack name="melee" interval="2000" skill="65" attack="55"/>
<attack name="fire" interval="1000" chance="17" range="7" radius="4" target="1" min="-120" max="-180">
<attribute key="shootEffect" value="fire"/>
<attribute key="areaEffect" value="firearea"/>
</attack>
<attack name="firefield" interval="1000" chance="15" range="7" radius="4" target="1">
<attribute key="shootEffect" value="fire"/>
</attack>
<attack name="fire" interval="1000" chance="17" length="8" spread="3" min="-150" max="-250">
<attribute key="areaEffect" value="firearea"/>
</attack>
</attacks>
<elements>
<element firePercent="10"/>
<element icePercent="-20"/>
<element earthPercent="10"/>
<element energyPercent="-10"/>
<element holyPercent="10"/>
<element deathPercent="-10"/>
</elements>

<defenses armor="32" defense="48">
<defense name="healing" interval="1000" chance="25" min="57" max="93">
<attribute key="areaEffect" value="blueshimmer"/>
</defense>
</defenses>
<immunities>
<immunity physical="0"/>
<immunity energy="0"/>
<immunity fire="1"/>
<immunity poison="1"/>
<immunity lifedrain="1"/>
<immunity paralyze="1"/>
<immunity outfit="1"/>
<immunity drunk="1"/>
<immunity invisible="1"/>
</immunities>
<voices interval="5000" chance="10">
<voice sentence="ZCHHHHH" yell="1"/>
<voice sentence="YOU WILL BURN!" yell="1"/>
</voices>
<loot capacity="900">
<item id="1976" countmax="1" chance="9000"/>
<item id="2672" countmax="5" chance="60000"/>
<item id="2492" countmax="1" chance="100"/>
<item id="2167" countmax="1" chance="5000"/>
<item id="2392" countmax="1" chance="300"/>
<item id="2148" countmax="100" chance="80000"/>
<item id="2148" countmax="100" chance="60000"/>
<item id="2148" countmax="50" chance="40000"/>
<item id="2033" countmax="1" chance="3000"/>
<item id="2796" countmax="1" chance="12000"/>
<item id="2177" countmax="1" chance="600"/>
<item id="2547" countmax="1" chance="6000"/>
<item id="2498" countmax="1" chance="200"/>
<item id="2146" countmax="1" chance="5000"/>
<item id="2479" countmax="1" chance="400"/>
<item id="2528" countmax="1" chance="300"/>
</loot>
</monster>
 
Perhaps it doesnt work with 0.2 (TAGS)... Ive only used it on trunk version and it worked ^^
 
You use Tags or Trunk? Because it is already in Trunk...

... and in Tags sources too.

@monsters.cpp
Code:
else if(xmlStrcmp(p->name, (const xmlChar*)"elements") == 0)
			{
				xmlNodePtr tmpNode = p->children;
				while(tmpNode)
				{
					if(xmlStrcmp(tmpNode->name, (const xmlChar*)"element") == 0)
					{
						CombatType_t type = COMBAT_NONE;
						int32_t percent = 0;

						if(readXMLInteger(tmpNode, "physicalPercent", intValue))
						{
							type = COMBAT_PHYSICALDAMAGE;
							percent = intValue;
						}
						if(readXMLInteger(tmpNode, "icePercent", intValue))
						{
							type = COMBAT_ICEDAMAGE;
							percent = intValue;
						}
						else if(readXMLInteger(tmpNode, "poisonPercent", intValue) || readXMLInteger(tmpNode, "earthPercent", intValue))
						{
							type = COMBAT_EARTHDAMAGE;
							percent = intValue;
						}
						else if(readXMLInteger(tmpNode, "firePercent", intValue))
						{
							type = COMBAT_FIREDAMAGE;
							percent = intValue;
						}
						else if(readXMLInteger(tmpNode, "energyPercent", intValue))
						{
							type = COMBAT_ENERGYDAMAGE;
							percent = intValue;
						}
						else if(readXMLInteger(tmpNode, "holyPercent", intValue))
						{
							type = COMBAT_HOLYDAMAGE;
							percent = intValue;
						}
						else if(readXMLInteger(tmpNode, "deathPercent", intValue))
						{
							type = COMBAT_DEATHDAMAGE;
							percent = intValue;
						}
						
						if(percent != 0 && type != COMBAT_NONE)
							mType->elementMap[type] = percent;
					}
					tmpNode = tmpNode->next;
				}
			}
 
EHmm no idea what im using lol, Im really newbie in this things.
Well and i cant find monsters.cpp in my ots folder :D
it would be great if u could explain me what difference is between tags and trunk and whats better ofc :p
 
Ill post newest revision of tags in few mins, jsut keep an eye on dowloands section.

The difference is that, that the TRUNK is for testing purposes and have functions that are being fixed, then the functions/files are fixed - they go to TAGS :p
 
Great! I love it! Now my monster are so cool!

Thanks you very much Marcinek Paladinek!
 
Back
Top