Add offset to look at rotation on tick

Hey all,

I’m attempting to face the camera toward an actor using Look At Rotation on tick so the camera is always looking at that actor, but I’m trying to figure how to add an offset to the camera rotation, so that it can look slightly to the right of the actor or slightly to the left of the actor etc.

I’ve tried out Add Actor Local Offset, but that just causes the camera to spin since it’s adding to the rotation every tick, I’ve also tried DeltaRot or CombineRotators to try converting the Look At Rotation to a relative rotation and adding the rotation offset to that relative rotation, but again it just causes the camera to spin.

Ideas?

so that it can look slightly to the
right of the actor or slightly to the
left of the actor etc.

This should do it for something simple even without inversing transforms:

The arrow is pointing 25 degrees to one side:

Image from Gyazo


Alternatively, Look At a specific vector rather than fiddle with rotations:

Here we’re finding a location that is 100uus to the target’s right. Note that the behaviour is now relative:

Image from Gyazo

As in, if the target was rotating, so it would its right vector:

Image from Gyazo


What to choose depends on the intended result.

1 Like

And if you’re translating something from relative → absolute or vice versa, look into rotation transforms:

353332-screenshot-3.png

.