update rotate script