Hello I want to achieve this:
I have turrets that player can create with a radius, turret body and a turret part that rotates when any monster is near and shot him. (in a future will add line of sigh but first need this to work).
-Turrets must select an objective when monster enter in his radius and won't leave it until monster dies or monster leaves from radius
-Turret will only shot and rotate in direction of objective
-(Later will add line of sigh to objective)
-Also need to fix that turret rotate instantly to monster, maybe saving actual angle and new angle and then slowly substract?
I dont know what i'm doing wrong need some help, here is an example of my code, thanks!