<?xml version="1.0" encoding="utf-8" standalone="no" ?>
<vehicle type="cutter" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../shared/xml/schema/vehicle.xsd">
    <annotation>Copyright (C) GIANTS Software GmbH, All Rights Reserved.</annotation>

    <storeData>
        <name params="$l10n_storeItem_header">MF 8570 %s</name>
        <specs>
            <workingWidth>6.0</workingWidth>
            <combination xmlFilename="$data/vehicles/masseyFerguson/mf8570/mf8570.xml"/>
            <combination xmlFilename="$data/vehicles/masseyFerguson/mf8570Trailer/mf8570Trailer.xml"/>
        </specs>
        <functions>
            <function>$l10n_function_cutter</function>
        </functions>
        <storePacks>
            <storePack>STARTER_GRAINS</storePack>
            <storePack>STARTER_RICELONGGRAIN</storePack>
        </storePacks>
        <image>$data/vehicles/masseyFerguson/mf8570Header/store_mf8570Header.png</image>
        <price>30000</price>
        <lifetime>600</lifetime>
        <rotation>0</rotation>
        <brand>MASSEYFERGUSON</brand>
        <category>cutters</category>
        <shopTranslationOffset>0 -0.011 0</shopTranslationOffset>
        <shopRotationOffset>-0.643 0 0</shopRotationOffset>
        <vertexBufferMemoryUsage>2031104</vertexBufferMemoryUsage>
        <indexBufferMemoryUsage>916992</indexBufferMemoryUsage>
        <textureMemoryUsage>917504</textureMemoryUsage>
        <instanceVertexBufferMemoryUsage>0</instanceVertexBufferMemoryUsage>
        <instanceIndexBufferMemoryUsage>0</instanceIndexBufferMemoryUsage>
        <audioMemoryUsage>0</audioMemoryUsage>
    </storeData>

    <base>
        <typeDesc>$l10n_typeDesc_cutter</typeDesc>
        <filename>$data/vehicles/masseyFerguson/mf8570Header/mf8570Header.i3d</filename>
        <size width="6.8" length="3.45" height="1.85"/>
        <speedLimit value="15"/>
        <components>
            <component centerOfMass="0 0.2 -0.5" solverIterationCount="10" mass="1700"/>
        </components>
        <schemaOverlay attacherJointPosition="0 0" name="COMBINE_HEADER"/>
        <mapHotspot type="CUTTER"/>
    </base>

    <powerConsumer ptoRpm="470" neededMaxPtoPower="50"/>

    <groundReferenceNodes>
        <groundReferenceNode node="heightNode02" threshold="0.5"/>
    </groundReferenceNodes>

    <workAreas>
        <workArea type="cutter" functionName="processCutterArea">
            <area startNode="workAreaStart" widthNode="workAreaWidth" heightNode="workAreaHeight"/>
            <groundReferenceNode index="1"/>
            <testAreas autoGenerate="true" zOffset="0.5" xOffset="0" length="0.6" numAreas="8" areaWidthScale="0.25"/>
        </workArea>
    </workAreas>

    <attachable>
        <inputAttacherJoints>
            <inputAttacherJoint node="attacherJoint" jointType="cutter">
                <heightNode node="heightNode01"/>
                <heightNode node="heightNode02"/>
                <heightNode node="heightNode03"/>
                <distanceToGround lower="0.27" upper="1.3"/>
            </inputAttacherJoint>
        </inputAttacherJoints>
    </attachable>

    <connectionHoses>
        <hose inputAttacherJointIndices="1" type="hydraulicIn" node="hydraulicIn01" length="0.5" diameter="0.025" isTwoPointHose="true" socket="hydraulicIn01_connector">
            <objectChange node="hydraulicIn01_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
        <hose inputAttacherJointIndices="1" type="hydraulicOut" node="hydraulicOut01" length="0.5" diameter="0.025" isTwoPointHose="true" socket="hydraulicOut01_connector">
            <objectChange node="hydraulicOut01_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
        <hose inputAttacherJointIndices="1" type="hydraulicIn" node="hydraulicIn02" length="0.5" diameter="0.025" isTwoPointHose="true" socket="hydraulicIn02_connector">
            <objectChange node="hydraulicIn02_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
        <hose inputAttacherJointIndices="1" type="hydraulicOut" node="hydraulicOut02" length="0.5" diameter="0.035" isTwoPointHose="true" socket="hydraulicOut02_connector">
            <objectChange node="hydraulicOut02_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
        <hose inputAttacherJointIndices="1" type="hydraulicIn" node="hydraulicIn03" length="0.5" diameter="0.035" isTwoPointHose="true" socket="hydraulicIn03_connector">
            <objectChange node="hydraulicIn03_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
    </connectionHoses>

    <animations>
        <animation name="turnedOnAnim" looping="true" isKeyframe="true">
            <part node="cutterRotate" startTime="0.0" endTime="0.5" startRot="0 -13 0" endRot="0 13 0"/>
            <part node="cutterRotate" startTime="0.5" endTime="1.0" startRot="0 13 0" endRot="0 -13 0"/>

            <part node="cutterMove" startTime="0.0" endTime="0.5" startRot="0 13 0" endRot="0 -13 0"/>
            <part node="cutterMove" startTime="0.5" endTime="1.0" startRot="0 -13 0" endRot="0 13 0"/>
        </animation>

        <animation name="cropDividersAnim" isKeyframe="true">
            <part node="colCropDividerLeft" startTime="0.0" endTime="0.01" startRot="0 -90 0" endRot="0 0 0"/>
            <part node="colCropDividerRight" startTime="0.0" endTime="0.01" startRot="0 90 0" endRot="0 0 0"/>
        </animation>
    </animations>

    <cylindered>
        <movingTools>
            <movingTool node="reelMove" playSound="true">
                <controls axis="AXIS_CUTTER_REEL" invertAxis="true" mouseSpeedFactor="0.3" iconName="REEL_TRANSLATE_X"/>
                <translation transSpeed="0.2" transAcceleration="10" transMin="-0.1" transMax="0.28" translationAxis="3" startTrans="0"/>
            </movingTool>

            <movingTool node="reelRotate" playSound="true">
                <controls axis="AXIS_CUTTER_REEL2" invertAxis="true" mouseSpeedFactor="0.3" iconName="REEL_TRANSLATE_Y"/>
                <rotation rotSpeed="10" rotAcceleration="80" rotMin="-22" rotMax="0" rotationAxis="1" startRot="-22"/>
                <dependentPart node="reelRotateHydraulic"/>
            </movingTool>

            <movingTool node="reel">
                <dependentPart node="reelPart"/>
            </movingTool>
        </movingTools>

        <movingParts>
            <movingPart node="reelRotateHydraulic" referencePoint="reelRotateHydraulicRef" referenceFrame="reelRotateHydraulicRef">
                <translatingPart node="reelRotateHydraulicPunch"/>
            </movingPart>

            <movingPart node="reelPart" referenceFrame="reel" doDirectionAlignment="false" doRotationAlignment="true" rotMultiplier="1">
                <dependentPart node="tines01"/>
                <dependentPart node="tines02"/>
                <dependentPart node="tines03"/>
                <dependentPart node="tines04"/>
                <dependentPart node="tines05"/>
                <dependentPart node="tines06"/>
            </movingPart>

            <movingPart node="tines01" referencePoint="tines01Ref" referenceFrame="reelMove" limitedAxis="1"/>
            <movingPart node="tines02" referencePoint="tines02Ref" referenceFrame="reelMove" limitedAxis="1"/>
            <movingPart node="tines03" referencePoint="tines03Ref" referenceFrame="reelMove" limitedAxis="1"/>
            <movingPart node="tines04" referencePoint="tines04Ref" referenceFrame="reelMove" limitedAxis="1"/>
            <movingPart node="tines05" referencePoint="tines05Ref" referenceFrame="reelMove" limitedAxis="1"/>
            <movingPart node="tines06" referencePoint="tines06Ref" referenceFrame="reelMove" limitedAxis="1"/>
        </movingParts>
    </cylindered>

    <dynamicMount forceLimitScale="1"/>

    <cutter fruitTypeCategories="grainHeader">
         <animationNodes>
            <animationNode node="reel" rotAxis="1" rotSpeed="220" turnOnFadeTime="2" turnOffFadeTime="4"/>

            <animationNode node="reelPartRoll01" rotAxis="1" rotSpeed="220" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="reelPartRoll02" rotAxis="1" rotSpeed="220" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="reelPartRoll03" rotAxis="1" rotSpeed="220" turnOnFadeTime="2" turnOffFadeTime="4"/>

            <animationNode node="pto" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>

            <animationNode node="gear02" rotSpeed="1200" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="gear03" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="gear04" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="gear05" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>

            <animationNode node="beltPulley01" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="beltPulley02" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>
            <animationNode node="beltPulley03" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4"/>

            <animationNode node="chains" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4" shaderComponentScale="0 1 0 0" shaderParameterName="offsetUV"/>
            <animationNode node="belt" rotSpeed="540" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="4" shaderComponentScale="0 1 0 0" shaderParameterName="offsetUV"/>

            <animationNode node="drum" rotSpeed="540" rotAxis="1" class="RotationAnimationSpikes" turnOnFadeTime="2" turnOffFadeTime="4">
                <spikes moveUpRange="130 200" moveDownRange="230 280" maxTrans="-0.065" transAxis="2">
                    <spike node="spikes11"/>
                    <spike node="spikes10"/>
                    <spike node="spikes09"/>
                    <spike node="spikes08"/>
                    <spike node="spikes07"/>
                    <spike node="spikes06"/>
                    <spike node="spikes05"/>
                    <spike node="spikes04"/>
                    <spike node="spikes03"/>
                    <spike node="spikes02"/>
                    <spike node="spikes01"/>
                </spikes>
            </animationNode>
        </animationNodes>

        <fruitExtraObjects hideOnMount="true">
            <fruitExtraObject node="cropDividers" animationName="cropDividersAnim" isDefault="true"/>
        </fruitExtraObjects>

        <automaticTilt raycastNode1="heightNode01" raycastNode2="heightNode03"/>

        <effect>
            <effectNode effectClass="CutterMotionPathEffect" effectType="CUTTER" linkNode="cutterEffectLinkNode">
                <motionPathEffect textureFilename="$data/vehicles/masseyFerguson/mf8570Header/drumArray.dds" numRows="32" rowLength="42" minFade="0.06" textureRealWidth="16" speedScale="0.16"/>
            </effectNode>
            <effectNode effectClass="ParticleEffect" effectNode="smokeEmitter" particleType="SMOKE" materialType="smokeParticle" emitCountScale="0.1" worldSpace="false" useCuttingWidth="false"/>
        </effect>
        <sounds>
            <cut template="cropCutting" volumeScale="1.4"/>
        </sounds>
    </cutter>

    <turnOnVehicle turnedOnByAttacherVehicle="true">
        <turnedOnAnimation name="turnedOnAnim" speedScale="8" turnOnFadeTime="2" turnOffFadeTime="3"/>

        <sounds>
            <start template="harvesterToolStart" volumeScale="1.0" pitchScale="1" />
            <work  template="harvesterToolWork"  volumeScale="1.0" pitchScale="1" />
            <stop  template="harvesterToolStop"  volumeScale="1.0" pitchScale="1"/>
        </sounds>
    </turnOnVehicle>

     <ai>
        <areaMarkers leftNode="aiMarkerLeft" rightNode="aiMarkerRight" backNode="aiMarkerBack"/>
        <collisionTrigger useSize="true"/>
        <agentAttachment useSize="true"/>
    </ai>

    <designColorConfigurations title="$l10n_configuration_designColor">
        <designColorConfiguration materialTemplateName="silverRough" name="$l10n_ui_colorSilver"/>
        <designColorConfiguration materialTemplateName="metalPaintedBlack" name="$l10n_ui_colorBlack"/>

        <material materialSlotName="mf8570Header_reel_mat"/>
    </designColorConfigurations>

    <foliageBending>
        <bendingNode minX="-3.35" maxX="3.4" minZ="-1.3" maxZ="-0.35" yOffset="0.1"/>
        <bendingNode minX="2.95" maxX="3.4" minZ="-0.35" maxZ="0.3" yOffset="0.1"/>
        <bendingNode minX="-3.35" maxX="-2.95" minZ="-0.35" maxZ="0.3" yOffset="0.1"/>
    </foliageBending>

    <wearable wearDuration="480" workMultiplier="5" fieldMultiplier="2"/>
    <washable dirtDuration="90" washDuration="1" workMultiplier="4" fieldMultiplier="2"/>

    <i3dMappings>
        <i3dMapping id="mf8570Header_main_component1" node="0>" />
        <i3dMapping id="attacherJoint" node="0>0|0|0" />
        <i3dMapping id="hydraulicIn01" node="0>0|0|1|0" />
        <i3dMapping id="hydraulicIn01_detached" node="0>0|0|1|0|0" />
        <i3dMapping id="hydraulicIn01_connector" node="0>0|0|1|0|0|0" />
        <i3dMapping id="hydraulicOut01" node="0>0|0|1|1" />
        <i3dMapping id="hydraulicOut01_detached" node="0>0|0|1|1|0" />
        <i3dMapping id="hydraulicOut01_connector" node="0>0|0|1|1|0|0" />
        <i3dMapping id="hydraulicIn02" node="0>0|0|1|2" />
        <i3dMapping id="hydraulicIn02_detached" node="0>0|0|1|2|0" />
        <i3dMapping id="hydraulicIn02_connector" node="0>0|0|1|2|0|0" />
        <i3dMapping id="hydraulicOut02" node="0>0|0|1|3" />
        <i3dMapping id="hydraulicOut02_detached" node="0>0|0|1|3|0" />
        <i3dMapping id="hydraulicOut02_connector" node="0>0|0|1|3|0|0" />
        <i3dMapping id="hydraulicIn03" node="0>0|0|1|4" />
        <i3dMapping id="hydraulicIn03_detached" node="0>0|0|1|4|0" />
        <i3dMapping id="hydraulicIn03_connector" node="0>0|0|1|4|0|0" />
        <i3dMapping id="reelRotate" node="0>0|1|0" />
        <i3dMapping id="reelMove" node="0>0|1|0|0|0" />
        <i3dMapping id="reel" node="0>0|1|0|0|0|0" />
        <i3dMapping id="tines01Ref" node="0>0|1|0|0|0|0|0|0" />
        <i3dMapping id="tines02Ref" node="0>0|1|0|0|0|0|0|1" />
        <i3dMapping id="tines03Ref" node="0>0|1|0|0|0|0|0|2" />
        <i3dMapping id="tines04Ref" node="0>0|1|0|0|0|0|0|3" />
        <i3dMapping id="tines05Ref" node="0>0|1|0|0|0|0|0|4" />
        <i3dMapping id="tines06Ref" node="0>0|1|0|0|0|0|0|5" />
        <i3dMapping id="reelPart" node="0>0|1|0|0|0|1" />
        <i3dMapping id="tines01" node="0>0|1|0|0|0|1|0|0" />
        <i3dMapping id="tines02" node="0>0|1|0|0|0|1|0|1" />
        <i3dMapping id="tines03" node="0>0|1|0|0|0|1|0|2" />
        <i3dMapping id="tines04" node="0>0|1|0|0|0|1|0|3" />
        <i3dMapping id="tines05" node="0>0|1|0|0|0|1|0|4" />
        <i3dMapping id="tines06" node="0>0|1|0|0|0|1|0|5" />
        <i3dMapping id="reelPartRoll01" node="0>0|1|0|0|0|2|0" />
        <i3dMapping id="reelPartRoll02" node="0>0|1|0|0|0|2|1" />
        <i3dMapping id="reelPartRoll03" node="0>0|1|0|0|0|2|2" />
        <i3dMapping id="reelRotateHydraulicRef" node="0>0|1|0|1" />
        <i3dMapping id="reelRotateHydraulic" node="0>0|1|1" />
        <i3dMapping id="reelRotateHydraulicPunch" node="0>0|1|1|0" />
        <i3dMapping id="cutterRotate" node="0>0|1|2|0" />
        <i3dMapping id="cutterMove" node="0>0|1|2|0|0" />
        <i3dMapping id="cropDividers" node="0>0|1|3" />
        <i3dMapping id="colCropDividerLeft" node="0>0|1|3|1" />
        <i3dMapping id="colCropDividerRight" node="0>0|1|3|2" />
        <i3dMapping id="drum" node="0>0|1|4" />
        <i3dMapping id="spikes01" node="0>0|1|4|0" />
        <i3dMapping id="spikes02" node="0>0|1|4|1" />
        <i3dMapping id="spikes03" node="0>0|1|4|2" />
        <i3dMapping id="spikes04" node="0>0|1|4|3" />
        <i3dMapping id="spikes05" node="0>0|1|4|4" />
        <i3dMapping id="spikes06" node="0>0|1|4|5" />
        <i3dMapping id="spikes07" node="0>0|1|4|6" />
        <i3dMapping id="spikes08" node="0>0|1|4|7" />
        <i3dMapping id="spikes09" node="0>0|1|4|8" />
        <i3dMapping id="spikes10" node="0>0|1|4|9" />
        <i3dMapping id="spikes11" node="0>0|1|4|10" />
        <i3dMapping id="pto" node="0>0|1|5" />
        <i3dMapping id="beltPulley01" node="0>0|1|6" />
        <i3dMapping id="beltPulley02" node="0>0|1|7" />
        <i3dMapping id="beltPulley03" node="0>0|1|8" />
        <i3dMapping id="belt" node="0>0|1|9" />
        <i3dMapping id="chains" node="0>0|1|10" />
        <i3dMapping id="gear02" node="0>0|1|11" />
        <i3dMapping id="gear03" node="0>0|1|12" />
        <i3dMapping id="gear04" node="0>0|1|13" />
        <i3dMapping id="gear05" node="0>0|1|14" />
        <i3dMapping id="smokeEmitter" node="0>0|2|0" />
        <i3dMapping id="cutterEffectLinkNode" node="0>0|2|1" />
        <i3dMapping id="workAreaStart" node="0>0|3|0" />
        <i3dMapping id="workAreaWidth" node="0>0|3|1" />
        <i3dMapping id="workAreaHeight" node="0>0|3|2" />
        <i3dMapping id="aiMarkerLeft" node="0>0|4|0" />
        <i3dMapping id="aiMarkerRight" node="0>0|4|1" />
        <i3dMapping id="aiMarkerBack" node="0>0|4|2" />
        <i3dMapping id="heightNode01" node="0>0|5|0" />
        <i3dMapping id="heightNode02" node="0>0|5|1" />
        <i3dMapping id="heightNode03" node="0>0|5|2" />
        <i3dMapping id="header_vis" node="0>0|6|0" />
    </i3dMappings>
</vehicle>
