<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<Mission xmlns="http://ProjectMalmo.microsoft.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <About>
        <Summary>MineRLNavigateDenseFixed-v0</Summary>
    </About>

    <ModSettings>
        <MsPerTick>50</MsPerTick>
    </ModSettings>

    <ServerSection>
        <ServerInitialConditions>
            <Time>
                <StartTime>6000</StartTime>
                <AllowPassageOfTime>false</AllowPassageOfTime>
            </Time>

            <Weather>clear</Weather>
            <AllowSpawning>false</AllowSpawning>
        </ServerInitialConditions>
        <ServerHandlers>
            <FileWorldGenerator src="$(MISSIONS_DIR)/forest_survival" destroyAfterUse="true"/>
            <NavigationDecorator>
                <randomPlacementProperties>
                    <maxRandomizedRadius>64</maxRandomizedRadius>
                    <minRandomizedRadius>64</minRandomizedRadius>
                    <maxRadius>8</maxRadius>
                    <minRadius>0</minRadius>
                    <block>diamond_block</block>
                    <placement>fixed_surface</placement>
                </randomPlacementProperties>
                <minRandomizedDistance>0</minRandomizedDistance>
                <maxRandomizedDistance>8</maxRandomizedDistance>
                <randomizeCompassLocation>false</randomizeCompassLocation>
                <!--            TODO set random placement seed to disable randomness-->
            </NavigationDecorator>
            <ServerQuitFromTimeUp timeLimitMs="300000" description="out_of_time"/>
            <ServerQuitWhenAnyAgentFinishes/>
        </ServerHandlers>
    </ServerSection>

    <AgentSection mode="Survival">
        <Name>MineRLAgent</Name>
        <AgentStart>
            <Placement x="-22" y="61" z="278" yaw="134" pitch="22.2"/>
            <Inventory>
                <InventoryObject slot="0" type="compass" quantity="1"/>
            </Inventory>
        </AgentStart>
        <AgentHandlers>

            <VideoProducer want_depth="false">
                <Width>64</Width>
                <Height>64</Height>
            </VideoProducer>
            <FileBasedPerformanceProducer/>

            <ObservationFromFullInventory flat="false"/>
            <ObservationFromFullStats/>
            <HumanLevelCommands/>
            <PlaceCommands/>
            <CameraCommands/>
            <ObservationFromCompass/>

            <RewardForMissionEnd>
                <Reward description="out_of_time" reward="0"/>
            </RewardForMissionEnd>
            <AgentQuitFromTouchingBlockType>
                <Block type="diamond_block"/>
            </AgentQuitFromTouchingBlockType>
            <RewardForTouchingBlockType>
                <Block reward="100.0" type="diamond_block" behaviour="onceOnly"/>
            </RewardForTouchingBlockType>
            <RewardForDistanceTraveledToCompassTarget rewardPerBlock="1" density="PER_TICK"/>
            <PauseCommand/>
        </AgentHandlers>
    </AgentSection>
</Mission>
