use an event system for packets