- October 4, 2013 at 3:07 pm
Working on an animated blowfish in After Effects and wanted to see if someone had a quick and dirty solution for parenting his spikes’ position to his toro’s scale. Basically, as his body puffs out I’d like the spikes to stay near the edge of it without having to keyframe the position of each, while maintaining their original size (since simply parenting would scale the spikes up as well.
I know there’s probably an expression out there, but I haven’t the foggiest on where.
Thanks in advance!
Motion Graphics & Animation
- October 4, 2013 at 7:31 pm
It’s a cartoony blowfish (Illustrator file). He doesn’t need volume, he’s just going to grow a bit and then I’ve got two subsequent character models of him more and more swelled up. I was thinking it’d just be nice to have his body well up a bit and then begin to expand without scaling the spikes themselves.
How would I do it in C4D out of curiosity (if that would work better)?
Motion Graphics & Animation
- October 4, 2013 at 8:27 pm
Depending on the look of the blowfish I would use nulls parented to the blowfish’s body, then use the compTo expression to tie the spikes to the nulls. I made a quick experiment to try it out.. and thought it looked better when I added a bit of increase of scale to the spikes.
I’ll just attach my li’l project for you!
Maybe there is an expression free way of doing this as well?
- October 4, 2013 at 8:44 pm
i’m not entirely clear on how you have things set up currently, but i think if you were to simply parent the spikes to the body, then scale the body, the spikes would stay in position relative to the body, correct?
but you’d like it if the spikes moved with the body as it scaled, but not scale themselves — or the scaling remained in dependent of the body?
if that is the case then you could try an expression like this to ‘cancel out’ the parent scale:
xScale = value/parent.scale;
yScale = value/parent.scale;
with that expression, after the spikes are parented to the body, as the body scales up, the spkes will look like the stick to the body, but the scale will remain the same. you can still animate the spikes’ scales if separately if needed.
KCPQ, KMYQ & KRCW
- October 5, 2013 at 8:56 am
When I woke up this morning, I had a simpler solution for this!
Delete the nulls. *You noticed my layers where all different colours? That way I can click the colour, and select label group, delete all nulls in one go.. or select all spikes etc!)
Parent spikes to body and apply this expression to the scale
- February 12, 2015 at 9:55 am
I have a similar problem, and this looks like a good script for me, but I couldnt make it work.
I put your script on scale on the child layer and got this message:
After Effects warning: an expression was disabled as a result of an error.
Error at line 3 in property ‘Scale’ of layer 12 (‘tak’) in comp ‘comp name’
invalid numeric result (divide by zero?)
Would you know why?
Log in to reply.