Greetings all, I wanted to explore making a mod to handle water and I was wondering how the game calculates it and handles the physics for it. I haven’t looked into the game files yet or explored much of it, and as I work long hours in my day job I often don’t get time in the evening to peek into things. Has anyone else tried modding the water or ways to move it around? If so I would be happy to hear your experience on it. My questions are as follows:
Does it even calculate physics on it?
How does the game calculate the amounts? By liter, by gallon, or by some arbitrary unit?
Does it even calculate it as different units or as one mass?
I’ve found that there were a lot of issues reported here with water in A19, but nothing very recent. Anyone know of anything recent?
How well does the game handle conservation of mass?
Does the game do any calculations on thermodynamics in relation to heating/cooling water?
Any information would be very helpful, thank you in advance.
The water system is getting re-visited by the developers! It will hopefully solve most issues with maneuvering water and such, i have no insight on how the water currently works, but i’d suggest waiting till they make all the chages (assumable after two alphas)
water currently as far as i can tell only sees land, minable areas as objects it can’t go through. to prove this I recently found a coal deposit i wanted to dig up. However, to do this i had to dig down from the mine i currently had dug and through a small space of water for the fastest route. I thought i could build up a tunnel of sorts to block the water from coming into my mine and the water flat out ignored the tunnel and flooded my mine.
From what I tested, the water consider wall and blocks placed by the player as solid ONLY if they were there before the water started flowing.
I once started building a wall to stop the water from flowing, after it was already started, and it ignored the wall like a ghost. The same test, this time first building the wall, and then releasing the water, worked. The water was contained by the wall.
I would guess the water pre-calculate its flow and new resting position, so everything happening after it is figured out is ignored. That would be probably why mining and having the water flow at the same time causes bugs.
In my experience, all blocks are considered solid at the moment the water starts flowing. The only exception to this is placing blocks inside the water. This causes both the water and the block existing in the same space. When you mine the stone next to it, the water flows through the block as though nothing is there. For example:
The water flows perfectly well over the constructed part (made before allowing the water to flow towards it, but removing blocks next to the wooden walls (placed originally in the water) will flood the whole mine
this explains why placing a wall over a deposit in the water doesn’t prevent the water from spilling into the mine after digging up the deposit and digging a hole into where the water would have been prior the wall being built…that’s annoying
Thank you all for the insight, I have only recently been playing Stonehearth and it’ gotten me hooked more than most games have in the past couple years. I think I’ll go ahead and build the models and animations for the mod now and wait for the water rework to take place before attempting any coding on it. This will be my first mod and it’s comforting to know I can ask a supportive community for advice and help if I hit a road block.