Made rotate a full-functional script