Instantiate scene rotated and positioned toward nearest enemy

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Knight xaura

I have a scene that I would like to add to my player. This scene will be a child of the player.

On ready of the added scene I want this scene to rotate to face the nearest enemy (I have the list with the nearest enemy already setup). I want it to then to set itself out in that direction about 8px away from my players position

This isn’t going to pivot around me constantly, just when added to the current scene it will do a swing animation and then disappear. Just wanted to clarify that as I was able to find how to do this, but I wasn’t able to manipulate it for what I wanted of it.

Any help is appreciated.