Phase 1 with GUI:

- Remove shuffle.
    - getShortestRout instead of best.
This commit is contained in:
HeshamTB 2021-01-01 00:33:26 +03:00
parent f4bc812f23
commit acff65eab3
Signed by: Hesham
GPG Key ID: 74876157D199B09E

View File

@ -65,7 +65,7 @@ public class MakkahCity {
generateCamps(District.ALMANSOOR, (int)getRandom(1600, 1800));
generateCamps(District.ALHIJRA, (int)getRandom(1400, 1600));
Collections.shuffle(listOfCampaigns);
//Collections.shuffle(listOfCampaigns);
fillBusesToList();
@ -727,7 +727,6 @@ public class MakkahCity {
if (!(vehicle instanceof Bus) && vehicle.isArrivedToDest())
listOfVehicles.remove(vehicle);
else i++;
}
}
@ -735,7 +734,7 @@ public class MakkahCity {
for (Campaign camp : listOfCampaigns){
if(camp.getVehicles().get(0).getCurrentStreet() == null) {
isAllRoutSet = false;
camp.setRoute(getBestRoute(camp, mashier));
camp.setRoute(getShortestRoute(camp, mashier));
}
}
}