Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <SDL/SDL.h>
- #include <iostream>
- using namespace std;
- #ifndef TILE_H
- #define TILE_H
- class Tile {
- private:
- SDL_Surface* surface;
- int x, y, size;
- int sx, sy; //sheet coordinates
- public:
- Tile();
- Tile(SDL_Surface* surface, int x, int y, int size, int sx, int sy);
- SDL_Surface* getSheet();
- int getX();
- int getY();
- int getSheetX();
- int getSheetY();
- int getSize();
- void setX(int x);
- void setY(int y);
- void setSheetX(int x);
- void setSheetY(int y);
- void setSheet(SDL_Surface* sheet);
- void render(SDL_Surface* screen, int xtrans, int ytrans);
- };
- #endif
Advertisement
Add Comment
Please, Sign In to add comment