Arreglos varios al codi
This commit is contained in:
@@ -1,19 +1,17 @@
|
||||
#include "tiled_bg.h"
|
||||
#include <SDL2/SDL_pixels.h> // for SDL_PIXELFORMAT_RGBA8888
|
||||
#include <SDL2/SDL_stdinc.h> // for SDL_sinf
|
||||
#include <stdlib.h> // for rand
|
||||
#include "screen.h" // for Screen
|
||||
#include "sprite.h" // for Sprite
|
||||
#include "texture.h" // for Texture
|
||||
#include <SDL2/SDL_pixels.h> // for SDL_PIXELFORMAT_RGBA8888
|
||||
#include <SDL2/SDL_stdinc.h> // for SDL_sinf
|
||||
#include <stdlib.h> // for rand
|
||||
#include "screen.h" // for Screen
|
||||
#include "sprite.h" // for Sprite
|
||||
#include "texture.h" // for Texture
|
||||
|
||||
// Constructor
|
||||
Tiledbg::Tiledbg(std::string texturePath, SDL_Rect pos, int mode)
|
||||
: texturePath(texturePath), pos(pos), mode(mode)
|
||||
{
|
||||
// Copia los punteros
|
||||
renderer = Screen::get()->getRenderer();
|
||||
this->texturePath = texturePath;
|
||||
this->pos = pos;
|
||||
this->mode = mode;
|
||||
|
||||
// Crea la textura para el mosaico de fondo
|
||||
canvas = SDL_CreateTexture(renderer, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_TARGET, pos.w * 2, pos.h * 2);
|
||||
|
||||
Reference in New Issue
Block a user