x

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 rotation does not update based on pawn when using Pawn Control Rotation

I'm working in an automatic reel based on a Spline, where a given component (a Mesh, for example) travels across that spline using both Get Location at Distance along Spline and Get Tangent at Distance along Spline, using the Location and the Rotation (calculated by using Make Rot from X on the tangent) as the new World Transform of that component.

The main player's Pawn is supposed to be attached to this component in first person mode, following its track. If I leave Use Pawn Control Rotation unchecked, everything happens as it should with the exception of not being able to look anywhere except the direction given transformation.

If I check that value (as I believe it should be), advancing along the Spline is not a problem and I can look around but there's a catch: my direction is not updated and I'm always "facing" the same way by moving in space without any kind of rotation.

Am I missing something obvious?

Product Version: UE 4.9
Tags:
more ▼

asked Feb 05 '16 at 07:23 PM in Blueprint Scripting

avatar image

† SG †
21 2 7 14

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

1 answer: sort voted first

This is just a simple mathematics ADDING your existing Rotator with the rotation you force by that track and the rotation you execute manually by input, isn't it?

So if you in example driving a circle facing straight away from the trail and you want to keep your viewpoint (result is the actual existing rotaion) you need to compensate the forced rotation manually (forced +x degrees added to manually -x degrees has to be 0, viewport stays in place). Thats what players feels like fighting against the movement rotaion in cars and stuff, right?

Sorry if I eventually got that wrong but I thinks this is what you are looking for.

more ▼

answered Feb 05 '16 at 08:32 PM

avatar image

te4zer
46 2 10

avatar image † SG † Feb 06 '16 at 01:57 AM

That's exactly where the problems come in. Adding rotations affects the pawn correctly but not the camera's orientation. This only works if I uncheck Use Pawn Control Rotation in the Pawn's Camera, but in that case my inputs do not affect the camera any longer and I can't rotate at all. That's why this thing is driving me nuts. The only way I can effectively turn the camera is by using the "Add control input" nodes.

avatar image te4zer Feb 06 '16 at 02:28 PM

Do you tried to Set Actor Rotation with your resulting Rotator ?

avatar image † SG † Feb 08 '16 at 03:16 PM

Yes, and the actor is rotated properly. The camera, however, is not altered at all.

(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