Collison detection with polygon