Bugfixes and tweaks from 2nd competition