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

Does anyone know what is causing this bug?

Mateus Robeerto

Excellent OT User
Joined
Jun 5, 2016
Messages
1,337
Solutions
71
Reaction score
697
Location
ლ(ಠ益ಠლ)
Does anyone know what is causing this bug? I'm using the original TFS 1.5 8.0 runes. Is there any way to fix these bugs? Please see the image and video.f707af8e-34a7-4470-865f-b4c3594cb07e.jpg


When I throw runes on the ground, like energy or fire bomb, and a player walks over them, console errors "000" appear. I do not know what this means.
 
it's look like some random print in creaturescripts
bug tela preta.png
I believe the problem is not in CreatureScript. Look how it turned out, it was like this originally in CreatureScript and bugs are appearing in the console. After adding the store, dodge, critical, and counting kills and frags, it's likely the issue is Movement related or somewhere else.
Using notepad++ search for print in your data folder, then compare
I've read it a few times and I still don't fully understand it, haha. Could you explain the details better?
 
View attachment 76120
I believe the problem is not in CreatureScript. Look how it turned out, it was like this originally in CreatureScript and bugs are appearing in the console. After adding the store, dodge, critical, and counting kills and frags, it's likely the issue is Movement related or somewhere else.

I've read it a few times and I still don't fully understand it, haha. Could you explain the details better?
the print statement, could be in any script file actually, he wasn't talking about the creaturescripts.xml

any code that works with dmg taken or dmg dealt, (onhealthChange) could have thar print statement

you should open your whole project in Microsoft visual studio (or any other program that do something similar) and use the button ctrl+shift+f to search the whole project for "print(" statements and check them to find this specific one.

Unless you know what scripts you have changed in the past that could have added this, then you can search only on that file.
 
the print statement, could be in any script file actually, he wasn't talking about the creaturescripts.xml

any code that works with dmg taken or dmg dealt, (onhealthChange) could have thar print statement

you should open your whole project in Microsoft visual studio (or any other program that do something similar) and use the button ctrl+shift+f to search the whole project for "print(" statements and check them to find this specific one.

Unless you know what scripts you have changed in the past that could have added this, then you can search only on that file.
Damn, it really was a movements problem. Thank you, you saved me!
 
I don't know if it's a source code that is causing the bug. If I remove the lines, everything works normally and no errors appear in the console. Not sure what happened to cause the bug. Please check the items.xml and movements.xml files. I tried changing "damage" to "initDamage" but it didn't help.
Lua:
<!-- Fields -->
    <movevent event="StepIn" itemid="1487" function="onStepInField" />
    <movevent event="AddItem" itemid="1487" function="onAddField" />
    <movevent event="StepIn" itemid="1488" function="onStepInField" />
    <movevent event="AddItem" itemid="1488" function="onAddField" />
    <movevent event="StepIn" itemid="1489" function="onStepInField" />
    <movevent event="AddItem" itemid="1489" function="onAddField" />
    <movevent event="StepIn" itemid="1490" function="onStepInField" />
    <movevent event="AddItem" itemid="1490" function="onAddField" />
    <movevent event="StepIn" itemid="1491" function="onStepInField" />
    <movevent event="AddItem" itemid="1491" function="onAddField" />
    <movevent event="StepIn" itemid="1492" function="onStepInField" />
    <movevent event="AddItem" itemid="1492" function="onAddField" />
    <movevent event="StepIn" itemid="1493" function="onStepInField" />
    <movevent event="AddItem" itemid="1493" function="onAddField" />
    <movevent event="StepIn" itemid="1494" function="onStepInField" />
    <movevent event="AddItem" itemid="1494" function="onAddField" />
    <movevent event="StepIn" itemid="1495" function="onStepInField" />
    <movevent event="AddItem" itemid="1495" function="onAddField" />
    <movevent event="StepIn" itemid="1496" function="onStepInField" />
    <movevent event="AddItem" itemid="1496" function="onAddField" />
    <movevent event="StepIn" itemid="1497" function="onStepInField" />
    <movevent event="AddItem" itemid="1497" function="onAddField" />
    <movevent event="StepIn" itemid="1498" function="onStepInField" />
    <movevent event="AddItem" itemid="1498" function="onAddField" />
    <movevent event="StepIn" itemid="1499" function="onStepInField" />
    <movevent event="AddItem" itemid="1499" function="onAddField" />
    <movevent event="StepIn" itemid="1500" function="onStepInField" />
    <movevent event="AddItem" itemid="1500" function="onAddField" />
    <movevent event="StepIn" itemid="1501" function="onStepInField" />
    <movevent event="AddItem" itemid="1501" function="onAddField" />
    <movevent event="StepIn" itemid="1502" function="onStepInField" />
    <movevent event="AddItem" itemid="1502" function="onAddField" />
    <movevent event="StepIn" itemid="1503" function="onStepInField" />
    <movevent event="AddItem" itemid="1503" function="onAddField" />
    <movevent event="StepIn" itemid="1504" function="onStepInField" />
    <movevent event="AddItem" itemid="1504" function="onAddField" />
    <movevent event="StepIn" itemid="1505" function="onStepInField" />
    <movevent event="AddItem" itemid="1505" function="onAddField" />
    <movevent event="StepIn" itemid="1506" function="onStepInField" />
    <movevent event="AddItem" itemid="1506" function="onAddField" />
    <movevent event="StepIn" itemid="1507" function="onStepInField" />
    <movevent event="AddItem" itemid="1507" function="onAddField" />
    <movevent event="StepIn" itemid="7359" function="onStepInField" />
    <movevent event="AddItem" itemid="7360" function="onAddField" />
Code:
<item id="1488" article="a" name="fire field">
        <attribute key="type" value="magicfield" />
        <attribute key="decayTo" value="1489" />
        <attribute key="duration" value="120" />
        <attribute key="field" value="fire">
            <attribute key="ticks" value="10000" />
            <attribute key="count" value="7" />
            <attribute key="initDamage" value="10" />
        </attribute>
    </item>
Check if it is correct. What could be causing the bug?
 
You need search all related 'print()' functions inside your project folder, look this video, i recommend use Visual Studio Code.

 
Or try to override print to make that log debug info
Just in case someone would like to trace any function caller it can be done like:

Lua:
local ori_print = print
print = function(...)
    local src = debug.getinfo(2).short_src
    ori_print('called by: '.. src)
    ori_print(...)
end
 
I found out that it was a life protection item. Without using the item, it did not show errors, but with the 'helmet' item, which is life immunity, it did show an error.
watch the video, will understand better

It was the movevens.xml file yes


Lua:
<movevent event="Equip"  itemid="40887" slot="head" function="onEquipItem"> -- Gladiator Helmet
        <vocation id="9"/><vocation id="13" showInDescription="0"/>
        <vocation id="10"/><vocation id="14" showInDescription="0"/>
        <vocation id="11"/><vocation id="15" showInDescription="0"/>
        <vocation id="12"/><vocation id="16" showInDescription="0"/>
    </movevent>
    <movevent event="DeEquip" itemid="40887" slot="head" function="onDeEquipItem"/>

Lua:
<item id="40887" name="gladiator helmet">
         <attribute key="description" value="An helmet of heroes gladiators. [RegenL.ife 600/1]"/>
    <attribute key="weight" value="8500"/>
    <attribute key="armor" value="16"/>
    <attribute key="slotType" value="head"/>
    <attribute key="healthTicks" value="1"/>
         <attribute key="healthGain" value="600"/>
</item>

Please check whether the moves.xml and items.xml files are correct or not.


When I use any item and pass through fields, it throws the bugs! Did I make some incorrect modification to the source source?
 
Last edited:
I downloaded the TFS 1.5 source, compiled it and tested it in game. No errors appeared, but I believe I made some changes to the source code, but I don't remember exactly what I moved

I'm going to have to add again from scratch some things I'm interested in like conditions and stuff. It's hard work, but thank you so much for your help.!
 
Last edited:
I downloaded the TFS 1.5 source, compiled it and tested it in game. No errors appeared, but I believe I made some changes to the source code, but I don't remember exactly what I moved

I'm going to have to add again from scratch some things I'm interested in like conditions and stuff. It's hard work, but thank you so much for your help.!
do you have conditions working like 7,72 cip? im looking for that u.u
 
Back
Top