Fixed various boss-related bugs which caused crashes

Fixes #131, #132, #133