32 std::unique_ptr<RealismConfigErForce>& realism_config,
33 const bool ramping =
false,
34 double primitive_executor_time_step_s =
35 DEFAULT_SIMULATOR_TICK_RATE_SECONDS_PER_TICK);
61 void setBlueRobots(
const std::vector<RobotStateWithId>& robots);
62 void setRobots(
const std::vector<RobotStateWithId>& robots,
63 gameController::Team team);
64 void setRobots(
const google::protobuf::Map<uint32_t, TbotsProto::RobotState>& robots,
65 gameController::Team side);
72 void setWorldState(
const TbotsProto::WorldState& world_state);
82 std::unique_ptr<TbotsProto::World> world_msg);
83 void setBlueRobotPrimitiveSet(
const TbotsProto::PrimitiveSet& primitive_set_msg,
84 std::unique_ptr<TbotsProto::World> world_msg);
99 std::vector<TbotsProto::RobotStatus> getYellowRobotStatuses()
const;
157 static void setRobotPrimitive(
158 RobotId
id,
const TbotsProto::PrimitiveSet& primitive_set_msg,
159 std::unordered_map<
unsigned int, std::shared_ptr<PrimitiveExecutor>>&
160 robot_primitive_executor_map,
161 const TbotsProto::World& world_msg,
const Vector& local_velocity,
171 static std::map<RobotId, std::pair<Vector, AngularVelocity>>
172 getRobotIdToLocalVelocityMap(
173 const google::protobuf::RepeatedPtrField<world::SimRobot>& sim_robots);
184 SSLSimulationProto::RobotControl updateSimulatorRobots(
185 std::unordered_map<
unsigned int, std::shared_ptr<PrimitiveExecutor>>&
186 robot_primitive_executor_map,
187 const TbotsProto::World& world_msg, gameController::Team side);
201 std::unique_ptr<TbotsProto::DirectControlPrimitive> getRampedVelocityPrimitive(
202 const Vector current_local_velocity,
204 TbotsProto::DirectControlPrimitive& target_velocity_primitive,
205 const double& time_to_ramp);
208 std::unordered_map<unsigned int, std::shared_ptr<PrimitiveExecutor>>
209 yellow_primitive_executor_map;
210 std::unordered_map<unsigned int, std::shared_ptr<PrimitiveExecutor>>
211 blue_primitive_executor_map;
212 std::unique_ptr<TbotsProto::World> yellow_team_world_msg;
213 std::unique_ptr<TbotsProto::World> blue_team_world_msg;
215 double primitive_executor_time_step_s;
216 unsigned int frame_number;
221 amun::SimulatorSetup er_force_sim_setup;
222 std::unique_ptr<camun::simulator::Simulator> er_force_sim;
228 std::optional<RobotId> blue_robot_with_ball;
229 std::optional<RobotId> yellow_robot_with_ball;
233 const std::string CONFIG_FILE =
"simulator/2020";
234 const std::string CONFIG_DIRECTORY =
"extlibs/er_force_sim/config/";