Fixed bugs with cursor range and physics