Fixed a bug, made code slightly neater, added rudimentary support for wools