Modified BD script.