Fixed wall bug when end position was less than start position