improved glass effect, and some bug fixes