ImageName="Panel.jpg";
ManufacturingNameText = "Building"; --"Производство"
WorkerNameText = "Character"
GardenNameText = "Garden";
GardenerNameText = "Character";
WaterwellNameText = "WaterWell";
RopeNameText = "ЙюЛч";
StairsNameText = "МЭЧУ";
TeleportNameText = "ґ«ЛНГЕ";
ShopNameText = "Shop";
ShopStoreNameText = "Lotok"; --склад магазина
StorehouseNameText = "Storehouse";

emptyObj = nil;

function copy(obj, template)
    obj = {};
    for key, value in pairs(template) do
        if(type(value) == 'table') then
            obj[key] = copy(obj[key], template[key]);
        else
            obj[key] = value;
        end 
    end
    
    return obj;
end 

function copyEx(obj, template)
    obj = {};
    for key, value in ipairs(template) do
        if(type(value) == 'table') then
            obj[key] = copy(obj[key], template[key]);
        else
            obj[key] = value;
        end 
    end
    
    return obj;
end 

SprSelectedTab=
{
	--Pos={4,3},
	Image=ImageName,
	SrcRect={0, 858, 195, 902},
};

AniSprNormalTaskBuilding=
{
	Pos={14,3},
	Image=ImageName,
	Animation=
	{
		FramesList=
		{
			{289, 679, 373, 764},	--(0) замок
			{611, 736, 670, 793},	--(1) мука
			{257, 964, 316, 1021},	--(2) 2 муки
			{316, 964, 375, 1021},	--(3) 3 муки
			{375, 736, 434, 793},	--(4) сок
			{434, 907, 493, 964},	--(5) 2 сока
			{375, 907, 434, 964},	--(6) 3 сока
			{434, 736, 493, 793},	--(7) кетчуп
			{611, 850, 670, 907},	--(8) 2 кетчупа
			{670, 793, 729, 850},	--(9) 3 кетчупа
			{670, 679, 729, 736},	--(10) котлета
			{139, 964, 198, 1021},	--(11) 2 котлеты
			{198, 964, 257, 1021},	--(12) 3 котлеты
			{493, 793, 552, 850},	--(13) пирог
			{552, 907, 611, 964},	--(14) 2 пирога
			{493, 907, 552, 964},	--(15) 3 пирога
			{611, 793, 669, 850},	--(16) хлеб
			{21, 964, 80, 1021},	--(17) 2 хлеба
			{80, 964, 139, 1021},	--(18) 3 хлеба
			{493, 736, 552, 793},	--(19) масло
			{80, 907, 139, 964},	--(20) 2 масла
			{21, 907, 80, 964},		--(21) 3 масла
			{434, 793, 493, 850},	--(22) гумбургер
			{552, 850, 611, 907},	--(23) 2 гумбургера
			{493, 850, 552, 907},	--(24) 3 гумбургера
			{375, 793, 434, 850},	--(25) тесто
			{434, 964, 493, 1021},	--(26) 2 теста
			{375, 964, 434, 1021},	--(27) 3 теста
			{552, 736, 611, 793},	--(28) упакованная картошка
			{139, 907, 198, 964},	--(29) 2 упакованной картошки
			{198, 907, 257, 964},	--(30) 3 упакованной картошки
			{552, 793, 611, 850},	--(31) картофель фри
			{316, 907, 375, 964},	--(32) 2 картофель фри
			{257, 907, 316, 964},	--(33) 3 картофель фри

		};
	};

};

AniSprDisabledTaskBuilding=
{
	Pos={15,4},
	Image=ImageName,
	Animation=
	{
		FramesList=
		{
			{289, 679, 373, 764},	--(0) замок
			{965, 736, 1024, 793},	--(33) мука(серый)
			{729, 964, 788, 1021},	--(34) 2 муки(серый)
			{788, 964, 847, 1021},	--(35) 3 муки(серый)
			{729, 736, 788, 793},	--(36) сок(серый)
			{965, 964, 1024, 1021},	--(37) 2 сока(серый)
			{965, 907, 1024, 964},	--(38) 3 сока(серый)
			{788, 736, 847, 793},	--(39) кетчуп(серый)
			{729, 850, 788, 907},	--(40) 2 кетчупа(серый)
			{670, 850, 729, 907},	--(41) 3 кетчупа(серый)
			{670, 736, 729, 793},	--(42) котлета(серый)
			{611, 964, 670, 1021},	--(43) 2 котлеты(серый)
			{670, 964, 729, 1021},	--(44) 3 котлеты(серый)
			{847, 793, 906, 850},	--(45) пирог(серый)
			{965, 850, 1024, 907},	--(46) 2 пирога(серый)
			{906, 850, 965, 907},	--(47) 3 пирога(серый)
			{965, 793, 1024, 850},	--(48) хлеб(серый)
			{493, 964, 552, 1021},	--(49) 2 хлеба(серый)
			{552, 964, 611, 1021},	--(50) 3 хлеба(серый)
			{847, 736, 906, 793},	--(51) масло(серый)
			{670, 907, 729, 964},	--(52) 2 масла(серый)
			{611, 907, 670, 964},	--(53) 3 масла(серый)
			{788, 793, 847, 850},	--(54) гумбургер(серый)
			{847, 850, 906, 907},	--(55) 2 гумбургера(серый)
			{788, 850, 847, 907},	--(56) 3 гумбургера(серый)
			{729, 793, 788, 850},	--(57) тесто(серый)
			{906, 964, 965, 1021},	--(58) 2 теста(серый)
			{847, 964, 906, 1021},	--(59) 3 теста(серый)
			{906, 736, 965, 793},	--(60) упакованная картошка(серый)
			{729, 907, 788, 964},	--(61) 2 упакованной картошки(серый)
			{788, 907, 847, 964},	--(62) 3 упакованной картошки(серый)
			{906, 793, 965, 850},	--(63) картофель фри(серый)
			{906, 907, 965, 964},	--(64) 2 картофель фри(серый)
			{847, 907, 906, 964},	--(65) 3 картофель фри(серый)

		};
	};

};

AniSprPressedTaskBuilding=
{
	Pos={15,4},
	Image=ImageName,
	Animation=AniSprNormalTaskBuilding.Animation,
	
};



AniSprNormalTaskGarden=
{
	Pos={14,3},
	Image=ImageName,
	Animation=
	{
		FramesList=
		{
			{289, 679, 373, 764},	--(0) замок
			{375, 679, 434, 736},	--(1) морковка
			{434, 679, 493, 736},	--(2) помидор
			{552, 679, 611, 736},	--(3) картошка
			{493, 679, 552, 736},	--(4) подсолнух
			{611, 679, 670, 736},	--(5) пшеница
		};
	};

};

AniSprDisabledTaskGarden=
{
	Pos={15,4},
	Image=ImageName,
	Animation=
	{
		FramesList=
		{
			{289, 679, 373, 764},	--(0) замок
			{729, 679, 788, 736},	--(1) морковка
			{788, 679, 847, 736},	--(2) помидор
			{906, 679, 965, 736},	--(3) картошка
			{847, 679, 906, 736},	--(4) подсолнух
			{965, 679, 1024, 736},	--(5) пшеница
		};
	};

};

AniSprPressedTaskGarden=
{
	Pos={15,4},
	Image=ImageName,
	Animation=AniSprNormalTaskGarden.Animation,
};

AniSprNormalTaskWaterwell=
{
	Pos={14,3},
	Image="Icons.jpg",
	Animation=
	{
		FramesList=
		{
			{762, 398, 846, 483},	--(0) замок
			{199, 398, 258, 455},	--(1) 1 ведро
			{317, 398, 376, 455},	--(2) 2 ведро
			{435, 398, 494, 455},	--(3) 3 ведро
		};
	};

};


AniSprDisabledTaskWaterwell=
{
	Pos={15,4},
	Image="Icons.jpg",
	Animation=
	{
		FramesList=
		{
			{762, 398, 846, 483},	--(0) замок
			{258, 398, 317, 455},	--(1) 1 ведро
			{376, 398, 435, 455},	--(2) 2 ведро
			{494, 398, 553, 455},	--(3) 3 ведро
		};
	};

};

AniSprPressedTaskWaterwell=
{
	Pos={15,4},
	Image="Icons.jpg",
	Animation=AniSprNormalTaskWaterwell.Animation,
};

--кнопка с мастерком
ButtonTextNormal=
{
	Font="font04.fnt",
	TextArea={6, 46, 98-6, 60},
	HAlign="center",
	SRatio=0.8,
};
ButtonTextPressed=
{
	Font="font04.fnt",
	TextArea={6+1, 46+1, 98-6+1, 60+1},
	HAlign="center",
	SRatio=0.8,

};

--текст для кнопки "отмена продажи персонажа"
ButtonTextNormalCancel=
{
	Font="font04.fnt",
	TextArea={4, 46, 98, 60},
	HAlign="center",
	SRatio=0.8,
};
ButtonTextPressedCancel=
{
	Font="font04.fnt",
	TextArea={4+1, 46+1, 98+1, 60+1},
	HAlign="center",
	SRatio=0.8,

};

--текст для кнопка продажи персонажа
SaleTextNormal=
{
	Font="font04.fnt",
	TextArea={6-5, 46, 92-5, 60},
	HAlign="center",
	SRatio=0.8,
};
SaleTextPressed=
{
	Font="font04.fnt",
	TextArea={6-5+1, 46+1, 92-5+1, 60+1},
	HAlign="center",
	SRatio=0.8,

};


LockAniSprDisabled=
{
	Pos={-1,1},
	Image=ImageName,

	Animation=
	{
		FramesList=
		{
			{0, 0, 0, 0},
			{195, 679, 289, 764},
		};
	};
};

-------------------
-------------------
-------------------

--кнопка на панельки
ButtonTextNormalTask=
{
	Font="font04.fnt",
	TextArea={0, 46, 88, 90},
	HAlign="center",
	SRatio=0.80,
};
ButtonTextPressedTask=
{
	Font="font04.fnt",
	TextArea={1, 46+1, 88+1, 90+1},
 	HAlign="center",
	SRatio=0.80,
};

TaskNormal={477, 594, 561, 679};
TaskOver={645, 594, 729, 679};
TaskPressed={645-1, 594-1, 729, 679};
TaskDisabled={561, 594, 645, 679};

SaleNormal={729, 594, 813, 679};
SaleOver={897, 594, 981, 679};
SalePressed={897-1, 594-1, 981, 679};
SaleDisabled={813, 594, 897, 679};

UpgradeRectNormal={195, 594, 289, 679};
UpgradeRectOver={383, 594, 477, 679};
UpgradeRectPressed={383-1, 594-1, 477, 679};
UpgradeRectDisabled={289, 594, 383, 679};

BuyRectNormal={617, 617, 686, 687};
BuyRectOver={479, 617, 548, 687};
BuyRectPressed={479-1, 617-1, 548, 687};
BuyRectDisabled={548, 617, 617, 687};

SprNormalBuildImage=
{
	Pos={4,3},
	Image=ImageName,
	SrcRect={228, 816, 285, 863},
};

SprOverBuildImage=
{
	Pos={4,3},
	Image=ImageName,
	SrcRect={228, 816, 285, 863},
};

SprPressedBuildImage=
{
	Pos={5,4},
	Image=ImageName,
	SrcRect={228, 816, 285, 863},
};

SprDisabledBuildImage=
{
	Pos={4,3},
	Image=ImageName,
	SrcRect={285, 816, 342, 863},
};


		
		
poxy=768-96;

TopInfo=
{
    Pos={0,0},
    Image="Icons.jpg",
    SrcRect={0, 0, 1024, 76},

    {
        Name="Medal",
        Type="Image",
        Pos={848,4},
        Image="Icons.jpg",
        SrcRect={823,434,901,468},
    },

    {
        Name="Time_Text",
        Type="Text",    
        Caption="",
        Font="font02.fnt",
        TextArea={790,6,864,42},
        SRatio=0.75,
        SizeW=0.95,
        SizeH=1,--0.95,
        HAlign="center",
    },

    {
        Name="BonuseTime_Text",
        Type="Text",    
        Caption="",
        Font="Font01.fnt",
        TextArea={832,6,962,42},
        Colour={174/255,61/255,0,1},
        SRatio=0.65,
        HAlign="center",
    },



    {
        Name="Money_Text",
        Type="Text",    
        Caption="",
        Font="Font02_.fnt",
        TextArea={666-10,6,666 + 78+10,42}, 
        Colour={1,1,1,1},
        SRatio=0.85,
        HAlign="center",
    },

    {
        Name="GAMEPANELMENU",
        Type="Button",
        Pos={937,0},
        Image="Icons.jpg",
        Normal={937, 0, 1020, 42},
        Over={858, 78, 941, 120},
        Pressed={941, 78, 1024, 120},
    },

};



PanelGarden=
{
	Pos={0,poxy},
	Image=ImageName,
	SrcRect={0, 1, 1024, 97},

	--Вкладка 2 огорода
	{
		Name="TAB_GARDEN_CHARACTER_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={170-1,-41},
		SrcRect={0, 638, 195, 682},
	},
	--Вкладка 1 огорода
	{
		Name="TAB_GARDEN_BUILDING_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={-3,-41},
		SrcRect={0, 594, 195, 638},
	},

	--Вкладка текста огорода
	 {
		Name="TAB_GARDEN_BUILDING_TEXT",
		Type="Text",    
		Caption = GardenNameText,
		Font="Font07.fnt",
		TextArea={20,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},
	--Вкладка текста персонажа (садовник)
	{
		Name="TAB_GARDEN_CHARACTER_TEXT",
		Type="Text",    
		Caption = GardenerNameText,
		Font="Font07.fnt",
		--TextArea={190, -32, 400, 0}, 
		TextArea={230, -32, 350, 0}, 
		SRatio=0.8,
		HAlign="center",
	},
	
	{
		Name="GARDEN_UPGRADE",
		Type="Button",
		Pos={230,10},
		Image=ImageName,
		Normal=UpgradeRectNormal,
		Over=UpgradeRectOver,
		Pressed=UpgradeRectPressed,
		Disabled=UpgradeRectDisabled,

		AniSprDisabled=LockAniSprDisabled;
	
		
		Caption="one_num", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,

	},

	
	{
		Name="GARDEN_TASK1",
		Type="Button",
		Pos={380+8,11},
		Image=ImageName,

		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskGarden,
		AniSprOver=AniSprNormalTaskGarden,
		AniSprPressed=AniSprPressedTaskGarden,
		AniSprDisabled=AniSprDisabledTaskGarden,


		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},

	{
		Name="GARDEN_TASK2",
		Type="Button",
		Pos={475+4,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,
		
		AniSprNormal=AniSprNormalTaskGarden,
		AniSprOver=AniSprNormalTaskGarden,
		AniSprPressed=AniSprPressedTaskGarden,
		AniSprDisabled=AniSprDisabledTaskGarden,
	
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},

	{
		Name="GARDEN_TASK3",
		Type="Button",
		Pos={570,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,
		AniSprNormal=AniSprNormalTaskGarden,
		AniSprOver=AniSprNormalTaskGarden,
		AniSprPressed=AniSprPressedTaskGarden,
		AniSprDisabled=AniSprDisabledTaskGarden,
	
		
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},
	
	{
		Name="GARDEN_TASK4",
		Type="Button",
		Pos={665-4,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,
		
		AniSprNormal=AniSprNormalTaskGarden,
		AniSprOver=AniSprNormalTaskGarden,
		AniSprPressed=AniSprPressedTaskGarden,
		AniSprDisabled=AniSprDisabledTaskGarden,

		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},

	{
		Name="GARDEN_TASK5",
		Type="Button",
		Pos={760-8,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,
		
		AniSprNormal=AniSprNormalTaskGarden,
		AniSprOver=AniSprNormalTaskGarden,
		AniSprPressed=AniSprPressedTaskGarden,
		AniSprDisabled=AniSprDisabledTaskGarden,

		
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},

	{
		Name="TABGARDEN_BUY",
		Type="Button",
		Pos={564,10},
		Image="Icons.jpg",
		Normal={152, 313, 246, 398},
		Over={340, 313, 434, 398},
		Pressed={340-1, 313-1, 434, 398},
		Disabled={246, 313, 340, 398},

		SprNormal=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprOver=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprPressed=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		
		SprDisabled=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 133, 785, 188},
		},
		
		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},

};

PanelWaterwell=
{
	
	Pos={0,poxy},
	Image=ImageName,
	SrcRect={0, 393, 1024, 489},
	
	{
		Name="TAB_WATERWELL_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={-3,-41},
		SrcRect={0, 814, 195, 858},
	},


	{
		Name="WAT_UPGRADE",
		Type="Button",
		Pos={230,10},
                            --Pos={310,18},
		Image=ImageName,
		Normal=UpgradeRectNormal,
		Over=UpgradeRectOver,
		Pressed=UpgradeRectPressed,
		Disabled=UpgradeRectDisabled,

		AniSprDisabled=LockAniSprDisabled;
	
		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,


	},

	--Колодец
	 {
		Name="WATERWELL_GARDEN_TEXT",
		Type="Text",    
		Caption = WaterwellNameText,
		Font="Font07.fnt",
		TextArea={23,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},

	
	{
		Name="WAT_TASK1",
		Type="Button",
		Pos={475+4, 11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskWaterwell,
		AniSprOver=AniSprNormalTaskWaterwell,
		AniSprPressed=AniSprPressedTaskWaterwell,
		AniSprDisabled=AniSprDisabledTaskWaterwell,

		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,
	},


	{
		Name="WAT_TASK2",
		Type="Button",
		Pos={570, 11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,
		
		AniSprNormal=AniSprNormalTaskWaterwell,
		AniSprOver=AniSprNormalTaskWaterwell,
		AniSprPressed=AniSprPressedTaskWaterwell,
		AniSprDisabled=AniSprDisabledTaskWaterwell,

		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,
	},

	{
		Name="WAT_TASK3",
		Type="Button",
		Pos={665-4, 11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskWaterwell,
		AniSprOver=AniSprNormalTaskWaterwell,
		AniSprPressed=AniSprPressedTaskWaterwell,
		AniSprDisabled=AniSprDisabledTaskWaterwell,

		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,
	},


};

PanelBuilding=
{
	
	Pos={0,poxy},
	Image=ImageName,
	SrcRect={0, 296, 1024, 392},
	--вкладка производство
	{
		Name="TAB_BUILDING_CHARACTER_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={170-1,-41},
		SrcRect={0, 638, 195, 682},
	},
	--вкладка здания
	{
		Name="TAB_BUILDING_BUILDING_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={-3,-41},
		SrcRect={0, 770, 195, 814},
	},
	--Текст Вкладки здания (производство)
	{
		Name="BUILDING_GARDEN_TEXT",
		Type="Text",    
		Caption = ManufacturingNameText,
		Font="Font07.fnt",
		TextArea={20,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},
	--Текст вкладки здания (персонаж)
	{
		Name="BUILDING_CHAR_TEXT",
		Type="Text",    
		Caption = WorkerNameText,
		Font="Font07.fnt",
		--TextArea={190, -32, 400, 0}, 
		TextArea={230, -32, 350, 0}, 
		SRatio=0.8,
		HAlign="center",
	},
	
	{
		Name="BUILDING_UPGRADE",
		Type="Button",
		Pos={230,10},
		Image=ImageName,
		Normal=UpgradeRectNormal,
		Over=UpgradeRectOver,
		Pressed=UpgradeRectPressed,
		Disabled=UpgradeRectDisabled,


		AniSprDisabled=LockAniSprDisabled;
		
		
		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},

	{
		Name="BUILDING_TASK1",
		Type="Button",
		Pos={475+4, 11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskBuilding,
		AniSprOver=AniSprNormalTaskBuilding,
		AniSprPressed=AniSprPressedTaskBuilding,
		AniSprDisabled=AniSprDisabledTaskBuilding,

		--AniSprDisabled=AniSprLookDisabled;
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},
	
	{
		Name="BUILDING_TASK2",
		Type="Button",
		Pos={570,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskBuilding,
		AniSprOver=AniSprNormalTaskBuilding,
		AniSprPressed=AniSprPressedTaskBuilding,
		AniSprDisabled=AniSprDisabledTaskBuilding,

		--AniSprDisabled=AniSprLookDisabled;
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},
	
	{
		Name="BUILDING_TASK3",
		Type="Button",
		Pos={665-4,11},
		Image=ImageName,
		Normal=TaskNormal,
		Over=TaskOver,
		Pressed=TaskPressed,
		Disabled=TaskDisabled,

		AniSprNormal=AniSprNormalTaskBuilding,
		AniSprOver=AniSprNormalTaskBuilding,
		AniSprPressed=AniSprPressedTaskBuilding,
		AniSprDisabled=AniSprDisabledTaskBuilding,

		--AniSprDisabled=AniSprLookDisabled;
		Caption="", 
		TextNormal=ButtonTextNormalTask,
		TextOver=ButtonTextNormalTask,
		TextPressed=ButtonTextPressedTask,

	},

	{
		Name="TABBUILDING_BUY",
		Type="Button",
		Pos={564, 10},
		Image="Icons.jpg",
		Normal={152, 313, 246, 398},
		Over={340, 313, 434, 398},
		Pressed={340-1, 313-1, 434, 398},
		Disabled={246, 313, 340, 398},

		SprNormal=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprOver=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprPressed=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		
		SprDisabled=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 133, 785, 188},
		},
		
		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},
	
};

PanelRope=
{
    Pos={0,poxy},
    Image=ImageName,
	SrcRect={0, 99-1, 1024, 194},

    {    
        Name="TAB_ROPE_BUTTON",
        Type="Image",
        Image=ImageName,
        Pos={-3,-41},
        SrcRect={0, 682, 195, 726}, --srcrect таба
    },    

	--Веревка
	 {
		Name="ROPE_GARDEN_TEXT",
		Type="Text",    
		Caption = RopeNameText,
		Font="Font07.fnt",
		TextArea={20,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},
	

    {
        Name="ROPE_UPGRADE",
        Type="Button",
        Pos={230,10},
        Image=ImageName,
        Normal=UpgradeRectNormal,
        Over=UpgradeRectOver,
        Pressed=UpgradeRectPressed,
        Disabled=UpgradeRectDisabled,

        AniSprDisabled=LockAniSprDisabled;

        Caption="", 
        TextNormal=ButtonTextNormal,
        TextOver=ButtonTextNormal,
        TextPressed=ButtonTextPressed,
    },

	{
		Name="TABROPE_BUY",
		Type="Button",
		Pos={564,10},
		Image="Icons.jpg",
		Normal={152, 313, 246, 398},
		Over={340, 313, 434, 398},
		Pressed={340-1, 313-1, 434, 398},
		Disabled={246, 313, 340, 398},

		SprNormal=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprOver=
		{
			Pos={12,8},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		SprPressed=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 78, 785, 133},
		},
		
		SprDisabled=
		{
			Pos={13,9},
			Image="Icons.jpg",
			SrcRect={716, 133, 785, 188},
		},
		
		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},
};

--магазин
PanelShop=
{
    Pos={0,poxy},
    Image=ImageName,
	SrcRect={0, 200-1, 1024, 295},
    
	

	--Магазин
	[5]=
	{
		Name="SHOP_TEXT",
		Type="Text",    
		Caption = ShopNameText,
		Font="Font07.fnt",
		TextArea={27,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},

	[6]=
    {
        Name="TAB_SHOP_BUTTON",
        Type="Image",
        Image=ImageName,
        Pos={-3,-41},
        SrcRect={0, 726, 195, 770},
    },
	
	--иконка кошелька для вкладки магазина
	[7]=
    {
		Name="SHOP_ICON",
		Type="Image",
		Image=ImageName,
		Pos={19, -31},
		SrcRect={234, 873, 275, 907},
    },

    {
        Name="SHOP_UPGRADE",
        Type="Button",
        Pos={230,10},
        Image=ImageName,
        Normal=UpgradeRectNormal,
        Over=UpgradeRectOver,
        Pressed=UpgradeRectPressed,
        Disabled=UpgradeRectDisabled,

   
        AniSprDisabled=LockAniSprDisabled;

        Caption="", 
        TextNormal=ButtonTextNormal,
        TextOver=ButtonTextNormal,
        TextPressed=ButtonTextPressed,

    },


};

--копия панели магазина для панели магазинного склада
PanelShopStore = copy(emptyObj, PanelShop);
PanelShopStore[5].Name = "SHOPSTORE_TEXT";
PanelShopStore[5].Caption = ShopStoreNameText;
PanelShopStore[6].Name = "TAB_SHOPSTORE_BUTTON";
PanelShopStore[7].Name = "SHOPSTORE_ICON"
PanelShopStore[7].SrcRect = {275, 873, 316, 907}; --иконка для магазинного склада (лотка)

--склад
PanelStorehouse=
{
    Pos={0,poxy},
    Image=ImageName,
	SrcRect={0, 200-1, 1024, 295},

	--вкладка склада
    {
        Name="TAB_STOREHOUSE_BUTTON",
        Type="Image",
        Image=ImageName,
        Pos={-3,-41},
		SrcRect={0, 726, 195, 770},
    },

	--текст склада
	 {
		Name="STOREHOUSE_GARDEN_TEXT",
		Type="Text",    
		Caption = StorehouseNameText,
		Font="Font07.fnt",
		TextArea={23,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},

   	--иконка флага для вкладки склада
	{
		Name="STOREHOUSE_ICON",
		Type="Image",
		Image=ImageName,
		Pos={19, -31},
		SrcRect={234, 839, 269, 873},
	},

    {
        Name="STOREHOUSE_UPGRADE",
        Type="Button",
        Pos={230,10},
        Image=ImageName,
        Normal=UpgradeRectNormal,
        Over=UpgradeRectOver,
        Pressed=UpgradeRectPressed,
        Disabled=UpgradeRectDisabled,

        AniSprDisabled=LockAniSprDisabled;

        Caption="", 
        TextNormal=ButtonTextNormal,
        TextOver=ButtonTextNormal,
        TextPressed=ButtonTextPressed,

    },
	--кнопка перехода на покупку/продажу
	{
		Name="STOREHOUSE_SHOP",
		Type="Button",
		Pos={564,10},
		Image="Icons.jpg",
		Normal={687, 313, 781, 398},
		Over={781, 313, 875, 398},
		Pressed={781-1, 313-1, 875, 398},
	},

};


--панель персонажа для огорода
PanelGardener=
{
	Pos={0,poxy},
	Image=ImageName,
	SrcRect={0, 490, 1024, 586},
	
	--Вкладка 2 персонажа
	name1=
	{
		Name="TAB_GARDENER_CHARACTER_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={170-1,-41},
		SrcRect={0, 638, 195, 682},
	},


	--Вкладка 1 персонажа
	name2=
	{
		Name="TAB_GARDENER_BUILDING_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={-3,-41},
		SrcRect={0, 594, 195, 638},
	},
	
	--Вкладка текста огорода
	name3=
	{
		Name="CHAR_GARDEN_GARDEN_TEXT",
		Type="Text",    
		Caption = GardenNameText,
		Font="Font07.fnt",
		TextArea={20,-32, 200,0}, 
		SRatio=0.8,
		HAlign="center",
	},
	--Вкладка текста персонажа (производитель)
	name4=
	{
		Name="CHAR_GARDEN_CHAR_TEXT",
		Type="Text",    
		Caption = GardenerNameText,
		Font="Font07.fnt",
		TextArea={230, -32, 350, 0}, 
		SRatio=0.8,
		HAlign="center",
	},	

		
	{
		Name="CHAR_UPGRADE",
		Type="Button",
		Pos={230,10},
		Image=ImageName,
		Normal=UpgradeRectNormal,
		Over=UpgradeRectOver,
		Pressed=UpgradeRectPressed,
		Disabled=UpgradeRectDisabled,

		AniSprDisabled=LockAniSprDisabled;
	
		Caption="one_num", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},

	{
		Name="CHAR_SALE",
		Type="Button",
		Pos={895,10},
		Image=ImageName,
		Normal=SaleNormal,
		Over=SaleOver,
		Pressed=SalePressed,
		Disabled=SaleDisabled,

		Caption="one_num", 
		TextNormal=SaleTextNormal,
		TextOver=SaleTextNormal,
		TextPressed=SaleTextPressed,
	},
	
	{
		Name="CHAR_BUY",
		Type="Button",
		Pos={564,10},
		Image="Icons.jpg",
		Normal={152, 313, 246, 398},
		Over={340, 313, 434, 398},
		Pressed={340-1, 313-1, 434, 398},
		Disabled={246, 313, 340, 398},

		--анимационный спрайт вместо SprNormal
		AniSprNormal=
		{
			Pos={12,7},
			Image="Icons.jpg",
			
			Animation=
			{
				FramesList=
				{
					{431, 114, 500, 169}, --садовник активный
					{785, 78, 858, 133}, --мальчик активный
					{569, 114, 642, 169}, --фея активная
                };
            };
		},
		AniSprOver=
		{
			Pos={12,7},
			Image="Icons.jpg",
			Animation=
			{
				FramesList=
				{
					{431, 114, 500, 169}, --садовник активный
					{785, 78, 858, 133}, --мальчик активный
					{569, 114, 642, 169}, --фея активная
                };
            };
		},
		AniSprPressed=
		{
			Pos={13,8},
			Image="Icons.jpg",
			Animation=
			{
				FramesList=
				{
					{431, 114, 500, 169}, --садовник активный
					{785, 78, 858, 133}, --мальчик активный
					{569, 114, 642, 169}, --фея активная
				};
			};

		},
		AniSprDisabled=
		{
			Pos={13,8},
			Image="Icons.jpg",
			Animation=
			{
				FramesList=
				{
					{500, 114, 569, 169}, --садовник не активный
					{785, 133, 858, 188}, --мальчик не активный
					{642, 114, 715, 169}, --фея не активная
				};
			};

		},
		
		Caption="one_num", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},

	{
		Name="CHAR_CANCEL_BORDER",
		Type="Image",
		Image="Icons.jpg",
		Pos={455,53},
		SrcRect={310, 465, 620, 504},
	},
	{
		Name="CHAR_CANCEL_PROGRESS",
		Type="Image",
		Image="Icons.jpg",
		Pos={455,53},
		SrcRect={0, 465, 310, 504},
	},

	--заглушка на прогресс
	{
		Name="CHAR_CANCEL_PROGRESS_PANEL",
		Type="Image",
		Image="Icons.jpg",
		Pos={455,53},
		SrcRect={620, 465, 683, 504},
	},
	--кнопка "отмена продажи персонажа"
	{
		Name="CHAR_CANCEL_CHARACTER",
		Type="Button",
		Pos={892,10},
		Image="Icons.jpg",
		Normal={152, 313, 246, 398},
		Over={340, 313, 434, 398},
		Pressed={340-1, 313-1, 434, 398},
		Disabled={246, 313, 340, 398},

		SprNormal=
		{
			Pos={12,12},
			Image="Icons.jpg",
			SrcRect={875, 313, 941, 378},
		},
		SprOver=
		{
			Pos={12,12},
			Image="Icons.jpg",
			SrcRect={875, 313, 941, 378},
		},
		SprPressed=
		{
			Pos={13,13},
			Image="Icons.jpg",
			SrcRect={875, 313, 941, 378},
		},
		
--		Caption="Отмена", 
--		TextNormal=ButtonTextNormalCancel,
--		TextOver=ButtonTextNormalCancel,
--		TextPressed=ButtonTextPressedCancel,
	},
};

--править
--копия панели персонажа для рабочего у здания
PanelWorker=copy(emptyObj, PanelGardener);
--PanelWorker.name1.Name="TAB_WORKER_CHARACTER_BUTTON";
--PanelWorker.name2.Name="TAB_WORKER_BUILDING_BUTTON";
PanelWorker.name2.SrcRect = {0, 770, 195, 814};
--PanelWorker._1_tab_value_2.SrcRect = {0, 0, 1, 4};
PanelWorker.name3.Caption = ManufacturingNameText;
PanelWorker.name4.Caption = WorkerNameText;

--табличка покупки здания
PanelBuyTableBuilding=
{
	Pos={0,poxy},
	Image=ImageName,
	SrcRect={0, 306, 1024, 306 + 102},
	
	{
		Name="TAB_BUILDING_BUTTON",
		Type="Image",
		Image=ImageName,
		Pos={-3,-39},
		SrcRect={0, 890, 195, 890 + 44},
	},

	{
		Name="TABBUILDING_UPGRADE",
		Type="Button",
		Pos={230,11},
		Image=ImageName,
		Normal={617, 547, 686, 617},
		Over={673, 758, 742, 828},
		Pressed={673-1, 758-1, 742, 828},
		Disabled={742, 758, 811, 828},

		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},

};


--табличка покупки веревки
PanelBuyTableRope=
{
	Pos={84,poxy-1},
	Image=ImageName,
	SrcRect={0, 266, 835, 354},

	
--[[
	{
		Name="TABROPE_IMAGE",
		Type="Image",
		Image=ImageName,
		Pos={411,2},
		SrcRect={0, 537, 426, 625},
	},
	]]
	{
		Name="TABROPE_UPGRADE",
		Type="Button",
		Pos={16,18},
		Image=ImageName,
		Normal={617, 547, 686, 617},
		Over={673, 758, 742, 828},
		Pressed={673-1, 758-1, 742, 828},
		Disabled={742, 758, 811, 828},

		Caption="", 
		TextNormal=ButtonTextNormal,
		TextOver=ButtonTextNormal,
		TextPressed=ButtonTextPressed,
	},
};

--пустая панель
PanelEmpty=
{
    Pos={0,poxy},
    Image="Icons.jpg",
	SrcRect={0, 215, 1024, 311},
};

PicSelObj=
{
	Image="Icons.jpg",
	Animation=
	{
		FramesList=
		{
			{425, 394, 510, 471},--0 WATERWELL1
			{510, 394, 595, 471},--1 WATERWELL2
			{595, 394, 680, 471},--2 WATERWELL3
			{680, 317, 765, 394},--3 garden1
			{765, 317, 850, 394},--4 garden2
			{850, 317, 935, 394},--5 garden3
			{680, 394, 765, 471},--6 garden4
			{935, 317, 1020, 394},--7 garden5


			{0, 163, 85, 240},--8 mill1
			{85, 163, 170, 240},--9 mill2
			{170, 163, 255, 240},--10 mill3

			{765, 240, 850, 317},--11 rope
			{850, 240, 935, 317},--12 stairway
			{935, 240, 1020, 317},--13 stairway
			{0, 317, 85, 394},--14 teleport

			{255, 163, 340, 240},--15 Juicer1
			{340, 163, 425, 240},--16 Juicer2
			{425, 163, 510, 240},--17 Juicer3

			{0, 240, 85, 317},--18 TOMATOB1
			{85, 240, 170, 317},--19 TOMATOB2
			{170, 240, 255, 317},--20 TOMATOB3

			{255, 86, 340, 163},--21 ROASTER1
			{340, 86, 425, 163},--22 ROASTER2
			{425, 86, 510, 163},--23 ROASTER3

			{510, 86, 595, 163},--24 CONFECTIONERY1
			{595, 86, 680, 163},--25 CONFECTIONERY2
			{680, 86, 765, 163},--26 CONFECTIONERY3

			{765, 86, 850, 163},--27 BAKERY1
			{850, 86, 935, 163},--28 BAKERY2
			{935, 86, 1020, 163},--29 BAKERY3

			{510, 163, 595, 240},--30 OILB1
			{595, 163, 680, 240},--31 OILB2
			{680, 163, 765, 240},--32 OILB3

			{765, 163, 850, 240},--33 SANDWICHB1
			{850, 163, 935, 240},--34 SANDWICHB2
			{935, 163, 1020, 240},--35 SANDWICHB3

			{0, 86, 85, 163},--36 DOUGHB1
			{85, 86, 170, 163},--37 DOUGHB2
			{170, 86, 255, 163},--38 DOUGHB3

			{255, 240, 340, 317},--39 PACKING1
			{340, 240, 425, 317},--40 PACKING2
			{425, 240, 510, 317},--41 PACKING3

			{510, 240, 595, 317},--42 FRIEDPOTATOESB1
			{595, 240, 680, 317},--43 FRIEDPOTATOESB2
			{680, 240, 765, 317},--44 FRIEDPOTATOESB3

			{340, 317, 425, 394},--45 StoreHouse1 
			{425, 317, 510, 394},--46 StoreHouse 2
			{510, 317, 595, 394},--47 StoreHouse 3
			{595, 317, 680, 394},--48 StoreHouse 4

			{0, 394, 85, 471},--49 shop 1 
			{85, 394, 170, 471},--50 shop 2
			{170, 394, 255, 471},--51 shop 3
			{255, 394, 340, 471},--52 shop 4
			{340, 394, 425, 471},--53 shop 5
			
			{255, 317, 340, 394},--54 shop box 1
			{170, 317, 255, 394},--55 shop box 2
			{85, 317, 170, 394},--56 shop box 3

		};
	};

};


TopTaskPanel= ---- top task panel 
{
	Image="Icons.jpg",
	Animation=
	{
		FramesList=
		{
			{106, 471, 202, 510},
			{202, 471, 318, 510},
			{0, 471, 25, 510},---begin
			{25, 471, 105, 510},---end
		},
	},

};

--прямоугольничек закрывающий палочку на верхней нанели когда есть деньги в целях уровня
ClosingRod=
{
	Image="Icons.jpg",
	Pos = {70, 0},
	SrcRect={20, 0, 90,  30},
};

--галочка для вывода вместо текста при выполненном задании
CheckSprite=
{
	Image="Icons.jpg",
	Pos = {0, 0},
	SrcRect={788, 188, 814, 215},
};

TaskTable=
{
	Image=ImageName,
	--SrcRect={615,89,647,123},
	Animation=
	{
		FramesList=
		{
			{893, 887, 923, 918},---
			{926, 887, 956, 918},----
			{959, 887, 989, 918},----
			{992, 887, 1022, 918}----Lock
		},
	},

};


TaskTableObjList=
{
    Image="Icons.jpg",
    Animation=
    {
        FramesList=
        {
            {0, 78, 26, 105}, --1 морковь
            {26, 78, 52, 105}, --2 томат
            {78, 78, 104, 105}, --3 картофель
            {52, 78, 78, 105}, --4 подсолнух
            {104, 78, 130, 105}, --5 колос
            {0, 105, 26, 132}, --6 сок
			{26, 105, 52, 132}, --7 кетчуп
            {52, 105, 78, 132}, --8 масло
            {104, 105, 130, 132}, --9 мука
            {78, 105, 104, 132}, --10 упакованная картошка
            {104, 132, 130, 159}, --11 хлеб
            {78, 132, 104, 159}, --12 картофель фри

            {130, 105, 156, 132}, --13 тесто
            {0,0,0,0},-- 14 EGG
            {0,0,0,0},-- 15 MEAT
            {0, 132, 26, 159}, --16 котлета
            {0,0,0,0},-- 17 CREAM
            {26, 132, 52, 159}, -- 18 гумбургер
            {130, 159, 156, 186}, -- 19 пирог

            --water
            {0, 159, 26, 186}, --20 деревянное ведро воды
            {26, 159, 52, 186}, --21 металлическое ведро воды
            {52, 159, 78, 186}, --22 странное ведро воды

            --more
            {104, 159, 130, 186}, --23 хлеб и котлета
            {52, 132, 78, 159}, --24 картошка с маслом
            {78, 159, 104, 186}, --25 масло и мясо
            {130, 78, 156, 105}, --26 мука и яйца
            {130, 132, 156, 159}, --27 тесто и джем
     
            {0, 186, 26, 213}, --28 монетка
        };
    };

};


ButtonBuyCharacters=
{
	Image="Icons.jpg",
	Animation=
	{
		FramesList=
		{
			{0, 700, 68, 770},--23  Gardener but
			{68, 700, 137, 770},--24 sel Gardener but
			{68-1, 700-1, 137, 770},--25 pres Gardener but
			{137, 700, 206, 770},--26 dis Gardener but


			{0, 6, 69, 76},--27  boy but
			{69, 6, 138, 76},--28 sel boy but
			{69-1, 6-1, 138, 76},--29 pres boy but
			{138, 6, 207, 76},--30 dis boy but

			{617,267,686,337},--32  Fairy but
			{686,267,755,337},--33 sel Fairy but
			{686-1,267-1,755,337},--34 pres Fairy but

		},
	},
};


BuildingCharList=
{
	Image="Panel.jpg",
	Animation=
	{
		FramesList=
		{
			{816,348,875,407},
			{757,407,816,466},
		},
	},
};


UpgradeDots=
{
	Image="Panel.jpg",
	Animation=
	{
		FramesList=
		{
			{213, 832, 230, 848},
			{213, 814, 230, 830},
		},
	},
};


Medal=
{
    Image="Panel.jpg",
    Animation=
    {
        FramesList=
        {
            {934, 119, 1013, 154},
            {857, 119, 936, 154},
            {0,0,0,0},

        },
    },
};


PersPanelAnimSprite = 
{
    Image="Icons.jpg",
    Animation=
    {
        FramesList=
        {
            {156, 78, 196, 113},--рыжий
            {196, 78, 236, 113},--черненькая
            {236, 78, 276, 113},--принц
            {276, 78, 316, 113},--соня
            {316, 78, 356, 113},--солдат
            {356, 78, 396, 113},--вонючка
            {396, 78, 436, 113},--профессор
            {436, 78, 476, 113},--музыкант в красной шапке
            {476, 78, 516, 113},--толстый в синей шапке
            {516, 78, 556, 113},--принцесса
            {556, 78, 596, 113},--колдун с седой бородой
            {596, 78, 636, 113},--толстяк с русыми волосами
            {636, 78, 676, 113},--мадама
            {676, 78, 716, 113},--бабуля    
        },
    },
};