Skip to content

GameScene subclass approach. #51

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jun 26, 2024
Prev Previous commit
Next Next commit
Cleanup.
  • Loading branch information
karnkaul committed Jun 25, 2024
commit 2436fa91fbab6ee788804d33dfb6c35277cde581
1 change: 0 additions & 1 deletion src/spaced/spaced/game/star_field.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,5 @@ class StarField : public bave::IDrawable {
bave::NotNull<Layout const*> m_layout;

std::vector<Field> m_fields{};
bave::Seconds m_next_spawn{};
};
} // namespace spaced
1 change: 0 additions & 1 deletion src/spaced/spaced/spaced.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ void Spaced::set_layout() {
static constexpr auto world_space_v = glm::vec2{1920.0f, 1080.0f};

auto layout = std::make_unique<Layout>(&get_app().get_render_device());
m_layout = layout.get();
auto& world_space = m_services.get<Display>().world;
world_space.render_view.viewport = world_space.get_viewport_scaler().match_width(world_space_v);

Expand Down
2 changes: 0 additions & 2 deletions src/spaced/spaced/spaced.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,5 @@ class Spaced : public bave::GameDriver {
void set_scene();

bave::Logger m_log{"Spaced"};
bave::Ptr<bave::Resources> m_resources{};
bave::Ptr<Layout> m_layout{};
};
} // namespace spaced