#include "Animation.h"
#ifndef UNIT_H
#define UNIT_H

//typs of units
///inviseal walls for coller,npcs, players, triggers, spond points,particals sponds, hot spots :tellport room enters,area exits
#include <sstream>


//enum orienation { upd, downd, leftd, rightd};
class Unit
{
	protected:
	//data members
		//THE SEVERWILL SET IDS AND GIVE OUT IDS THE FIRST BIT IN ID WILL TELL IN NPC OR PLAYER UINT
		int id;
		int socketid;
		int x;
		int y;
		int w;
		int h;
		int layer;
		int source_X;
		int source_Y;
		int collision;
		int frame;
		int direction;
		int source;
		int inarea;
		string name;
		int dest;
	public:
	DATAFILE *data;
		int scroll_x;
		int screen_pos_y;
		int scroll_y;
		int screen_pos_x;
		//gets
		int tag; // this is so you know what the object is
		string Get_name();
		int Get_inarea();
		int Get_id();
		int Get_socketid();
		int Get_X();
		int Get_Y();
		int Get_W();
		int Get_H();
		int Get_frame();
		int Get_layer();
		int Get_source_X();
		int Get_source_Y();
		int Is_in_collision();
		int Get_direction();
		int Get_sourcebitmap();
		int Get_destbitmap();
		//sets
		void Set_name(string );
		void Set_inarea(int);
		void Set_id(int);
		void Set_socketid(int);
		void Set_X(int);
		void Set_Y(int);
		void Set_H(int);
		void Set_W(int);
		void Set_frame(int);
		void Set_layer(int);
		void Set_source_X(int);
		void Set_source_Y(int);
		void Set_collision(int);
		void Set_direction(int);
		void Set_sourcebitmap(int);
		void Set_destbitmap(int);
		void draw(BITMAP*);
		void showname(BITMAP* );
		bool is_collision( Unit );
		//constutors
		Unit();
		~Unit();
		Unit(int,BITMAP*);
		//other founctions
		//void drawer( BITMAP *bmpp ,BITMAP *bmp ,int x,int y,int w, int h , int frame_x, int frame_y );
		//void masked_blit(BITMAP *source, BITMAP *dest, int source_x, int source_y, int dest_x, int dest_y, int width, int height);

};


/////////////////////////////////////////////////////
#endif