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

Lua Liquid problems.

Exoltes

Novia OTserv Developer
Joined
Jul 2, 2009
Messages
563
Reaction score
47
Location
Belgium
I'm working on a 8.54 Open Tibia Server using The Forgotten Server - Version 0.2.7 (Mystic Spirit).

When I add containers with liquid in to my server with my map editor they almost always appear different in my server. Further when i try to use for example an empty bottle on a water source I keep getting the message 'it is empty', below in my screen.

I've checked within my items.xml. Also tried and change things to be corresponding with my
Server\doc\LIQUIDS file.

So atm I'm quite running out of idea's to fix this, but it is rather an important part to an rpg server so if someone has a clue why this doesn't work or how to fix it, that would be nice.

Thanks in advance.
 
Can you give examples with itemids and scripts?
The LIQUIDS file in the folder doc is an information file, it has no effect on what you have in your datapack.
 
May I ask why you chose to work with an 8.54 distro instead of a newer distro, lets say, 8.6 (that has potentionally less bugs)?
 
For example when I create the item Trough in game (/i 1775) I get a trough filled with water.

When I try to put this water in a bottle
14:20 You see a blue bottle. It is empty.
It weighs 2.50 oz.
ItemID: [2007].

I only get the msg 'It is Empty'.

Also for example when I try to make bread (Use flour on a water source).
Code:
    <action itemid="2692" script="other/createbread.lua"/>
Code:
local liquidContainers = {1775, 2005, 2006, 2007, 2008, 2009, 2011, 2012, 2013, 2014, 2015, 2023, 2031, 2032, 2033}
function onUse(cid, item, fromPosition, itemEx, toPosition)
    if item.itemid == 2692 and isInArray(liquidContainers, itemEx.itemid) == TRUE and itemEx.type == 9 then
        doChangeTypeItem(item.uid, item.type - 1)
        doPlayerAddItem(cid, 2693, 1)
        doChangeTypeItem(itemEx.uid, item.type - item.type)
    else
        return FALSE
    end
    return TRUE
end
Nothing happens.
 
The script fluids.lua works that you can fill them based on ground ids, like sea water.
If you want to use an empty vial on a through with water to fill it with water, add that itemid + itemtype to the ground ids line.
Code:
or (itemEx.itemid == 1775 and item.type == 9)

The createbread script works fine for me.
Did you added it on a vial/fluid container with water?
 
Yea, I tested it with a filled container but probbably the problem will be within the 'fluids.lua', forget to check that file xD
 
Yea, I tested it with a filled container but probbably the problem will be within the 'fluids.lua', forget to check that file xD
Most likely it is the "fluids.lua" file that is causing problems for you, if you still cant seem to fix it I recommend you to change distro to a newer one, with that being said you should only do this if you're not too far ahead on your server and feel that would be beneficial, less bugs in the long run.
I remember working with an 8.6 server and I had so many bugs that I just quit working on it and now I finally grabbed a new distro and I havent encountered a single bug yet.

REMEMBER: You can always downgrade your distro by changing spells, exhaust and lots of other things, I usually do this and it works great (includes more choices aswell)
 
Last edited:
Problems in the datapack (data folder) are easy to solve, changing the server for a different datapack won't be needed.
Only reason when it's good to choose for a different server is if you want a different client version or the features that server has to offer.
 
Yeah but as I said in the previous post, too many follow up bugs can be too much to handle sometimes, like I've myself have experienced, ofcourse everything can be fixed, especially if you have sources too, then absolutely everything can be solved, but I only recommended a change if he feels it becomes too much. (Some servers are worse than others when it comes to bugs)

He should continue using the distro if he does not feel it is beneficial to change it.
 
Back
Top