[Solved] How do you make some turrets?

Hi everyone i was curious if someone knows how to create some turrets that target specific targets while in close proximity

Here’s the setup :

image


Turret origin and centre are at the bottom of the turret, MarbleStart point is at the other end :


And here’s the code that moves the turret and fires the ball :

But instead of aiming at the mouse, use the target object closest to the turret.

I’ve never used it but looks there’s an extension for this purpose

Thx mate!
Your a life saver