Rewrite player movement functions