How to Reduce Decal Stretching?

I think it’s not quite straight.

What’s your code for aligning the decal with the object?