Add a motion gem check.
Restructure a bit.