Selaa lähdekoodia

港口测试底图栅格json

huangchunxi 3 kuukautta sitten
vanhempi
commit
027f285ffa
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      src/main/java/com/ecnu/platform/test/TestPortGrid.groovy

+ 2 - 2
src/main/java/com/ecnu/platform/test/TestPortGrid.groovy

@@ -74,7 +74,7 @@ class TestPortGrid {
                 algBaseMapArea.setType("lane")
 
                 double xNext = xJobLane + k * gridInterval
-                if (xNext + gridInterval < widthJobLane){
+                if ((k+1) * gridInterval < widthJobLane){
                     for (int j = 0;j < 5; j++){
                         coordinateJobGrid += xNext + xUnitList.get(j) * gridInterval + ","
                         coordinateJobGrid += yNext + yUnitList.get(j) * heightJobLane
@@ -124,7 +124,7 @@ class TestPortGrid {
                 algBaseMapArea.setType("lane")
 
                 double xNext = xTrafficLane + k * gridInterval
-                if (xNext + gridInterval < widthJobLane){
+                if ((k+1) * gridInterval < widthTrafficLane){
                     for (int j = 0;j < 5; j++){
                         coordinateTrafficGrid += xNext + xUnitList.get(j) * gridInterval + ","
                         coordinateTrafficGrid += yNext + yUnitList.get(j) * heightTrafficLane