Adds event on ready and setMethods method