Commit pa que Mon arregle el codi mentre em dutxe

This commit is contained in:
2024-10-09 21:48:01 +02:00
parent 3c1dcad3ab
commit f2fa216b0d
34 changed files with 862 additions and 1218 deletions

View File

@@ -11,7 +11,7 @@
#include "options.h"
// Constructor
Player::Player(int id, float x, int y, bool demo, SDL_Rect *playArea, std::vector<Texture *> texture, std::vector<std::vector<std::string> *> animations)
Player::Player(int id, float x, int y, bool demo, SDL_Rect *playArea, std::vector<std::shared_ptr<Texture>> texture, std::vector<std::vector<std::string> *> animations)
{
// Reserva memoria para los objetos
playerSprite = std::make_unique<AnimatedSprite>(texture[0], "", animations[0]);
@@ -679,7 +679,7 @@ void Player::shiftColliders()
}
// Pone las texturas del jugador
void Player::setPlayerTextures(std::vector<Texture *> texture)
void Player::setPlayerTextures(std::vector<std::shared_ptr<Texture>> texture)
{
playerSprite->setTexture(texture[0]);
powerSprite->setTexture(texture[1]);