Updating function and setting up opt.fourthking