bool PSPlanner::collide()
{
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().lrx(), this->cc().lry(),
+ this->ps().x1(), this->ps().y1(),
+ this->ps().x2(), this->ps().y2()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().rfx(), this->cc().rfy(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x1(), this->ps().y1(),
+ this->ps().x2(), this->ps().y2()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().rfx(), this->cc().rfy(),
+ this->ps().x1(), this->ps().y1(),
+ this->ps().x2(), this->ps().y2()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lrx(), this->cc().lry(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x1(), this->ps().y1(),
+ this->ps().x2(), this->ps().y2()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().lrx(), this->cc().lry(),
+ this->ps().x2(), this->ps().y2(),
+ this->ps().x3(), this->ps().y3()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().rfx(), this->cc().rfy(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x2(), this->ps().y2(),
+ this->ps().x3(), this->ps().y3()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().rfx(), this->cc().rfy(),
+ this->ps().x2(), this->ps().y2(),
+ this->ps().x3(), this->ps().y3()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lrx(), this->cc().lry(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x2(), this->ps().y2(),
+ this->ps().x3(), this->ps().y3()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().lrx(), this->cc().lry(),
+ this->ps().x3(), this->ps().y3(),
+ this->ps().x4(), this->ps().y4()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().rfx(), this->cc().rfy(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x3(), this->ps().y3(),
+ this->ps().x4(), this->ps().y4()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lfx(), this->cc().lfy(),
+ this->cc().rfx(), this->cc().rfy(),
+ this->ps().x3(), this->ps().y3(),
+ this->ps().x4(), this->ps().y4()
+ )))
+ return true;
+ if(std::get<0>(intersect(
+ this->cc().lrx(), this->cc().lry(),
+ this->cc().rrx(), this->cc().rry(),
+ this->ps().x3(), this->ps().y3(),
+ this->ps().x4(), this->ps().y4()
+ )))
+ return true;
return false;
}