I want an AI that will move my NPC towards the target but avoid obstacles in its path they may be moving .Please tell me who can get started for it
I think RayCast would be a good way to start with your problem.
void Update()
{
Vector3 fwd = transform.TransformDirection(Vector3.forward);
if (Physics.Raycast(transform.position, fwd, 10))
{
print("There is something in front of the object!");
}
}