-- LocConciergeDesk

LocConciergeDesk = Location:new("LocConciergeDesk")

----------------------------------------------------------------------------------------------------
function LocConciergeDesk_UPDATE()
	return 0
end

----------------------------------------------------------------------------------------------------
function LocConciergeDesk_INIT()
    LocConciergeDesk:init()
end

----------------------------------------------------------------------------------------------------
LocConciergeDesk:setSceneHandler(1,
     function(aScene, aEvent)
        if aEvent == "capture" then
            aScene:captureObjects({'flash_drive', 'white_gloves'})
        elseif aEvent == "generic_init" then
            
                     
            aScene:setHidsParams({'flash_drive'}, {inventory = true})
            aScene:setWinTerms({"ho_collected", "activate_computer"})

        elseif aEvent == "start" then
			aScene:setRemark('ids_remark_locconciergedesk_1') 
            aScene:attachHids(aScene:getHidList())
            aScene:attachInteract("computer", "flash_drive")
            aScene:setTask("ids_challenge_locconciergedesk_1")
            
        elseif aEvent == "activate_computer" then
            aScene:onChallengeComplete()
            aScene:setTask("ids_collect_ho")
        end
    end)

----------------------------------------------------------------------------------------------------
LocConciergeDesk:setSceneHandler(2,
    function(aScene, aEvent)
        if aEvent == "capture" then
            aScene:captureObjects({'cup', 'arrow'})
        elseif aEvent == "generic_init" then
            
            aScene:setHidsParams({'cup'}, {inventory = true})
            aScene:setWinTerms({"ho_collected", "activate_papers"})

        elseif aEvent == "start" then
            aScene:attachHids(aScene:getHidList())
            aScene:attachInteract('papers', 'cup')
            aScene:setTask("ids_challenge_locconciergedesk_2")
            aScene:setRemark('ids_remark_locconciergedesk_2')

        elseif aEvent == "activate_papers" then
            aScene:onChallengeComplete()
            aScene:setTask("ids_collect_ho")

        end
    end)

----------------------------------------------------------------------------------------------------
LocConciergeDesk:setSceneHandler(3,
    function(aScene, aEvent)
        if aEvent == "capture" then
            aScene:captureObjects({'newspaper', 'watch', 'glasses'})
        elseif aEvent == "generic_init" then
            
            
            aScene:setHidsParams({'newspaper'}, {inventory = true})
            aScene:setWinTerms({"ho_collected", "activate_shredder"})

        elseif aEvent == "start" then
            aScene:attachHids(aScene:getHidList())
            aScene:attachInteract('shredder', 'newspaper')
            aScene:setTask("ids_challenge_locconciergedesk_3")
            aScene:setRemark('ids_remark_locconciergedesk_3')

        elseif aEvent == "activate_shredder" then
            aScene:onChallengeComplete()
            aScene:setTask("ids_collect_ho")

        end
    end)

----------------------------------------------------------------------------------------------------
LocConciergeDesk:setSceneHandler(4,
    function (aScene, aEvent)

        -- capture hat
        -- film_roll active,click(pen -> balloon)

        if aEvent == "capture" then
            aScene:captureObjects({'hat', 'pen', 'film_roll', 'headset', 'trident', 'flowers'})
        elseif aEvent == "generic_init" then
            
            aScene:setWinTerms({"ho_collected", "activate_balloon"})
            aScene:setHidsParams({'pen'}, {inventory = true})
            aScene:setHidsParams({'film_roll'}, {active = false})

        elseif aEvent == "start" then
        
            aScene:setRemark('ids_remark_locconciergedesk_4')
            aScene:setTask("ids_challenge_locconciergedesk_4")
            aScene:attachHids(aScene:getHidList())
            aScene:attachInteract('balloon', 'pen')

        elseif aEvent == "activate_balloon" then
            aScene:setHidsParams({'film_roll'}, {active = true})
            ho:click('hid_4_film_roll')
            aScene:onChallengeComplete()
            aScene:setTask("ids_collect_ho")

        end
    end)

----------------------------------------------------------------------------------------------------
LocConciergeDesk:setSceneHandler(5,
    function(aScene, aEvent)

        -- lipstick_conc -> aquarium

        if aEvent == "capture" then
            aScene:captureObjects({'lipstick_conc'})
        elseif aEvent == "generic_init" then
            
            aScene:setWinTerms({"ho_collected", "activate_aquarium"})
            aScene:setHidsParams({'lipstick_conc'}, {inventory = true})

        elseif aEvent == "start" then
        
            aScene:setRemark('ids_remark_locconciergedesk_5')
            aScene:setTask("ids_challenge_locconciergedesk_5")
            aScene:attachHids(aScene:getHidList())
            aScene:attachInteract('aquarium', 'lipstick_conc')

        elseif aEvent == "activate_aquarium" then
            aScene:onChallengeComplete()
            aScene:setTask("ids_collect_ho")

        end
    end)
