You mean the turning-box-effect? I know how he did that: Used a physics-simulation he programmed himself, imported it into blender, and used neural networks to make the algorithm learn the best way to turn.
~"I never let school interfere with my education"~ -Mark Twain