<?xml version="1.0" encoding="utf-8" standalone="no"?>
<vehicle type="mulcher" 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>Kornik XL 2.8</name>
        <specs>
            <neededPower>90</neededPower>
            <workingWidth>2.8</workingWidth>
        </specs>
        <functions>
            <function>$l10n_function_mulcher</function>
        </functions>
        <image>store.dds</image>
        <price>15000</price>
        <lifetime>600</lifetime>
        <rotation>0</rotation>
        <brand>UNIA</brand>
        <category>mulchers</category>
        <shopTranslationOffset>0 -0.1 0</shopTranslationOffset>        
        <audioMemoryUsage>0</audioMemoryUsage>
    </storeData>

    <base>
        <typeDesc>$l10n_typeDesc_mulcher</typeDesc>
        <filename>kornikXL.i3d</filename>
        <size width="4" length="2" lengthOffset="0.2"/>
        <speedLimit value="12"/>
        <components>
            <component centerOfMass="0 0.2 0" solverIterationCount="15" mass="685"/>
        </components>
        <schemaOverlay attacherJointPosition="0 0" name="IMPLEMENT" />
    </base>

    <wheels>
        <wheelConfigurations>
            <wheelConfiguration name="$l10n_configuration_valueDefault">
                <wheels>
                    <wheel>
                        <physics restLoad="0.2" repr="0>2|0" radius="0.08" width="0.1" forcePointRatio="0.35" initialCompression="20" suspTravel="0.05" spring="14" damper="20" frictionScale="0.1" yOffset="0.01"/>
                    </wheel>
                    <wheel>
                        <physics restLoad="0.2" repr="0>2|1" radius="0.08" width="0.1" forcePointRatio="0.35" initialCompression="20" suspTravel="0.05" spring="14" damper="20" frictionScale="0.1" yOffset="0.01"/>
                    </wheel>
                </wheels>
            </wheelConfiguration>
        </wheelConfigurations>
    </wheels>

    <speedRotatingParts>
        <speedRotatingPart node="0>6|2" radius="0.1" groundReferenceNodeIndex="1" onlyActiveWhenLowered="true" />
    </speedRotatingParts>

    <attachable>
        <inputAttacherJoints>
            <inputAttacherJoint node="0>0|0" jointType="implement" topReferenceNode="0>0|1" lowerRotationOffset="-2" upperRotationOffset="10" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 1 0" allowsLowering="true">
                <distanceToGround lower="0.3" upper="0.9"/>
            </inputAttacherJoint>
        </inputAttacherJoints>
        <support animationName="moveSupport" />
    </attachable>

    <powerTakeOffs>
        <input inputAttacherJointIndices="1" inputNode="0>0|2|0" detachNode="0>0|2|1" aboveAttacher="true">
        </input>
    </powerTakeOffs>

    <powerConsumer forceNode="0>" ptoRpm="540" neededMaxPtoPower="32"/>

    <groundReferenceNodes>
        <groundReferenceNode node="0>3|3" forceFactor="1" threshold="0.1"/>
    </groundReferenceNodes>

    <workAreas>
        <workArea type="mulcher" functionName="processMulcherArea" disableBackwards="false">
            <area startNode="0>3|0" widthNode="0>3|1" heightNode="0>3|2"/>
            <groundReferenceNode index="1"/>
            <onlyActiveWhenLowered value="true"/>
        </workArea>
    </workAreas>

    <animations>
        <animation name="moveSupport">
            <part node="0>1|0" startTime="0" endTime="0.4" startTrans="-0.066 0.715 0.586" endTrans="-0.066 0.544 0.586"/>
            <part node="0>1|1" startTime="0" endTime="0.4" startTrans="0 0.2 0" endTrans="0 0 0"/>

            <sound template="clackVar5" startTime="0.39" direction="-1" volumeScale="1.5" pitchScale="1.5" linkNode="0>0|0"/>
            <sound template="clackVar1" startTime="0.01" direction="1"  volumeScale="1.5" pitchScale="1.5" linkNode="0>0|0"/>
        </animation>
    </animations>

    <mulcher>
        <effects>
            <effect workAreaIndex="1">
                <effectNode effectClass="TypedMotionPathEffect" effectType="MULCHER" linkNode="0>5|1">
                    <motionPathEffect textureFilename="$data/vehicles/tmcCancela/tms2_300d/mulcherEffectArray.dds" numRows="30" rowLength="18" minFade="0.15" shapeScale="0.2" maxShapeScale="1.5"/>
                </effectNode>
                <effectNode effectClass="TypedMotionPathEffect" effectType="MULCHER" linkNode="0>5|2">
                    <motionPathEffect textureFilename="$data/vehicles/tmcCancela/tms2_300d/mulcherEffectArray.dds" numRows="30" rowLength="18" minFade="0.15" shapeScale="0.2" maxShapeScale="2"/>
                </effectNode>                
                <effectNode effectNode="0>5|0" effectClass="ParticleEffect" particleType="smoke" materialType="smokeParticle" worldSpace="false" emitCountScale="0.5"/>
            </effect>
        </effects>
        <sounds>
            <work template="DEFAULT_PLOW_WORK" linkNode="0>" />
        </sounds>
    </mulcher>

    <turnOnVehicle turnOffIfNotAllowed="true">
        <animationNodes>
            <animationNode node="0>6|1" rotSpeed="-2500" rotAxis="1" turnOnFadeTime="2" turnOffFadeTime="8" />
        </animationNodes>

        <sounds>
            <start template="dischargeStart" />
            <work template="dischargeLoop" />
            <stop template="dischargeStop" />
        </sounds>
    </turnOnVehicle>

    <ai>
        <needsLowering value="true"/>
        <areaMarkers leftNode="0>4|0" rightNode="0>4|1" backNode="0>4|2"/>
        <collisionTrigger node="0>4|3" width="1.5" height="1.3"/>
        <agentAttachment width="1.8" height="1.1" length="1.2" lengthOffset="0.05"/>
    </ai>

    <foliageBending>
        <bendingNode minX="-1.6" maxX="1.45" minZ="-0.7" maxZ="0.65" yOffset="0.25"/>
    </foliageBending>

    <designConfigurations title="$l10n_backFlap">
        <designConfiguration name="$l10n_Closed">
            <objectChange node="0>5|1" visibilityActive="true"/>
            <objectChange node="0>5|2" visibilityActive="false"/>
            <objectChange node="0>6|0" rotationActive="0.594 0 0"/>            
        </designConfiguration>
        <designConfiguration name="$l10n_Opened">
            <objectChange node="0>5|1" visibilityActive="false"/>
            <objectChange node="0>5|2" visibilityActive="true"/>>
            <objectChange node="0>6|0" rotationActive="50.594 0 0"/>            
        </designConfiguration>
    </designConfigurations>

     <configurationSets title="$l10n_Version">
        <configurationSet name="I" price="0" > 
            <configuration name="design2" index="1" /> 
            <configuration name="baseMaterial" index="1" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="2" /> 
            <configuration name="designMaterial3" index="3" />                                                            
        </configurationSet>
        <configurationSet name="II" price="0" > 
            <configuration name="design2" index="2" /> 
            <configuration name="baseMaterial" index="2" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="3" /> 
            <configuration name="designMaterial3" index="2" />                                                          
        </configurationSet>
        <configurationSet name="III" price="0" > 
            <configuration name="design2" index="3" /> 
            <configuration name="baseMaterial" index="1" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="2" /> 
            <configuration name="designMaterial3" index="3" />                                                          
        </configurationSet> 
        <configurationSet name="IV" price="0" > 
            <configuration name="design2" index="4" /> 
            <configuration name="baseMaterial" index="2" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="3" /> 
            <configuration name="designMaterial3" index="2" />                                                          
        </configurationSet> 
        <configurationSet name="V" price="0" > 
            <configuration name="design2" index="5" /> 
            <configuration name="baseMaterial" index="1" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="2" /> 
            <configuration name="designMaterial3" index="3" />                                                          
        </configurationSet>
        <configurationSet name="VI" price="0" > 
            <configuration name="design2" index="6" /> 
            <configuration name="baseMaterial" index="2" /> 
            <configuration name="designMaterial" index="2" /> 
            <configuration name="designMaterial2" index="3" /> 
            <configuration name="designMaterial3" index="2" />                                                          
        </configurationSet>  
        <configurationSet name="VII" price="0" > 
            <configuration name="design2" index="7" /> 
            <configuration name="baseMaterial" index="3" /> 
            <configuration name="designMaterial" index="1" /> 
            <configuration name="designMaterial2" index="1" /> 
            <configuration name="designMaterial3" index="1" />                                                          
        </configurationSet>
        <configurationSet name="VIII" price="0" > 
            <configuration name="design2" index="8" /> 
            <configuration name="baseMaterial" index="3" /> 
            <configuration name="designMaterial" index="1" /> 
            <configuration name="designMaterial2" index="1" /> 
            <configuration name="designMaterial3" index="1" />                                                          
        </configurationSet>                                                                                                  
    </configurationSets>

    <design2Configurations>   
        <design2Configuration name="I">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="true"/>
            <objectChange node="0>6|0|2" visibilityActive="false"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="true"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration>
        <design2Configuration name="II">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="false"/>
            <objectChange node="0>6|0|2" visibilityActive="true"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="true"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration>
        <design2Configuration name="III">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="true"/>
            <objectChange node="0>6|0|2" visibilityActive="false"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="true"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration> 
        <design2Configuration name="IV">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="false"/>
            <objectChange node="0>6|0|2" visibilityActive="true"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="true"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration> 
        <design2Configuration name="V">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="true"/>
            <objectChange node="0>6|0|2" visibilityActive="false"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="true"/>                                             
        </design2Configuration>  
        <design2Configuration name="VI">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="false"/>
            <objectChange node="0>6|0|2" visibilityActive="true"/>

            <objectChange node="0>7|0|0" visibilityActive="false"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="true"/>                                             
        </design2Configuration>    
        <design2Configuration name="VII">
            <objectChange node="0>6|0|0" visibilityActive="true"/>
            <objectChange node="0>6|0|1" visibilityActive="false"/>
            <objectChange node="0>6|0|2" visibilityActive="false"/>

            <objectChange node="0>7|0|0" visibilityActive="true"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration>
        <design2Configuration name="VIII">
            <objectChange node="0>6|0|0" visibilityActive="false"/>
            <objectChange node="0>6|0|1" visibilityActive="false"/>
            <objectChange node="0>6|0|2" visibilityActive="true"/>

            <objectChange node="0>7|0|0" visibilityActive="true"/> 
            <objectChange node="0>7|0|1" visibilityActive="false"/>
            <objectChange node="0>7|0|2" visibilityActive="false"/>
            <objectChange node="0>7|0|3" visibilityActive="false"/>                                             
        </design2Configuration>

    </design2Configurations>

    <baseMaterial>
        <material name="kornikXL_mat" baseNode="0>7|0">
            <shaderParameter name="colorMat0" value="0.6 0.04 0.032"/>
            <shaderParameter name="colorMat1" value="0.6 0.04 0.032"/>
            <shaderParameter name="colorMat2" value="0.6 0.04 0.032"/>
            <shaderParameter name="colorMat3" value="0.05 0.05 0.05"/>
            <shaderParameter name="colorMat4" value="0.6 0.04 0.032"/>                                    
        </material>
    </baseMaterial>

    <baseMaterialConfigurations price="0">
        <baseMaterialConfiguration material="0" color="0.07 0.29 0.1"/>    	
        <baseMaterialConfiguration material="0" color="0 0.21 0.09"/>    	
        <baseMaterialConfiguration material="0" color="0.54 0.03 0.031"/>        

        <material name="kornikXL_mat" shaderParameter="colorMat0" />   
    </baseMaterialConfigurations>

    <designMaterialConfigurations price="0">
        <designMaterialConfiguration material="6" color="0.15 0.15 0.15"/>        
        <designMaterialConfiguration material="6" color="0.05 0.05 0.05"/>     

        <material name="kornikXL_mat" shaderParameter="colorMat1" />        
    </designMaterialConfigurations>

    <designMaterial2Configurations price="0">
        <designMaterial2Configuration material="6" color="0.15 0.15 0.15"/>        
        <designMaterial2Configuration material="0" color="0.07 0.29 0.1"/>     
        <designMaterial2Configuration material="0" color="0 0.21 0.09"/>

        <material name="kornikXL_mat" shaderParameter="colorMat2" />        
    </designMaterial2Configurations>  

    <designMaterial3Configurations price="0">                     
        <designMaterial3Configuration material="6" color="0.15 0.15 0.15"/>
        <designMaterial3Configuration material="6" color="0.05 0.05 0.05"/>        
        <designMaterial3Configuration material="6" color="0.07 0.29 0.1"/>         

        <material name="kornikXL_mat" shaderParameter="colorMat4" />        
    </designMaterial3Configurations>            

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