How do I make my boat float on water?

So I have a boat, which is a model inside a model which has other models inside it. This is a large boat, but I want it to float on water. How would I make this boat float on water? I have heard about using body positions, but where would I insert them? Would I need to weld all the parts together?

4 Likes

Considering you’re making a boat, yeah, you’d need to unanchor your boat and weld the parts together to have them physically simulated and adhere to water. As far as making them float, that should be done automatically. Consider looking at the CustomPhysicsProperties of each part if you need the boat to stay above water, specifically density.

There’s a couple of topics related to boats working with terrain water that you can see here:
https://devforum.roblox.com/search?q=water%20density

If you aren’t working with terrain water, you’ll need to handle buoyancy yourself. There’s a thread on that as well that’s been solved which may help you:

7 Likes

I don’t think just unanchoring and welding is gonna make them float. I think it might just sink.

2 Likes

That’s where the rest of my response comes in.

  • Address the density of the boat and the CustomPhysicalProperties of the boat
  • Calculate custom buoyancy for non-terrain-water boats

Body forces can’t be used with anchored assemblies because they’re part of simulated physics on Roblox, they can only be used with unanchored assemblies. All boats on Roblox that aren’t rigidly handled with CFrames are handled by unanchorage and welding, especially if body forces are involved.

4 Likes

Would it be easier if I used body position?

2 Likes

BodyPosition is a body force. It’s intended to apply a force so that a certain assembly keeps a constant position over a certain coordinate. You’re welcome to use it so long as you’d also like to calculate custom buoyancy regardless of usage of terrain water, states in which the boat should be floating and states in which the boat should be moving. Essentially; handling the majority of boat physics yourself.

1 Like

What is the best option do you think.

1 Like

I don’t quite work with boats nor is this my project, so I can’t really say anything about that. Boat floating is fairly context dependent and can differ from game to game.

I presented what I knew about the topic in the first post, so it’s up to you to test or search around for anything that might help. There are quite a few topics about boat floating here.

1 Like