Bugfixes and new custom events