#ifndef WORLD_H #define WORLD_H #include "enemy.h" #include "resourceholder.h" #include "scenenode.h" #include #include #include class World : private sf::NonCopyable { public: explicit World(sf::RenderWindow& window); void update(const sf::Time& dt); void draw(); std::queue& getCommandQueue(); private: bool loadTextures(); void buildScene(); enum Layer { Background, Air, LayerCount }; std::queue queue_commands; sf::RenderWindow& world_window; sf::View world_view; TextureHolder texture_holder; SceneNodeSPtr scene_graph; std::array arr_layers; sf::FloatRect world_bounds; sf::Vector2f world_spawn_pos; float world_speed; EnemySPtr player; }; #endif // WORLD_H