octacian wrote:Nice idea! Screenshot?
Hi, my username is azekill_DIABLO and i'm an exelent bug-maker(yeah...i know...i have a bad reputation)
texmex wrote:Hey FaceDeer, great to see this came into being!
texmex wrote:Is the 1.0 milestone the same as the "enforce buoyancy" feature?
FaceDeer wrote:No problem. Initially I was kind of at a loss for how to make this work, but then I had a head-slap moment: buckets can be used on water blocks, I could just look at how those do it. Turns out it's really simple. :) The bulk of this mod's work is just overriding all the node definitions belonging to "wood" and "tree" groups to add "liquids_pointable = true" to them. The specialized pontoon blocks are almost superfluous after doing that (aside from the lava-proof one, of course)
FaceDeer wrote:If you mean the thing we talked about in PM about pontoons rising to the surface and dragging the stuff built on them up with them, it's probably going to be a while before I get to it. Moving arrays of nodes around is hard work and for Minetest it'll be a bit of an edge case since water is normally pretty static (though I've done what I can to fix that :)). I mainly just called this version 0.5 because since it's the initial commit I'm sure there are plenty of unknown bugs and minor missing features that people are going to tell me about now that it's posted.
texmex wrote:Actually I wouldn't dare to dream that big for Minetest. My aim was the first step really, that the buoyant block rises to the surface if placed underwater with nothing other than water above it.
If another solid block is placed above half way to the surface it and then removed the realistic thing for it to do would be to continue to rise, but I know for that to happen a whole other taxing piece of code needs to run so that part is not justified in my opinion.
FaceDeer wrote:Oh, that. :) Yeah, that part isn't hard. I'll look into setting that up tonight. I'll probably want that behaviour to be pontoon-specific rather than applying to wood or trees, though, in case people want to build pilings or ocean-bottom wooden structures.
texmex wrote:I've noticed that falling nodes falls smoothly and not in block-sized steps. It would be so cool if this could be reversed for floatables, but I'm going to guess that's a hardcoded engine feature specifically written for falling blocks. Anyway, a non-smooth movement is fine too of course.
FaceDeer wrote:Actually, it's not hard-coded. Falling blocks turn themselves into entities, which move smoothly and then turn back into nodes again once they hit ground. I've never done the coding for that myself but I remember looking over some of it and it seemed simple enough, at least for nodes that don't have fancy metadata or inventories to worry about.
FaceDeer wrote:Before you ask, redoing Digtron to use entities like that would be rather a lot more complicated. :) There are a few mods I've seen out there that allow groups of nodes to move by fusing them together into one big entity, but the resulting object isn't capable of complex operations. It's just a big inert monolithic thing that looks like it's made out of a bunch of nodes.
FaceDeer wrote:I'll look into something like that for pontoons, though. If it works like I think it should the pontoon block would not actually be *built* when you tried placing it underwater, it would just spawn an entity that would move upward until it hit surface or obstruction and turned into the node at that spot.
FaceDeer wrote:As for sounds, I just grabbed the wood and metal defaults as an expeditious way to get the mod rolled out. If you know of a good freely-licensed hollow thud sound I could swap that in.
texmex wrote:Hey FaceDeer! I've tried the falling_extras mod and it could contain valuable code for forcing pontoons to float to the surface on placement.
I managed to create negative gravity with the mod simply by modifying this line as Wuzzy suggested was possible.
Here's how it behaved when gravity was negated.
+ Spoiler
Hi, my username is azekill_DIABLO and i'm an exelent bug-maker(yeah...i know...i have a bad reputation)
Users browsing this forum: No registered users and 40 guests