replaced units for loops by event-based listing