- Home /
Visual script graph causes NPC to 'glitch' (shudder) when facing Player
Firstly, I am not a coder. The best I can do is use assets and the occasional Bolt script graph. I am using a simple graph on an NPC which keeps the NPC facing the Player direction. This is to make it easier when the Player needs to have a conversation with the NPC (Dialogue System). The graph is an 'Update Event' node linked to a 'Transform Look At' node where the 'Target' is a 'Get Variable' node identifying the Player. This works ok but when the Player is in position the NPC can sometimes glitch and shudder as though caught between rotating or staying still. It's not game breaking but it is annoying. Can anyone tell me what I'm doing wrong please or is this a bug? EDIT: I should have noted that I'm using Unity 2021.1.14.
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613040331im_/https://answers.unity.com/themes/thub/images/avi.jpg)