The influence of success and failure experiences on agency