Announcement

Collapse
No announcement yet.

[Help] Articulated Backhoe Simulator

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

    [Help] Articulated Backhoe Simulator

    Hello everyone, this is my first post here, so excuse me if i'm posting in the wrong place, and bear with me because its gonna be a long post, but i'm sure this will be useful for someone.

    I'm been working on this backhoe simulator quite some time and I was doing all the movement of the backhoe using SetRelativeRotation for the arms and AddActorWorldOffset for the translation of the backhoe itself.
    Doing in this way gave me a lot of control over the movement of the arms and the translation of the backhoe, but the sweep option in the SetRelativeRotation node its not implemented yet, so this gave a whole sort of troubles that I had to address and fix.

    Here is one of the problems that I was having:

    Click image for larger version

Name:	z0YLwu0.jpg
Views:	1
Size:	160.0 KB
ID:	1188833

    I manage to "fix" this overlapping by using the OnComponentBeginOverlap event to stop the movement if it hit the ground, but this gave me another problem:

    Click image for larger version

Name:	uBELiVM.jpg
Views:	1
Size:	98.0 KB
ID:	1188832

    This problem with the balls going through the shovel I wasn't able to fix yet, because if I use the same method above the shovel will stop its movement if it touch any balls, and that's not what I want

    So, I went from a total different approach: using Physics Constraints. I watched some youtube videos (there are only a few) on how to use and setup the constraints and create and setup my entire backhoe blueprint, here is the screenshots from the setup:

    Click image for larger version

Name:	AF11RRk.png
Views:	1
Size:	610.9 KB
ID:	1188834

    Click image for larger version

Name:	7JuzwtO.png
Views:	1
Size:	462.0 KB
ID:	1188835

    Click image for larger version

Name:	vlWW2Ap.png
Views:	1
Size:	391.0 KB
ID:	1188836

    Click image for larger version

Name:	o3lGush.png
Views:	1
Size:	280.3 KB
ID:	1188831

    After all the setup, I tried using AddTorque on the arm's components to implement its movements, but the arms were all loosen, like ragdolls arms, and was impossible to have total control of the arms. I wanted them to be stiff in place and only move when I wanted. So, after almos 3 days of trying all sorts of things I managed to almost acomplish it...yes, almost

    Here what I did: I disabled the gravity on all the components of my blueprint that belonged to the arm of the backhoe, I changed the center of mass of all the arm's components to be exaclty where their physics constraints was.
    On the physics constraints I did: configured the angular limits accordingly, enabled Angular Orientation Drive, with the Angular Orientation Target to (0, 0, 0) with the Angular Position Strenght according to their respective components (Very high values, by the way).
    After all this, I managed to rotate my components by changing the Angular Orientation Target of the physics constraints in the Tick Event with the input from my joystick.

    So, what I mean by "almost acomplish" is that the physics interactions are still a bit strange, kinda "jittery" and if I push to hard on a surface, sometimes the arms goes crazy or even go through objects. I kindly ask you guys if someone can help me with this, or can point me to the right directions, because I can't even find related stuff online and there must be a way to do this efficiently.

    Thank you in advance, and sorry if I made some english mistakes.
    Last edited by Kalybio; 07-30-2016, 09:47 PM.

    #2
    I would suggest to not abandon kinematic approach and just expose couple of hidden features from c++. Yesterday I've seen that for example AddRelativeRotation and AddLocalRotation do have Sweep option in c++. It shouldn't be too hard to expose it.
    Youtube Channel

    Comment


      #3
      Originally posted by BoredEngineer View Post
      I would suggest to not abandon kinematic approach and just expose couple of hidden features from c++. Yesterday I've seen that for example AddRelativeRotation and AddLocalRotation do have Sweep option in c++. It shouldn't be too hard to expose it.
      Yes, AddRelativeRotation and AddLocalRotation have the sweep option in the blueprints too, but it says that its not implemented yet, so I assumed that this was true in the c++ too

      Comment

      Working...
      X