ctrl k
  • service/src/simulationmodel/factory/DroneFactory.cc
    ■ ■ ■ ■ ■ ■
    1 1  #include "DroneFactory.h"
    2  - 
     2 +#include "DroneBatteryDecorator.h"
    3 3  IEntity* DroneFactory::createEntity(const JsonObject& entity) {
    4 4   std::string type = entity["type"];
    5 5   if (type.compare("drone") == 0) {
    6 6   std::cout << "Drone Created" << std::endl;
    7  - return new Drone(entity);
     7 + return new DroneBatteryDecorator(new Drone(entity), 100, 100, 20, 5.0);
    8 8   }
    9 9   return nullptr;
    10 10  }
    skipped 1 lines
Page is in error, reload to recover