added event passing to the lua script