Creating Christmas Tree-Shaped Lights with Basic Effects

Опубликовано: 30 Июль 2026
на канале: After Effect Recipe
791
25

You can change the colors to suit your preference and adjust the amount of particles.
To smooth out the sharp movements as it rotates upward, extend the duration. :)

Here is the expression script used in this recipe.

compCenter = [thisComp.width / 2, thisComp.height / 2];
layerPos = thisComp.layer("Null 1").toComp([0, 0, 0]);
(layerPos[0] - compCenter[0]) / thisComp.width;


compCenter = [thisComp.width / 2, thisComp.height / 2];
layerPos = thisComp.layer("Null 1").toComp([0, 0, 0]);
(layerPos[1] - compCenter[1]) / thisComp.width;


compCenter = [thisComp.width / 2, thisComp.height / 2];
layerPos = thisComp.layer("Null 1").toWorld([0, 0, 0]);
zPosition = layerPos[2];
zOffset = 540;
normalizedZ = (zPosition + zOffset - compCenter[1]) / thisComp.width;






#AfterEffects #Particle #Christmas