1#ifndef OBSTACLELISTMANAGER_H
2#define OBSTACLELISTMANAGER_H
4#include "core/ObstacleType.h"
106 std::shared_ptr<QMutex> locker;
109 QList<Obsticals*> activate_obsticals;
112 QList<CactusObsticals*> cactus_obsticals_pool;
115 QList<BirdObsticals*> brid_obsticals_pool;
124 enum class BaseType {
135 QList<Obsticals*> query_unactivates(BaseType t,
int how_many);
140 void init_instance_pool();
145 void process_internal_pass_session();
150 void process_random_summon_once();
156 int get_max_right_x_of_actives()
const;
164 int adjustif_new_members(
const QList<Obsticals*>& new_members,
int start_x);
169 void let_bird_appear() { should_bird_appear =
true; }
172 bool should_bird_appear {
false };
Represents bird obstacles in the game.
Definition BirdObsticals.h:12
CactusObsticals inherits from Obsticals and provides size and rendering control.
Definition CactusObsticals.h:13
Manages the creation, rendering, and collision detection of obstacles.
Definition ObstacleListManager.h:17
int max_obstacle_cnt() const
Gets maximum obstacle count.
Definition ObstacleListManager.h:70
bool is_intersects(Dinasour *dinasour)
Checks for collision with dinosaur.
Definition ObstacleListManager.cpp:62
int activate_obstacle_cnt() const
Gets count of active obstacles.
Definition ObstacleListManager.h:76
int get_obstacle_speed()
Gets current obstacle movement speed.
Definition ObstacleListManager.cpp:87
void set_max_obstacle_cnt(short max_count)
Sets maximum number of active obstacles.
Definition ObstacleListManager.cpp:79
void start_blank_working()
Initializes the obstacle system.
Definition ObstacleListManager.cpp:45
void set_obstacle_speed(int speed)
Sets obstacle movement speed.
Definition ObstacleListManager.cpp:153
void flush_activate_obsticals_once()
Updates active obstacles.
Definition ObstacleListManager.cpp:145
QList< Obsticals * > get_pools()
Gets all obstacle pools.
Definition ObstacleListManager.cpp:71
void reset_back()
Resets all obstacles to initial state.
Definition ObstacleListManager.cpp:57
QList< Obsticals * > get_should_render()
Gets obstacles that should be rendered.
Definition ObstacleListManager.cpp:41
void pass_a_obstacle(ObstacleType type, Obsticals *which)
Emitted when an obstacle is passed.
void animate_once()
Performs one animation frame update.
Definition ObstacleListManager.cpp:50
Base class for all obstacle objects in the game.
Definition Obsticals.h:15
Configuration constants for bird obstacles.
Configuration constants for cactus obstacles.
Configuration constants related to the dinosaur figure.