Fixes some rotation bugs