Fixed bug with new event system