Replace sprite hack with proper selection rectangle