Improved script support