2 Replies Latest reply on Oct 10, 2008 5:44 AM by (Are_Eple)

    Linking an effect to the endpoint of a rotating object

    Level 1
      I want to link an effect (smoke) to the end of a rotating stick moving through the air. I've tried to link it to a null object inside the stick-comp, but that only gives me the null object's static coordinates from inside the comp (i.e. the smoke just stands still)...

      Does anyone know how this can be done?
        • 1. Re: Linking an effect to the endpoint of a rotating object
          A. Cobb Level 3
          Does the null need to be inside the nested comp? That gets a little more complicated than if you were to put the null inside the main comp, and parent it to the comp layer you otherwise had it nested inside.

          Having done that, you need to use the layer transformation functions. Supposing your null is named "Null 1":

          For 2D coordinates, you should use toComp():
          >myNull = thisComp.layer("Null 1");

          >myNull.toComp(myNull.anchorPoint)

          For 3D coordinates, use toWorld():
          >myNull = thisComp.layer("Null 1");

          >myNull.toWorld(myNull.anchorPoint)

          Personally, unless you want the smoke offset from the layer along its z-axis, I would dispense with the null and put a Point Control effect on the layer you want to target. The expression is similar:
          >myLayer = thisComp.layer("Stick");

          >myPoint = thisComp.layer("Stick").effect("Point Control")("Point");

          >myLayer.toComp(myPoint)