#ifndef MENUOBJECT_H
#define MENUOBJECT_H

#include <string>
using std::string;

class MenuObject
{
	protected:
		int x,y,w,h,color;
		bool coligion,selceted;
		string lable;

	public:
		BITMAP *bmp;
		string	Get_lable();
		BITMAP*	Get_bmp();
		int	Get_x();
		int	Get_y();
		int	Get_w();
		int	Get_h();
		int	Get_color();
		bool Get_coligion();
		bool Get_selceted();
		void Set_lable(string);
		void Set_bmp(BITMAP*);
		void Set_x(int);
		void Set_y(int);
		void Set_w(int);
		void Set_h(int);
		void Set_color(int);
		void Set_coligion(bool);
		void Set_selceted(bool);	
		void draw();
		bool is_collision(MenuObject);
		MenuObject();
};

BITMAP* MenuObject::Get_bmp()
{
return bmp ;
}


string MenuObject::Get_lable()
{
return lable;
}
	int	MenuObject::Get_x()
		{
return x;
	}
	int	MenuObject::Get_y()
			{
return y;
	}
	int	MenuObject::Get_w()
			{
return w;
	}
	int	MenuObject::Get_h()
			{
return h;
	}
	int	MenuObject::Get_color()
			{
return color;
	}
	bool MenuObject::Get_coligion()
			{
return coligion;
	}
	bool MenuObject::Get_selceted()
			{
return selceted;
	}
void MenuObject::Set_bmp(BITMAP* q)
{
bmp = q;
}
void MenuObject::Set_lable(string q)
{
	lable = q;
}
	void MenuObject::Set_x(int q)
			{
x=q;
	}
	void MenuObject::Set_y(int q)
			{
y=q;
	}
	void MenuObject::Set_w(int q)
			{
w=q;
	}
	void MenuObject::Set_h(int q)
			{
h=q;
	}
	void MenuObject::Set_color(int q)
			{
color=q;
	}
	void MenuObject::Set_coligion(bool q)
			{
coligion=q;
	}
	void MenuObject::Set_selceted(bool q)
			{
selceted=q;
	}
	bool MenuObject::is_collision( MenuObject b)
{
    if ((x > b.x + b.w -1) || // is a on the right side
        (y > b.y + b.h -1) || // is a under
        (b.x > x + w -1) || // is b on the right side
        (b.y > y + h -1))   // is b under
    {
        // this means that there is no collision
        return 0; // means no colide
    }

    return 1; // means colide
}



MenuObject::MenuObject()
{
	x=0;
	y=0;
	w=100;
	h=100;
color=makecol(255,255,55);
		 coligion=selceted=false;
		lable="no lable";
		bmp = screen;


}
void MenuObject::draw()
{
}

#endif