Script loader updates

#optimization