clang-tidy

This commit is contained in:
2025-08-17 10:20:41 +02:00
parent b359a73d50
commit 8ddc5d94f1
73 changed files with 867 additions and 833 deletions

View File

@@ -18,7 +18,7 @@ Sprite::Sprite(std::shared_ptr<Texture> texture, SDL_FRect rect)
Sprite::Sprite(std::shared_ptr<Texture> texture)
: textures_{std::move(texture)},
texture_index_(0),
pos_(SDL_FRect{0, 0, static_cast<float>(textures_.at(texture_index_)->getWidth()), static_cast<float>(textures_.at(texture_index_)->getHeight())}),
sprite_clip_(pos_) {}
@@ -41,8 +41,8 @@ void Sprite::setPosition(SDL_FPoint point) {
// Reinicia las variables a cero
void Sprite::clear() {
pos_ = {0, 0, 0, 0};
sprite_clip_ = {0, 0, 0, 0};
pos_ = {.x = 0, .y = 0, .w = 0, .h = 0};
sprite_clip_ = {.x = 0, .y = 0, .w = 0, .h = 0};
}
// Cambia la textura activa por índice