From 4f40a79085b347efd4adb52ebc614a3ec4926d96 Mon Sep 17 00:00:00 2001 From: bytesparallel Date: Tue, 9 Aug 2022 10:33:02 -0500 Subject: [PATCH] saving final changes --- fleet.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/fleet.py b/fleet.py index b7ebff5..ad174d4 100644 --- a/fleet.py +++ b/fleet.py @@ -69,9 +69,8 @@ class GroundVehicle(Vehicle): def __init__(self, _isModular, _moveGroundVehicle, _gpsPosition, _velocity, _weight, _velocityType, _weightType, _status,vehicleid, _fuelType, _vehicleType): super().__init__(_gpsPosition, _velocity, _weight, _velocityType, _weightType, _status,vehicleid, _fuelType, _vehicleType) self.isModular = _isModular - # modifier to GPS position self.moveGroundVehicle = _moveGroundVehicle - + # modifier to GPS position class RoadVehicle(GroundVehicle): @abstractmethod @@ -137,13 +136,14 @@ class VehicleFactory(): def factory(self, _type): # try: if _type == VehicleTypes.semi_Truck: - + truckToBuild = semi_Truck(2, 4, True, [40.0000, 50.0000], [30.0000, 20.000], 60, 90000, "mph", "lbs", "traveling", "307UNHL", fuelTypes.Diesel) return truckToBuild + # Make these parameters and not hard coded values elif _type == VehicleTypes.train: - return Train(4, 5,True, [40.0000, 50.0000], [30.0000, 20.000], 60, 90000, "mph", "lbs", "traveling", "307UNHL", fuelTypes.Diesel ) + return Train(4, 5, True, [40.0000, 50.0000], [30.0000, 20.000], 60, 90000, "mph", "lbs", "traveling", "307UNHL", fuelTypes.Diesel ) else: - "Bad vehicle creation: " + str(type) + print("Bad vehicle creation: " + str(type)) # except TypeError: # print("Unexpected object creation error")