Main controller for managing the simulation of creepers and Steves. More...
#include <Simulation.hpp>
Public Member Functions | |
| Simulation (const std::shared_ptr< FieldParams > &fieldParams, const std::shared_ptr< CreepersParams > &creepersParams, const std::shared_ptr< StevesParams > &stevesParams) | |
| Constructs a Simulation object. | |
| void | updateField () |
| Updates the simulation field. | |
| CreepersManager & | getCreepersManager () |
| Provides access to the CreepersManager. | |
| StevesManager & | getStevesManager () |
| Provides access to the StevesManager. | |
| Simulation & | setBedrock (const Rectangle &bedrock) |
| Configures bedrock for the simulation field. | |
| Simulation & | deleteBedrock (const Rectangle &bedrock) |
Main controller for managing the simulation of creepers and Steves.
The Simulation class coordinates the field, creepers, and Steves, handling updates, interactions, and field configuration.
| Simulation::Simulation | ( | const std::shared_ptr< FieldParams > & | fieldParams, |
| const std::shared_ptr< CreepersParams > & | creepersParams, | ||
| const std::shared_ptr< StevesParams > & | stevesParams | ||
| ) |
Constructs a Simulation object.
| fieldParams | Shared pointer to the field parameters. |
| creepersParams | Shared pointer to creeper parameters. |
| stevesParams | Shared pointer to Steve parameters. |
|
inline |
|
inline |
Provides access to the CreepersManager.
|
inline |
Provides access to the StevesManager.
|
inline |
Configures bedrock for the simulation field.
| bedrock | Rectangle representing the bedrock boundaries. |
| void Simulation::updateField | ( | ) |
Updates the simulation field.
This method manages the interactions and updates between creepers and Steves.