quick check with linters

This commit is contained in:
MihailRis
2024-05-10 12:34:05 +03:00
parent 92f185ab51
commit 9522aedeec
55 changed files with 129 additions and 184 deletions
+1 -1
View File
@@ -416,7 +416,7 @@ void Hud::add(HudElement element) {
elements.push_back(element);
}
void Hud::onRemove(HudElement& element) {
void Hud::onRemove(const HudElement& element) {
auto document = element.getDocument();
if (document) {
Inventory* inventory = nullptr;
+1 -1
View File
@@ -162,7 +162,7 @@ public:
void openPermanent(UiDocument* doc);
void add(HudElement element);
void onRemove(HudElement& element);
void onRemove(const HudElement& element);
void remove(std::shared_ptr<gui::UINode> node);
Player* getPlayer() const;
+2 -2
View File
@@ -38,7 +38,7 @@ LevelScreen::LevelScreen(Engine* engine, Level* level) : Screen(engine) {
worldRenderer = std::make_unique<WorldRenderer>(engine, frontend.get(), controller->getPlayer());
hud = std::make_unique<Hud>(engine, frontend.get(), controller->getPlayer());
keepAlive(settings.graphics.backlight.observe([=](bool flag) {
keepAlive(settings.graphics.backlight.observe([=](bool) {
controller->getLevel()->chunks->saveAndClear();
}));
keepAlive(settings.camera.fov.observe([=](double value) {
@@ -137,7 +137,7 @@ void LevelScreen::update(float delta) {
hud->update(hudVisible);
}
void LevelScreen::draw(float delta) {
void LevelScreen::draw(float) {
auto camera = controller->getPlayer()->currentCamera;
Viewport viewport(Window::width, Window::height);