After Effects is a motion graphics compositing software that can also produce puppet animation, as well as animate photographs and produce video effects.
The most complex effects are efficiently produced using Javascript.
It is good for multi-layered short clips in high definition. Also rotoscoping plug-ins.
For longer video editing eith fewer layers use Adobe Premiere.
For lower resolution animation and line animation use Adobe Animate or TVPaint.