1. Create a shape, I made a circle
2. Add a Trim Paths to put the arrowhead at the end (you don't need this here and could set the location to anywhere along the path)
3. Add polystar to your shape layer, set points to 3 (for a triangle arrowhead)
4. On your polystar set position to
Code: Select all
var p = content("Group 1").content("Path 1").path;
var pnts = p.pointOnPath(thisComp.layer("Shape Layer 1").content("Group 1").content("Trim Paths 1").end/100,time);
pnts
5. On polystar set rotation to
Code: Select all
var p = content("Group 1").content("Path 1").path;
var tans = p.tangentOnPath(thisComp.layer("Shape Layer 1").content("Group 1").content("Trim Paths 1").end/100,time);
radiansToDegrees(Math.atan2(tans[1],tans[0])) + 90