Announcement

Collapse
No announcement yet.

How calculate vector after line by channel "hit normal"

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

    How calculate vector after line by channel "hit normal"

    Hi,

    I want move up character in fly mode parallel to wall like this picture, how calculate this vector?

    #2

    I would use a double cross product. A cross product between normalized trace vector and hit normal, then a cross product between the result and the hit normal. That should give you the direction vector (may need to multiply by -1 if it faces the wrong way).

    EDIT

    I am assuming the hit normal would be the result from the trace and should be perpendicular to your surface right?
    Last edited by craigBeads; 08-03-2019, 01:56 AM.

    Comment


      #3
      Sry I no reply but I still dont know how make this in blueprint. "I am assuming the hit normal would be the result from the trace and should be perpendicular to your surface right?" I just want move parallel with wall if character close to wall then change mode to fly and charckter move up

      Comment


        #4
        do a linetrace from your character capsule and then break the hit result of the linetrace, which will expose hit normal( which I think is the vector you need to start the double cross product). If you need more info on linetracing just type "mathew wadstein linetrace" into google.

        Comment

        Working...
        X