Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Camera flipping on rotation issue

Hey there, I had a similar question related to this issue, But this was a more specific problem.

What I'm doing: I've got an Actor blueprint which has a SpringArm and camera attached to it. I'm Rotating and setting its location to be at the center of both (2) players.

The Issue: When the Cameras actor rotation reaches a 90 or -90 degrees, the camera suddenly does a 180 flip. Video Showing the issue: https://youtu.be/jS8ntx04RNw

How can i get rid of this unwanted behaviour?

Thanks in advance! -SamuelB

Product Version: UE 4.17
more ▼

asked Nov 25 '17 at 09:21 PM in Using UE4

avatar image

283 9 19 22

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

I think there is a problem in using FindLookAt results, but this is really not a point.

For now you need to understand a logic of this camera setup.

Two characters can be on right and left side of a camera. For example, P1 on right and P2 on left. SpringArm location will be:

 (P1.location + P2.location)*0.5

Rotation can be calculated according to character's sides.

 RightVector = P1.location - P2.location
 CameraYAxis = Normalize(Vector(RightVector.x, RightVector.y, 0)

But here is one problem. What should happen if characters change sides? When P1 make some big jump and pass location of P2. In this case, with this math, camera will flip. Maybe not instant flip, but it will.

So... Camera rotation should depend on some right and left side, but it shouldn't depend on which character is on that side.

more ▼

answered Nov 26 '17 at 04:49 PM

avatar image

4.3k 81 19 104

avatar image Samuelb Nov 26 '17 at 06:52 PM

Hey, thank you redbox again for the answer. I'll give this a try and report back later.


avatar image Samuelb Nov 27 '17 at 12:13 PM

I Finally got it working! I Used the math you presented to get the correct answer, thank you so much =)!

Here is the final solution in blueprints.

alt text


(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question