This is what I got:
//enemy AI
Vector2 toTarget{Vector2Subtract(target->GetWorldPos(), worldPos)};
toTarget = Vector2Normalize(toTarget);
toTarget = Vector2Scale(toTarget, speed);
worldPos = Vector2Add(worldPos, toTarget);
This is what I got:
//enemy AI
Vector2 toTarget{Vector2Subtract(target->GetWorldPos(), worldPos)};
toTarget = Vector2Normalize(toTarget);
toTarget = Vector2Scale(toTarget, speed);
worldPos = Vector2Add(worldPos, toTarget);
Looks good. Does it work properly?