Moving to AI is not really a solution, to be honest. You're still stuck with arranging the faces after the fact and the usual issues with precision, the bounding box of the layers complicating the math and potential further mayhem due to continuous rasterization/ collapsed transformations. It's going to be just as complicated as navigating the pre-comps created from the script. All that being the case, the only honest answer here is to move on to a genuine 3D program where this could be as easy as creating the polyhedron, exploding it into its separate polygons and create a per-poly UV map to which then individual textures can be applied. Still a ton of work for the higher power shapes, but at least doable in a realistic way without growing a beard over it. Of course the basic tetrahedron, cube and and octahedron should be doable in AE, but anything beyond that will be a nightmare to deal with in AE, no matter which approach.
I am not, nor should anyone really, move to a new piece of software, especially one that's not free, and then have to deal with the entire learning curve of a completely new thing, to do one project.
I found a tutorial on how to apply the faces, here: https://www.youtube.com/watch?v=QVCIW-NtPpI So I'm halfway there now. I'm stuck on something much simpler, though: AE by default, centers the anchor point of something, via its bounding box. For triangles, that obviously doesn't work if you're trying to rotate the triangle.
I need the anchor point to be the actual centroid of the triangle.
I'm sure I'm missing something dead simple that would do this...
There's nothing simple about calculating centroids. A simple triangle can have multiple centers - center of mass, intersection of its perpendiculars, weighted distance from edge, circumscribed center and so on. Some of them typically coincide, others do not. Not trying to be a stiffler about the math, but depending on which method you employ, you could end up with a veritable mess. And since in AE you still would need to account for 3D rotations due to that Euler vs. Quarternions thing, it would be a major clusterduck. At least for the latter part you would most definitely want to rotate around one of the polygon's edges or a corner point, not the actual center. That would also have the benefit that your polygons in the pre-comps would retain predicatable upright orientation for adding the textures. Point in case: You need to treat this like a folding map, not a polygon generation algorithm and refactor the math to account for this. Otherwise I guess the nab script is as good as it gets and you have to put up with its shortcomings and quirks.