bug fixes
Merge https://github.com/andykat/cowsandcows3