merged init and init_noevent, moved it in a more visible place