clang-tidy

This commit is contained in:
2026-04-07 12:06:41 +02:00
parent 39170a086e
commit 5462b31f96
12 changed files with 63 additions and 64 deletions

View File

@@ -223,7 +223,7 @@ void Player::moveHorizontal(float delta_time) {
}
const auto& tc = room_->getTileCollider();
float new_x = x_ + vx_ * delta_time;
float new_x = x_ + (vx_ * delta_time);
// Colisión con paredes
if (vx_ < 0.0F) {
@@ -431,9 +431,9 @@ void Player::transitionToState(State state) {
// Bordes de pantalla
// ============================================================================
auto Player::handleBorders() -> Room::Border {
const float CENTER_X = x_ + WIDTH / 2.0F;
const float CENTER_Y = y_ + HEIGHT / 2.0F;
auto Player::handleBorders() const -> Room::Border {
const float CENTER_X = x_ + (WIDTH / 2.0F);
const float CENTER_Y = y_ + (HEIGHT / 2.0F);
if (CENTER_X < PlayArea::LEFT) { return Room::Border::LEFT; }
if (CENTER_X > PlayArea::RIGHT) { return Room::Border::RIGHT; }