# AI SetFocus Instantly snap rotate to location (How to make it rotate smoothly?)

**URL:** <https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219>\
**Category:** AI\
**Tags:** ai-navigation, ai-controller, unreal-engine, Blueprint, question\
**Created:** [May 19, 2019, 12:33pm UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219 "2019-05-19T12:33:44Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![dinasorZ](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@dinasorZ](https://forums.unrealengine.com/u/dinasorZ)\
**Post date:** [May 19, 2019, 12:33pm UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219/1 "2019-05-19T12:33:44Z")

</div>

When I Set New Focus, the AI Instantly snap rotate to the focused location… Any Idea how to make it smoothly rotate to the new focused location?

Thank you in advance.

---

<div class="post-metadata">

**Author:** ![NorlinGames](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/norlingames/32/495614_2.png) [@NorlinGames](https://forums.unrealengine.com/u/NorlinGames)\
**Post date:** [May 19, 2019, 3:09pm UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219/2 "2019-05-19T15:09:20Z")

</div>

There is no built-in smooth rotation (not in the same way as SetFocus is working), but it’s not complex to implement:

- Instead of Set Focus, just save the target location in a variable
- In a tick, calculate the desired rotation from your location and target location
- use the RInterpTo node for smooth rotation

Here is the good video about how to use this node: [WTF Is? Interpolation - RInterp Node in Unreal Engine 4 - YouTube](https://www.youtube.com/watch?v=yoKJMhgSxmU)

---

<div class="post-metadata">

**Author:** ![dinasorZ](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@dinasorZ](https://forums.unrealengine.com/u/dinasorZ)\
**Post date:** [May 20, 2019, 6:56am UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219/3 "2019-05-20T06:56:10Z")

</div>

The problem of not using SetFocus is that (And maybe I’m wrong, except for the last reason which I’ve tested a lot):

- It’s not heavy on the system as  
RInterpTo that runs every tick.
- It have better syncing with multiplayer as it’s independent from  
frame tick.
- With SetFocus AI’s pawn always face the target while it’s moving, which  
uses the Movement Blendspace  
Animations that is based on Direction in the right way. Ex: with SetFocus AI  
will face player and move backward  
normally with the right backward animation,  
while with RInterp the AI will always play “forward”  
animation even if it’s moving backward

I’m thinking though of using RInterpTo/Ease before setting a new focus as a workaround, so for example when player shoot AI from behind the AI will first RInterp smoothly to player over Timeline, then after Timeline finishes I’ll set the new focus… I’m open for suggestions though if there is a better solution 🙂

---

<div class="post-metadata">

**Author:** ![NorlinGames](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/norlingames/32/495614_2.png) [@NorlinGames](https://forums.unrealengine.com/u/NorlinGames)\
**Post date:** [May 20, 2019, 7:06am UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219/4 "2019-05-20T07:06:41Z")

</div>

SetFocus is also use per-tick updates for tracking. Though not sure about network solution, it still should work with manual rotation.

You can use SetFocus along with lerping target location if you want to (just update the focus per tick), but probably it will be heavier than setting manual rotation.

Another workaround is to make an invisible Actor for targeting, call SetFocus to this actor just once, and update it’s location smoothly as you want to.

---

<div class="post-metadata">

**Author:** ![Swornh](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Swornh](https://forums.unrealengine.com/u/Swornh)\
**Post date:** [January 1, 2026, 9:51pm UTC](https://forums.unrealengine.com/t/ai-setfocus-instantly-snap-rotate-to-location-how-to-make-it-rotate-smoothly/449219/5 "2026-01-01T21:51:26Z")

</div>

This is the only thing you will ever need:

> **[Smooth Focus using AI SetFocus/SetFocalPoint | Community tutorial](https://dev.epicgames.com/community/learning/tutorials/ZYVB/unreal-engine-smooth-focus-using-ai-setfocus-setfocalpoint)**
>
> How to use Smooth SetFocus / SetFocalPoint on a Controller
