#ifndef TILE_H
#define TILE_H

#include "Object.h"
#include "Sprite.h"

class Tile: public Object
{
public:
	Tile();
	Tile(Sprite* sprite, bool collidable, int x, int y, double depth = 0);

	virtual Object *copy();

	void collide( Object* o );	
	void draw();
	void update();

	Sprite *getSprite() {return _sprite;}
	void setDraw(bool draw) {_draw = draw;}
	bool getDraw() {return _draw;}

	void calcDrawBox();
	SDL_Rect getSquare(Sprite *sprite, double depth);


private:
	Sprite * _sprite;
	bool _draw;
	bool _existDBox;
	SDL_Rect _drawBox;
};

#endif