class 'l_10_Dead_ship_shore_Z_Treasure_spot' (ZoomZone)

function l_10_Dead_ship_shore_Z_Treasure_spot:__init(name, mode, PlayField)
	ZoomZone.__init(self, name, mode, PlayField)
	local tool_shovel = '09_shovel'
	local tool_key = '09_old_key'
	local tool_bag_of_gold = '10_bag_of_gold'

	-- links ---------------------------------------------------------------
	self.playfield:linkScene('area_link_zt_mg',  'CursorGlass',   '10_Chest')	

	-- apply_shovel -------------------------------------------------------------
	do 	
		local function on_apply_shovel(e)
			self:entityHide(e.target)
			self:entityShow('area_apply_old_key')

			if e.save then
				self:entityShow('zt_chest_closed')
			else
				self:entityFadeShow('zt_chest_closed')
			end
		end
		self:registerToolApplyInfo(tool_shovel, 'area_apply_shovel', on_apply_shovel, 'BBT_10_NEED_SHOVEL')
	end
	--------------------------------------------------------------------------

	-- apply_old_ke -------------------------------------------------------------
	do
		local function on_apply_old_key(e)
			self:entityHide(e.target)
			self:entityShow('area_link_zt_mg')

			if e.save then
				self:entityShow('zt_chest_opened')
				self:entityHide('zt_chest_closed')
			else
				self:entityFadeShow('zt_chest_opened')
				self:entityFadeHide('zt_chest_closed')
			end
		end
		self:registerToolApplyInfo(tool_key, 'area_apply_old_key', on_apply_old_key, 'BBT_10_NEED_OLD_KEY')
	end 
	--------------------------------------------------------------------------

end

--------------------------------------------------------------------------------
--                      GENERATED CONTENT. DO NOT EDIT.                       --
--------------------------------------------------------------------------------

function l_10_Dead_ship_shore_Z_Treasure_spot:CreateLoaderTable()
	local objects =
	{
		{ name = 'zt_bg',  entityType = 'SpriteEntity',  x = 512,  y = 384,  order = 0,  editingLocked = true,  treeItemIsExpanded = true,  texturePath = 'Data/Textures/Scenes/10_Dead_ship_shore/Z_Treasure_spot/zt_bg.jpg',  width = 640,  height = 480,  },
		{ name = 'zt_chest_closed',  entityType = 'SpriteEntity',  x = 632,  y = 436,  order = 5,  isVisible = false,  isRespondable = false,  editingLocked = true,  treeItemIsExpanded = true,  texturePath = 'Data/Textures/Scenes/10_Dead_ship_shore/Z_Treasure_spot/zt_chest_closed.png',  width = 398,  height = 376,  },
		{ name = 'zt_chest_opened',  entityType = 'SpriteEntity',  x = 632,  y = 436,  order = 10,  isVisible = false,  isRespondable = false,  editingLocked = true,  treeItemIsExpanded = false,  texturePath = 'Data/Textures/Scenes/10_Dead_ship_shore/Z_Treasure_spot/zt_chest_opened.png',  width = 398,  height = 376,  },
		{ name = 'zt_grass',  entityType = 'SpriteEntity',  x = 512,  y = 544,  order = 20,  isRespondable = false,  isActive = false,  editingLocked = true,  treeItemIsExpanded = false,  texturePath = 'Data/Textures/Scenes/10_Dead_ship_shore/Z_Treasure_spot/zt_grass.png',  width = 640,  height = 160,  },
		{ name = 'area_apply_shovel',  entityType = 'SpriteEntity',  x = 622,  y = 440,  order = 30,  scale = 25,  color = {r = 1, g = 1, b = 1, a = 0.00392157},  editingLocked = true,  treeItemIsExpanded = false,  width = 10,  height = 10,  },
		{ name = 'area_apply_old_key',  entityType = 'SpriteEntity',  x = 659.248,  y = 445.278,  order = 28,  isVisible = false,  isRespondable = false,  isActive = false,  scaleX = 14,  scaleY = 10,  color = {r = 1, g = 1, b = 1, a = 0.00392157},  editingLocked = true,  treeItemIsExpanded = false,  width = 10,  height = 10,  },
		{ name = 'area_link_zt_mg',  entityType = 'SpriteEntity',  x = 616,  y = 406,  order = 28,  isVisible = false,  isRespondable = false,  isActive = false,  angle = -38,  scaleX = 16,  scaleY = 14,  color = {r = 1, g = 1, b = 1, a = 0.00392157},  editingLocked = true,  treeItemIsExpanded = false,  width = 10,  height = 10,  },
	}
	return objects
end
