add condition for 0 planRoadDirection
This commit is contained in:
parent
371e60b3af
commit
80f083cf3a
1 changed files with 6 additions and 7 deletions
|
@ -533,18 +533,17 @@ public class BinaryRoutePlanner {
|
||||||
long fid = to.getRoad().getId();
|
long fid = to.getRoad().getId();
|
||||||
for (int i = 0; i < from.getRoad().getRestrictionLength(); i++) {
|
for (int i = 0; i < from.getRoad().getRestrictionLength(); i++) {
|
||||||
long id = from.getRoad().getRestrictionId(i);
|
long id = from.getRoad().getRestrictionId(i);
|
||||||
|
int tp = from.getRoad().getRestrictionType(i);
|
||||||
if (fid == id) {
|
if (fid == id) {
|
||||||
int tp = from.getRoad().getRestrictionType(i);
|
if (tp == MapRenderingTypes.RESTRICTION_NO_LEFT_TURN
|
||||||
if (tp == MapRenderingTypes.RESTRICTION_NO_LEFT_TURN ||
|
|| tp == MapRenderingTypes.RESTRICTION_NO_RIGHT_TURN
|
||||||
tp == MapRenderingTypes.RESTRICTION_NO_RIGHT_TURN ||
|
|| tp == MapRenderingTypes.RESTRICTION_NO_STRAIGHT_ON
|
||||||
tp == MapRenderingTypes.RESTRICTION_NO_STRAIGHT_ON ||
|
|| tp == MapRenderingTypes.RESTRICTION_NO_U_TURN) {
|
||||||
tp == MapRenderingTypes.RESTRICTION_NO_U_TURN) {
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
if (tp == MapRenderingTypes.RESTRICTION_ONLY_STRAIGHT_ON) {
|
||||||
if (from.getRoad().getRestrictionType(i) == MapRenderingTypes.RESTRICTION_ONLY_STRAIGHT_ON) {
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue