Announcement

Collapse
No announcement yet.

Rotation problem . . .

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

    #16
    Wow I did not know about that draw debug coordinate system node. I have been manually drawing all 3 lines every time I do this kind of thing.

    Anyways, the GetPosition value from an actor variable should just work. Works perfectly fine here.

    The selected actor is the BP that does the rotation stuff. The colorchart mesh is just a regular mesh in the world with no BP script:
    Click image for larger version

Name:	Rot_01.JPG
Views:	1
Size:	36.2 KB
ID:	1090915

    Colorchart mesh is referenced by the other BP as actor reference:
    Click image for larger version

Name:	Rot_02.JPG
Views:	1
Size:	14.8 KB
ID:	1090916

    Changing angle causes mesh reference to rotate around an axis perpendicular to the vector between the actors:
    Click image for larger version

Name:	Rot_03.JPG
Views:	1
Size:	24.0 KB
ID:	1090917

    My script looks the same as yours:
    Click image for larger version

Name:	Rot_04.JPG
Views:	1
Size:	160.0 KB
ID:	1090918
    Last edited by RyanB; 10-07-2015, 01:05 PM.
    Ryan Brucks
    Principal Technical Artist, Epic Games

    Comment


      #17
      i wrote this script inside my PLAYER_BLUEPRINT
      is it correct?
      and my "dish" mesh is inside a blueprint actor.

      Comment


        #18
        You need to debug to see what is going wrong at this point. Your math looks the same so something about your vectors or actor locations is not working as expeted. Do draw debug sphere on all your locations to make sure they are right.
        Ryan Brucks
        Principal Technical Artist, Epic Games

        Comment


          #19
          Ok i found the problem...i used a normal " vector*vector " instead " CROSS PRODUCT " ( you can see from the pics i sent before... my have ADD PIN your NOT
          Now work perfectly ... i'll check better for be sure.
          So Ryan...what can i say... thank you so much for your help and time spent. You are so helpful.
          Thank you.

          Comment


            #20
            oh man I feel your pain... those nodes are way too similar looking. I remember complaining about that a while but but not sure what happened to that bug report... Glad it is working now!
            Ryan Brucks
            Principal Technical Artist, Epic Games

            Comment


              #21
              Originally posted by RyanB View Post
              oh man I feel your pain... those nodes are way too similar looking. I remember complaining about that a while but but not sure what happened to that bug report... Glad it is working now!
              Ok so first of all, I wasn't sure if it was a good idea to dig up an old thread rather to start a new one but I'm going with digging it up... Secondly, thanks a bunch for this! It got me a few steps closer to getting what I need - a rotation system where I can rotate an object around its own 3 local axes.. so each axis will rotate all axes (as opposed to a gimbal coord system etc).

              So I've done this setup, I just adjust the 'pitch', 'roll' and 'yaw' variables and watch it rotate. It's not quite working as I expected though, am I close here?
              Attached Files

              Comment


                #22
                I was wondering if I needed to be more descriptive of my request.. the idea would be that I have a e.g spaceship in 3rd person top down view. I want to rotate yaw, pitch and bank correctly at all times, meaning each of those axes are always lined up correctly with the ship, so bank will always bank no matter what yaw and pitch does.

                Thanks!

                Comment

                Working...
                X