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

TFS 0.X [OTX2]Default Ring Equipped error

potinho

Advanced OT User
Joined
Oct 11, 2009
Messages
1,403
Solutions
17
Reaction score
151
Location
Brazil
Good afternoon people,

I discovered a bug on my server, I believe it's not the client, because with the custom rings I have (and which are infinite) the problem doesn't happen, I'll leave an example:

If I log out with a Ring of Healing equipped (but it can also be a Life Ring, Power Ring, etc.) when I log back into the game it comes back bugged, without the glow. If I try to pull it into the backpack, it shows that it is not possible. If I put a custom ring (which is infinite, the only difference for it), the bug doesn't happen.
1700943513140.gif

If I die with the RoH bug, my character also doesn't fall to the ground, and it looks like the image below:
1700943661395.png
The following error messages appear in the OTClientv8 log file:
C++:
ERROR: no thing at pos:160 53 7, stackpos:1
at:
    [C++]: ?getMappedThing@ProtocolGame@@QAE?AV?$shared_object_ptr@VThing@@@stdext@@ABV?$shared_object_ptr@VInputMessage@@@3@@Z
ERROR: no thing
at:
    [C++]: ?parseTileRemoveThing@ProtocolGame@@AAEXABV?$shared_object_ptr@VInputMessage@@@stdext@@@Z

ERROR: no thing at pos:163 54 5, stackpos:2
at:
    [C++]: ?getMappedThing@ProtocolGame@@QAE?AV?$shared_object_ptr@VThing@@@stdext@@ABV?$shared_object_ptr@VInputMessage@@@3@@Z
ERROR: no creature found to move
at:
    [C++]: ?parseCreatureMove@ProtocolGame@@AAEXABV?$shared_object_ptr@VInputMessage@@@stdext@@@Z
WARNING: attempt to destroy widget 'widget1227' two times
 
Last edited:
show me health ring from items.xml
Post automatically merged:

Lua:
function onLogin(cid)
local ringsfix = {
[ITEMID] = {change = ITEMDTOID},
}
local ring = ringsfix[getPlayerSlotItem(cid, 9).itemid]
if ring then
    doTransformItem(getPlayerSlotItem(cid, 9).uid, ring.change)
end
return true
end

this is working i tested to my tfs 0.4 is working but not is the best solution
Post automatically merged:

add register event in creaturescripts.xml and login.lua
 
Last edited:
show me health ring from items.xml
Post automatically merged:

Lua:
function onLogin(cid)
local ringsfix = {
[ITEMID] = {change = ITEMDTOID},
}
local ring = ringsfix[getPlayerSlotItem(cid, 9).itemid]
if ring then
    doTransformItem(getPlayerSlotItem(cid, 9).uid, ring.change)
end
return true
end

this is working i tested to my tfs 0.4 is working but not is the best solution
Post automatically merged:

add register event in creaturescripts.xml and login.lua
Unnequiped
XML:
    <item id="2214" article="a" name="ring of healing">
        <attribute key="weight" value="80"/>
        <attribute key="slotType" value="ring"/>
        <attribute key="transformEquipTo" value="2216"/>
        <attribute key="stopduration" value="1"/>
        <attribute key="showduration" value="1"/>
    </item>

Equiped
XML:
    <item id="2216" article="a" name="ring of healing">
        <attribute key="weight" value="100"/>
        <attribute key="decayTo" value="0"/>
        <attribute key="transformDeEquipTo" value="2214"/>
        <attribute key="duration" value="450"/>
        <attribute key="healthGain" value="50"/>
        <attribute key="healthTicks" value="3000"/>
        <attribute key="manaGain" value="50"/>
        <attribute key="manaTicks" value="3000"/>
        <attribute key="showduration" value="1"/>
        <attribute key="showattributes" value="1"/>
    </item>

All buggy rings have decayTo parameter, infinite rings have no problem. Im guessing maybe a problem with this function.

After use your creaturescript, its impossible to log in, im falled into a loop with this error:

2023-11-25 23:24:21 - [Error - CreatureScript Interface]
2023-11-25 23:24:21 - data/creaturescripts/scripts/ringfix.lua:eek:nLogin
2023-11-25 23:24:21 - Description:
2023-11-25 23:24:21 - data/creaturescripts/scripts/ringfix.lua:3: table index is nil
2023-11-25 23:24:21 - stack traceback:
2023-11-25 23:24:21 - data/creaturescripts/scripts/ringfix.lua:3: in function <data/creaturescripts/scripts/ringfix.lua:1>
 
Lua:
function onLogin(cid)
local ringsfix = {
[2214] = {change = 2216},
}
local ring = ringsfix[getPlayerSlotItem(cid, 9).itemid]
if ring then
    doTransformItem(getPlayerSlotItem(cid, 9).uid, ring.change)
end
return true
end

You changed ids?
 
Lua:
function onLogin(cid)
local ringsfix = {
[2214] = {change = 2216},
}
local ring = ringsfix[getPlayerSlotItem(cid, 9).itemid]
if ring then
    doTransformItem(getPlayerSlotItem(cid, 9).uid, ring.change)
end
return true
end

You changed ids?
Putted now, still not working. No errors on console.

GIF 26-11-2023 08-02-53.gif
 
have same problem with soft boots? or only with rings?
Post automatically merged:

i found this from old problems. fix this error with this
Look in creaturescripts for scripts with type login, it can also be in mods.
Then look for this
Lua:
doRemoveConditions(cid, false)
Change it to this
Lua:
doRemoveConditions(cid)

If it isn't removing a certain condition from an event that it should after changing this, you can remove it by removing that specific condition.
Example:
Lua:
if getCreatureCondition(cid, CONDITION_OUTFIT) then
doRemoveCondition(cid, CONDITION_OUTFIT)
end
 
have same problem with soft boots? or only with rings?
Post automatically merged:

i found this from old problems. fix this error with this
Look in creaturescripts for scripts with type login, it can also be in mods.
Then look for this
Lua:
doRemoveConditions(cid, false)
Change it to this
Lua:
doRemoveConditions(cid)

If it isn't removing a certain condition from an event that it should after changing this, you can remove it by removing that specific condition.
Example:
Lua:
if getCreatureCondition(cid, CONDITION_OUTFIT) then
doRemoveCondition(cid, CONDITION_OUTFIT)
end
I have none script with
Lua:
doRemoveConditions
.
1701001612943.png

And this seems to be happens just for rings, Soft Botos get no visually bugged. But I found something even stranger that has now blown my mind:

I noticed that when I die and lose my backpack (with the soft boots equipped or i relog) I lose the items and fall to the ground normally. If I go back, pull the backpack into the correct slot and die again, the character stops falling to the ground when I die.
1701002238593.png

Character seems totally bugged, after restart server it back falling in the ground and when i relog and ring get bugged, its impossible throw it in any place, just replacing by another ring.
 
Last edited:
Back
Top