event generator example