local zoom_chest;

function auxCloseZoomChest()
    if zoom_chest.IsVisible() then
        zoom_chest.SetVisible(false);
    end
    zoom_chest.Disable();
end

function OnSceneLoad(screen)
    LoadData(screen)
    DefaultOnSceneLoad('data/Scenes/13_Crimeplace_Main_HO.lua', 'hidden_object', 'data/Scenes/13_Crimeplace_Main.lua')
    
    play_field:IgnoreOnTestPoint('BG_Chest');
    play_field:IgnoreOnTestPoint('BG_Listok1');
    
    play_field:GetObject('picture_anim1'):GetAnimation():SetMode(HGEANIM_FWD + HGEANIM_NOLOOP);
    play_field:GetObject('picture_anim2'):GetAnimation():SetMode(HGEANIM_FWD + HGEANIM_NOLOOP);
    play_field:GetObject('picture_anim1'):GetAnimation():Stop();
    play_field:GetObject('picture_anim2'):GetAnimation():Stop();
    play_field:GetObject('picture_anim2'):SetVisible(false);
    play_field:GetObject('BG_Chest'):SetOpacity(0);
    play_field:GetObject('area_chest_open'):SetVisible(false);
    
    play_field:GetObject('Nail'):SetOpacity(0.);
    
    AddTask(CreateTask('STONE',  '',        'Stone'));
    AddTask(CreateTask('BOW',    'BOWS',    'Bow1',    'Bow2',    'Bow3', 'Bowknot1', 'Bowknot2', 'Bowknot3'));
    AddTask(CreateTask('PISTOL', 'PISTOLS', 'Pistol1', 'Pistol2', 'Pistol3'));
    AddTask(CreateTask('NAIL',   '',        'Nail'));
    
    AddRandomTasks( CreateTask('BELL',         'BELLS',        'Bell1', 'Bell2', 'Bell3'),
                    CreateTask('RING',         'RINGS',        'Ring1', 'Ring2', 'Ring3'),
                    CreateTask('BRANCH',       '',             'Branch'),
                    CreateTask('CANDLESTICK',  '',             'Candlestick'),
                    CreateTask('LONG_BOX',     '',             'Casket'),
                    CreateTask('CAT',          '',             'Cat'),
                    CreateTask('CLOCK',        '',             'Clock'),
                    CreateTask('CLOWN',        '',             'Clown'),
                    CreateTask('COFFEE_GRINDER', '',           'CoffeeGrinder'),
                    CreateTask('FLOWERPOT',    '',             'Flowerpot'),
                    CreateTask('GOLF_DRIVER',  'GOLF_DRIVERS', 'GolfDriver1', 'GolfDriver2', 'GolfDriver3'),
                    CreateTask('GRIPSACK',     '',             'Gripsack'),
                    CreateTask('LEAF',         'LEAFS',        'Leaf1', 'Leaf2', 'Leaf3'),
                    CreateTask('LION',         '',             'Lion'),
                    CreateTask('LOCOMOTIVE',   '',             'Locomotive'),
                    CreateTask('MANDOLIN',     '',             'Mandolin'),
                    CreateTask('MASK',         '',             'Mask'),
                    CreateTask('NECKLACE',     '',             'Necklace'),
                    CreateTask('PHONE',        '',             'Phone'),
                    CreateTask('DOVES',        '',             'Pigeons'), 
                    CreateTask('PIPE',         '',             'Pipe'),
                    CreateTask('PLATE',        '',             'Plate'),
                    CreateTask('SCALES',       '',             'Scales'),
                    CreateTask('SHOE',         '',             'Shoe'),
                    CreateTask('SMALL_BAG',    '',             'SmallBag'),
                    CreateTask('WALKING_STICK','',             'Stick'),
                    CreateTask('TOPHAT',       '',             'TopHat'),
                    CreateTask('UMBRELLA',     '',             'Umbrella'),
                    CreateTask('UNICORN',      '',             'Unicorn'),
                    CreateTask('VASE',         '',             'Vase'));
    
    RegisterActiveObject('area_pict',           function(obj_name)
                                                    play_field:GetObject(obj_name):SetVisible(false);
                                                    play_field:GetObject('Nail'):SetOpacity(1.);
                                                    
                                                    PlaySound('13_Painting_Fall');
                                                    
                                                    StartPictureAnimation();
                                                end,
                                                function(obj_name)
                                                    play_field:GetObject(obj_name):SetVisible(false);
                                                    play_field:GetObject('picture_anim1'):SetVisible(false);
                                                    play_field:GetObject('Nail'):SetOpacity(1.);
                                                end);
    
    RegisterActiveObject('area_chest_close',    function(obj_name)
                                                    play_field:GetObject('area_chest_close'):SetVisible(false);
                                                    play_field:GetObject('area_chest_open' ):SetVisible(true);
                                                    play_field:GetObject('BG_Chest'):ChangeOpacity(0, 1, OPEN_DOOR_TIME);
                                                    
                                                    PlaySound('13_OpenShelf')
                                                end,
                                                function(obj_name)
                                                    play_field:GetObject('area_chest_close'):SetVisible(false);
                                                    play_field:GetObject('area_chest_open' ):SetVisible(true);
                                                    play_field:GetObject('BG_Chest'):SetOpacity(1);
                                                end);
    
    zoom_chest = CreateZoomZone('area_chest_open',
                                'CloseZoneChest',
                                'ZOOM_chest',       true,
                                'Stone',            true);
    
    local state_value = game_state.scene_path.."(Stone)"
    if HasGameState("TaskObjectFound", state_value) then
        zoom_chest.Disable();
    end
    
    RegisterToolFindInfo('13_stone');
end

function StartPictureAnimation()
    local anim1 = play_field:GetObject('picture_anim1'):GetAnimation();
    
    anim1:Play();
    
    TimerDoString("PictureAnimationPart2()", GetAnimationLength(anim1), play_field:GetTimer());
end

function PictureAnimationPart2()
    local anim2 = play_field:GetObject('picture_anim2'):GetAnimation();
    
    play_field:GetObject('picture_anim1'):SetVisible(false);
    play_field:GetObject('picture_anim2'):SetVisible(true);
    
    anim2:Play();
    
    TimerDoString("play_field:GetObject('picture_anim2'):SetVisible(false)", GetAnimationLength(anim2), play_field:GetTimer());
end

function OnSceneFree(screen)
    DefaultOnSceneFree()
    FreeData(screen)
end

function OnUpdate(dt)
    DefaultOnUpdate(dt)
end

function OnAllItemsFound()
    DefaultOnAllItemsFound()
end

function OnLose()
    DefaultOnLose()
end

function OnExit()
    DefaultOnExit()
end

function OnClose()
    DefaultOnClose()
end

function OnObjectMouseEnter(object)
    DefaultOnObjectMouseEnter(object)
end

function OnObjectMouseLeave(object)
    DefaultOnObjectMouseLeave(object)
end

function OnObjectMouseDown(object)
    local is_wrong_click = not DefaultOnObjectMouseDown(object)
    local obj_name = object:GetName()
    local pf = play_field

    DefaultOnObjectMouseDownProcessed(is_wrong_click);
end

function OnObjectMouseUp(object)
    DefaultOnObjectMouseUp(object)
end

function OnObjectFound(object)
    if object:GetName() == 'Stone' then
        TimerDoString('auxCloseZoomChest()', 1, play_field:GetTimer())
    end
    
    DefaultOnObjectFound(object)
end

function OnToolFound(tool)
    DefaultOnToolFound(tool)
end

function OnToolApply(tool, object)
    DefaultOnToolApply(tool, object)
end

function OnObjectReachPanel(object)
    DefaultOnObjectReachPanel(object)
end

function OnButtonPress(title)
    DefaultOnButtonPress(title)
end

function OnMouseMove(previous_pos, current_pos)
    DefaultOnMouseMove(previous_pos, current_pos)
end

function OnSetTool(tool)
    DefaultOnSetTool(tool)
end

function LevelLoaded(level)
end

function OnSceneDestroy(playfield)
    DefaultOnSceneDestroy(playfield)
end

--------------------------------------------------------------------------------
-- CLEAR_ON_SAVE_BEGIN
-- Do not edit code listed below (generated by the editor on each save)
function LoadData(screen)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/background.jpg',0,0,1024,768,1,0)
	anim:SetHotSpot(512,384)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('background',anim,512,384,97,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bell1.png',0,0,52,177,1,0)
	anim:SetHotSpot(26,88)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bell1',anim,604,117,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bell2.png',0,0,79,45,1,0)
	anim:SetHotSpot(39,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bell2',anim,320,568,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bell3.png',0,0,38,40,1,0)
	anim:SetHotSpot(19,20)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bell3',anim,636,556,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Book.png',0,0,120,69,1,0)
	anim:SetHotSpot(60,34)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Book',anim,163,639,104,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Books.png',0,0,72,59,1,0)
	anim:SetHotSpot(36,29)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Books',anim,834,590,105,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bow1.png',0,0,170,164,1,0)
	anim:SetHotSpot(85,82)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bow1',anim,916,496,106,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bow2.png',0,0,44,46,1,0)
	anim:SetHotSpot(22,23)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bow2',anim,495,547,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bow3.png',0,0,51,48,1,0)
	anim:SetHotSpot(25,24)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bow3',anim,193,412,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bowknot1.png',0,0,54,53,1,0)
	anim:SetHotSpot(27,26)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bowknot1',anim,538,326,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bowknot2.png',0,0,87,35,1,0)
	anim:SetHotSpot(43,17)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bowknot2',anim,258,650,104,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Bowknot3.png',0,0,53,63,1,0)
	anim:SetHotSpot(26,31)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Bowknot3',anim,405,66,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Branch.png',0,0,126,76,1,0)
	anim:SetHotSpot(63,38)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Branch',anim,678,240,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Candlestick.png',0,0,82,115,1,0)
	anim:SetHotSpot(41,57)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Candlestick',anim,129,526,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Casket.png',0,0,140,62,1,0)
	anim:SetHotSpot(70,31)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Casket',anim,490,638,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Cat.png',0,0,77,72,1,0)
	anim:SetHotSpot(38,36)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Cat',anim,408,563,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Clock.png',0,0,99,49,1,0)
	anim:SetHotSpot(49,24)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Clock',anim,135,598,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Clown.png',0,0,75,86,1,0)
	anim:SetHotSpot(37,43)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Clown',anim,199,548,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/CoffeeGrinder.png',0,0,73,79,1,0)
	anim:SetHotSpot(36,39)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('CoffeeGrinder',anim,80,599,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Flowerpot.png',0,0,90,94,1,0)
	anim:SetHotSpot(45,47)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Flowerpot',anim,44,523,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/GolfDriver1.png',0,0,36,184,1,0)
	anim:SetHotSpot(18,92)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('GolfDriver1',anim,96,486,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/GolfDriver2.png',0,0,126,215,1,0)
	anim:SetHotSpot(63,107)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('GolfDriver2',anim,945,592,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/GolfDriver3.png',0,0,278,60,1,0)
	anim:SetHotSpot(139,30)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('GolfDriver3',anim,378,452,101,90,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Gripsack.png',0,0,132,104,1,0)
	anim:SetHotSpot(66,52)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Gripsack',anim,932,637,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Leaf1.png',0,0,39,45,1,0)
	anim:SetHotSpot(19,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Leaf1',anim,131,309,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Leaf2.png',0,0,39,54,1,0)
	anim:SetHotSpot(19,27)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Leaf2',anim,846,490,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Leaf3.png',0,0,56,44,1,0)
	anim:SetHotSpot(28,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Leaf3',anim,595,229,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Lion.png',0,0,72,68,1,0)
	anim:SetHotSpot(36,34)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Lion',anim,557,449,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Locomotive.png',0,0,100,64,1,0)
	anim:SetHotSpot(50,32)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Locomotive',anim,250,571,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Mandolin.png',0,0,106,189,1,0)
	anim:SetHotSpot(53,94)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Mandolin',anim,759,520,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Mask.png',0,0,45,109,1,0)
	anim:SetHotSpot(22,54)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Mask',anim,774,388,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Nail.png',0,0,35,33,1,0)
	anim:SetHotSpot(17,16)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Nail',anim,890,95,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Necklace.png',0,0,105,44,1,0)
	anim:SetHotSpot(52,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Necklace',anim,327,625,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Note1.png',0,0,58,72,1,0)
	anim:SetHotSpot(29,36)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Note1',anim,850,571,104,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Note2.png',0,0,55,50,1,0)
	anim:SetHotSpot(27,25)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Note2',anim,659,120,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Note3.png',0,0,54,51,1,0)
	anim:SetHotSpot(27,25)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Note3',anim,47,442,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Phone.png',0,0,66,92,1,0)
	anim:SetHotSpot(33,46)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Phone',anim,486,353,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Pigeons.png',0,0,114,45,1,0)
	anim:SetHotSpot(57,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Pigeons',anim,190,70,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Pipe.png',0,0,54,53,1,0)
	anim:SetHotSpot(27,26)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Pipe',anim,40,591,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Pistol1.png',0,0,107,30,1,0)
	anim:SetHotSpot(53,15)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Pistol1',anim,75,218,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Pistol2.png',0,0,111,24,1,0)
	anim:SetHotSpot(55,12)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Pistol2',anim,310,598,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Pistol3.png',0,0,81,59,1,0)
	anim:SetHotSpot(40,29)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Pistol3',anim,552,281,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Plate.png',0,0,111,49,1,0)
	anim:SetHotSpot(55,24)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Plate',anim,226,616,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Ring1.png',0,0,33,28,1,0)
	anim:SetHotSpot(16,14)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Ring1',anim,819,625,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Ring2.png',0,0,30,23,1,0)
	anim:SetHotSpot(15,11)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Ring2',anim,463,605,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Ring3.png',0,0,36,20,1,0)
	anim:SetHotSpot(18,10)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Ring3',anim,692,384,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Scales.png',0,0,127,123,1,0)
	anim:SetHotSpot(63,61)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Scales',anim,570,609,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Shoe.png',0,0,75,69,1,0)
	anim:SetHotSpot(37,34)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Shoe',anim,640,619,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/SmallBag.png',0,0,101,63,1,0)
	anim:SetHotSpot(50,31)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('SmallBag',anim,787,595,106,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Stick.png',0,0,50,246,1,0)
	anim:SetHotSpot(25,123)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Stick',anim,728,512,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/TopHat.png',0,0,170,126,1,0)
	anim:SetHotSpot(85,63)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('TopHat',anim,944,465,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Umbrella.png',0,0,151,119,1,0)
	anim:SetHotSpot(75,59)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Umbrella',anim,715,609,104,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Unicorn.png',0,0,121,102,1,0)
	anim:SetHotSpot(60,51)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Unicorn',anim,389,612,104,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Items/Vase.png',0,0,63,141,1,0)
	anim:SetHotSpot(31,70)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('Vase',anim,722,568,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Bant2.png',0,0,28,26,1,0)
	anim:SetHotSpot(14,13)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Bant2',anim,492,532,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Galstuk-babochka3.png',0,0,17,15,1,0)
	anim:SetHotSpot(8,7)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Galstuk-babochka3',anim,399,55,105,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Golubi.png',0,0,106,35,1,0)
	anim:SetHotSpot(53,17)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Golubi',anim,185,84,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Kolokolchik2.png',0,0,28,28,1,0)
	anim:SetHotSpot(14,14)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Kolokolchik2',anim,735,657,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Koshka.png',0,0,36,38,1,0)
	anim:SetHotSpot(18,19)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Koshka',anim,433,585,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Listok1.png',0,0,35,53,1,0)
	anim:SetHotSpot(17,26)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Listok1',anim,144,310,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Mandolina.png',0,0,73,89,1,0)
	anim:SetHotSpot(36,44)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Mandolina',anim,787,577,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Pistolet3.png',0,0,51,45,1,0)
	anim:SetHotSpot(25,22)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Pistolet3',anim,572,294,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Telefon.png',0,0,74,23,1,0)
	anim:SetHotSpot(37,11)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Telefon',anim,480,393,102,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Vaza.png',0,0,66,63,1,0)
	anim:SetHotSpot(33,31)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Vaza',anim,745,621,105,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Vetka eli.png',0,0,40,81,1,0)
	anim:SetHotSpot(20,40)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Vetka eli',anim,880,632,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Animations/picture_anim1.png',0,0,358,597,15,16)
	anim:SetHotSpot(179,298)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('picture_anim1',anim,825,343,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Animations/picture_anim2.png',0,0,358,597,10,16)
	anim:SetHotSpot(179,298)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('picture_anim2',anim,845,349,101,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/Common/area.png',0,0,8,8,1,0)
	anim:SetHotSpot(4,4)
	anim:SetBlendMode(2)
	anim:SetColor('0x01FFFFFF')
	screen:CreateObject('area_pict',anim,880,108,105,0,18,16)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Chest.png',0,0,333,127,1,0)
	anim:SetHotSpot(166,63)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Chest',anim,553,502,103,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/Common/area.png',0,0,8,8,1,0)
	anim:SetHotSpot(4,4)
	anim:SetBlendMode(2)
	anim:SetColor('0x01FFFFFF')
	screen:CreateObject('area_chest_close',anim,556,501,104,0,30,6)
	local anim = CreateAnimation('data/Texture/Scenes/Common/area.png',0,0,8,8,1,0)
	anim:SetHotSpot(4,4)
	anim:SetBlendMode(2)
	anim:SetColor('0x01FFFFFF')
	screen:CreateObject('area_chest_open',anim,556,501,105,0,30,6)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Zoom_chest/ZOOM_chest.jpg',0,0,640,480,1,0)
	anim:SetHotSpot(320,240)
	anim:SetBlendMode(2)
	anim:SetColor('0x00FFFFFF')
	screen:CreateObject('ZOOM_chest',anim,512,384,150,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Zoom_chest/stone_layer.png',0,0,137,90,1,0)
	anim:SetHotSpot(68,45)
	anim:SetBlendMode(2)
	anim:SetColor('0x00FFFFFF')
	screen:CreateObject('Stone',anim,540,403,151,0,1,1)
	local anim = CreateAnimation('data/Texture/Scenes/13_Crimeplace/Zone_HO/Layers/BG_Nail.png',0,0,26,30,1,0)
	anim:SetHotSpot(13,15)
	anim:SetBlendMode(2)
	anim:SetColor('0xFFFFFFFF')
	screen:CreateObject('BG_Nail',anim,899,102,102,0,1,1)
end

function FreeData(screen)
end
-- CLEAR_ON_SAVE_END
