Announcement

Collapse
No announcement yet.

Boat driving

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Boat driving

    First time I am considering to make some boat racing project, I have made car and motobike projects, but how can i get boat or ship to move in water, I mean if i add boat if goes immediately bottom of lake/ocean, some physic stuff, but not know how to start

    #2
    You'll have to implement your own physics simulation for water as its not really handled by default.

    Start off by splitting it into the basics. What does a boat do? It floats. Floating is buoyancy. Watch a tutorial on how to implement object Buoyancy: https://www.youtube.com/watch?v=kkxJeyG2whw

    After that, you should be able to figure out how to affect it so it moves depending on player control, such as manually setting its velocity or adding torque/physics rotation/impulse, using thrusters, etc, depending on what key the player presses.

    Or you can watch a tutorial on how to make hovering vehicles using raycasts from wheel positions or whatever, and just make it so it raycasts to hit the water plane and thats where the model should be, etc. You can go as simple or complex as you'd like, keeping in mind truly realistic/real-world accuracy hydrodynamics in terms of it being a freaking ocean ship navigation simulator requires a degree in hydrodynamics and a large team of programmers; coming from someone who used to work at Kongsberg Maritime simulation used by government agencies where the simulations had to be as realistic as possible (I was a modeler, not a programmer though for that job).

    But game physics should be easy enough for boats that float by following the above tutorial, thinking about how people implement hovering vehicles in games, etc. Alot of vehicle physics in games are basically raycasts from a physics object, from hovering cars to cars to boats. The raycasts determining where to place wheels, how much force to apply in the opposite direction of the raycasts hit point to keep the vehicle upright, etc.

    Best of luck!
    Last edited by Deathstick; 07-10-2017, 01:05 AM.
    Indie Dev - Whiskey Cat Softworks
    Currently developing a colony survival game!

    https://twitter.com/WSoftworks https://www.facebook.com/WhiskeyCatSoftworks/

    Comment


      #3
      You should reconsider this idea. Or at least do serious research first. There is one huge problem with unreal, currently it cannot produce nice water sharder.
      So i strongly suggest working on water shader first, if you get result that you are happy with you may proceed with physics of water.

      Comment


        #4
        thanks for advices, not usually buy marketplace, but there is good looking water asset where is easy to add like boat etc: https://www.unrealengine.com/marketp...-water-surface need only make boat controls, that asset looks good but not no will it make things easier

        Comment


          #5
          and if someone has working boat to unreal water, can pay it for some money

          Comment


            #6
            Originally posted by tero83 View Post
            and if someone has working boat to unreal water, can pay it for some money
            A bit late but here is a link https://www.unrealengine.com/marketp.../drivable-boat

            Comment


              #7
              Originally posted by tero83 View Post
              First time I am considering to make some boat racing project, I have made car and motobike projects, but how can i get boat or ship to move in water, I mean if i add boat if goes immediately bottom of lake/ocean, some physic stuff, but not know how to start
              For movement forward, TaskPawn is an Actor or a Pawn, e.g. a blueprint with a boat mesh. The actor mesh is aligned to the X axis. This example here works without possessing the pawn.
              Click image for larger version  Name:	brotation.jpg Views:	0 Size:	152.0 KB ID:	1691871

              Movement, rotation, rotates the boar actor, or pawn

              Click image for larger version  Name:	brotation2.jpg Views:	0 Size:	174.4 KB ID:	1691872

              Optional calling an interface (added to Player Character and PC AnimBP), to set dedicated boat animation
              Click image for larger version  Name:	optional1.jpg Views:	0 Size:	161.3 KB ID:	1691875Click image for larger version  Name:	optional2.jpg Views:	0 Size:	184.9 KB ID:	1691876Click image for larger version  Name:	optional3.jpg Views:	0 Size:	152.2 KB ID:	1691873Click image for larger version  Name:	optional4.jpg Views:	0 Size:	154.0 KB ID:	1691874
              [LEGENDS of EPICA][Twitter][FB][YT][Vimeo][Reallusion Technical Expert]

              Comment

              Working...
              X