public CheckpointPIDController(Drone drone, float mass, float gravity, AbstractDroneCommand droneCommand, Parameter[] parameters, List<Checkpoint> checkpoints) : base(drone, mass, gravity, droneCommand, parameters) { _targetCheckpoints = checkpoints; _isStarted = false; _rotorsEnabled = false; }
public SimplePIDController(Drone drone, float mass, float gravity, AbstractDroneCommand droneCommand, Parameter[] parameters) { _drone = drone; _droneMass = mass; _gravity = gravity; _droneCommand = droneCommand; _gravity = gravity; _altParameter = new Parameter(ParameterType.Altitude, new Coefficients(0, 0, 0)); _yawParameter = new Parameter(ParameterType.Yaw, new Coefficients(0, 0, 0)); _pitchParameter = new Parameter(ParameterType.Pitch, new Coefficients(0, 0, 0)); _rollParameter = new Parameter(ParameterType.Roll, new Coefficients(0, 0, 0)); foreach (Parameter param in parameters) { switch (param.Type) { case ParameterType.Altitude: _altParameter = param; break; case ParameterType.Pitch: _pitchParameter = param; break; case ParameterType.Roll: _rollParameter = param; break; case ParameterType.Yaw: _yawParameter = param; break; } } }
public PlayerController(PlayerInteraction player, Drone drone, float mass, float gravity, AbstractDroneCommand droneCommand, Parameter[] parameters) : base(drone, mass, gravity, droneCommand, parameters) { _command = droneCommand; _player = player; _deltaZ = 0; _drone = drone; _isStarted = false; return; }