So i want to make a sail boat actully sail! My plan is to make the wind a gameobject and then raycast towards the sail of the sail boat and give the player the ability to rotate the sails.
But what i am wondering is if there are a better way to do this or if you have another and more effektiv way.
You could take the dot products of the wind, sail and boat direction to create a force vector and apply it to the boat’s rigidbody using AddForce().
Raycasts would only be necessary if you was creating a boat simulator where the user could create/model their own boat and then test to see how it performed.
I found and used (for my Pilot Kurt game) a really cool airplane physics package designed to make real airplane flight in Unity. You simply define wing airfoils: wings, stabilizer, tail, fuselage, sail, whatever.
A sailboat sail is just a vertical airfoil after all.
You would need to model the dynamic keel force, which is the opposite force that keeps a sailboat actually tracking forward rather than just blowing sideways with the wind.
And you’d need the uprighting force of the keel ballast playing against the buoyancy of the hull… honestly it sounds like what you’re attempting is totally within reach with these parts. I’d be curious to see how you get along with it!!
You beat me to it! Awesome… I only made that boat video above then set it aside. I will go back and see how that sailboat thing works. Did you just make a single vertical airfoil? Tell us all about it!!!
So i did try 2 sails/foils but i found out that i becomes quit wierd at that part my boat started bugging out a’lot specially when you hit something. Sometimes it just flew away from no where, i recomend only going with one else it becomes hard to make it work. I never tried to space them out which i should probely try when i get to it.
I also tried to make a speed boat that uses the foils as hydro foils, it did not work at all my guess is that the water you use needs to help the boat generate lift. The hard point is to truly simulat wind you actully need to take in to account alot more then a normal person thinks.
Okay as you can see in the image these are the simple and basics sailing types and how you should position the sail. To give more insight sailing is all about chatching wind but what many people get wrong is that when you sail you only rotate your sails and thats wrong. Sail boats have the ability to tighten the sails which we want to do when sailing in option 3 and 2 you can see the numbers in the picture. But when sail in option one we wont to losen up the sails to catch more wind, and this is where the hard point of making sailing come to life with programing.
You could make a big 3D sail billowed left and right with a Blendshape.
With another blendshape you could go from the middle to a rippling luffing effect.
Then when the sail builds angle relative to inbound wind it fills up, when you let out the sheet it just luffs and wiggles in the wind, mostly flat looking…