added beat listener to lua api