<?xml version="1.0" encoding="utf-8" standalone="no"?>
<vehicle type="baseTipper" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://validation.gdn.giants-software.com/xml/fs22/vehicle.xsd">

    <storeData>
        <name>
			<en>Grain Swap Body</en>
			<de>Getreide Wechselaufbau</de>
			<fi>Vilja Jalkalava</fi>
        </name>
        <specs>
            <combination xmlFilename="xml/lizardspirit.xml"/>
			<combination xmlFilename="xml/viljakarry.xml"/>
			<combination xmlFilename="$data/vehicles/volvo/fh16/fh16.xml"/>
        </specs>
        <functions>
            <function>$l10n_function_tipper</function>
        </functions>
        <image>store_viljalava.dds</image>
        <price>30000</price>
        <lifetime>600</lifetime>
        <rotation>0</rotation>
        <brand>LIZARD</brand>
        <category>misc</category>
        <shopTranslationOffset>0 0.251 2.5</shopTranslationOffset>
    </storeData>
	
    <base>
        <typeDesc>$l10n_typeDesc_tipper</typeDesc>
        <filename>i3d/grainswapbody.i3d</filename>
        <size width="2.6" length="8" height="3"/>
        <components>
            <component centerOfMass="0 -2.588 -0.96" solverIterationCount="10" mass="3000"/>
			<component centerOfMass="0 0 0" solverIterationCount="10" mass="20"/>
			<joint component1="1" component2="2" node="0>3|6" rotLimit="45 0 0" transLimit="0 0 0" rotLimitSpring="20.0 0 0" rotLimitDamping="40.0 0 0" enableCollision="false"/>
        </components>
        <schemaOverlay attacherJointPosition="-1 -0.5" name="IMPLEMENT"/>
    </base>
	
   <attachable>
        <inputAttacherJoints>
            <inputAttacherJoint node="0>3|0|0" jointType="semitrailer" upperRotationOffset="0" enableCollision="true" fixedRotation="false" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 0 0" upperTransLimitScale="0 0 0"/>
        
		<inputAttacherJoint node="0>3|0|1" jointType="82JointX3" upperRotationOffset="0" enableCollision="true" fixedRotation="false" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 0 0" upperTransLimitScale="0 0 0"/>
        
		<inputAttacherJoint node="0>3|0|1" jointType="82JointTipperX2" upperRotationOffset="0" enableCollision="true" fixedRotation="false" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 0 0" upperTransLimitScale="0 0 0"/>
        
		<inputAttacherJoint node="0>3|0|1" jointType="82JointWreckIT" upperRotationOffset="0" enableCollision="true" fixedRotation="false" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 0 0" upperTransLimitScale="0 0 0"/>
		
		<inputAttacherJoint node="0>3|0|2" jointType="MTBJoint" upperRotationOffset="0" enableCollision="true" fixedRotation="false" lowerRotLimitScale="0 0 0" upperRotLimitScale="0 0 0" lowerTransLimitScale="0 0 0" upperTransLimitScale="0 0 0"/>
		
        </inputAttacherJoints>
        <support animationName="moveSupport"/>
        <brakeForce force="0.6" />
    </attachable>
	
   	<connectionHoses>
		
		<target attacherJointIndices="1" type="airDoubleRed"  node="0>3|3|0|0|0|0"> 
			<objectChange node="0>3|3|0|0|0|1" rotationActive="0 0 0" rotationInactive="-95 0 0"/>
	
		</target>
		 <target attacherJointIndices="1" type="airDoubleYellow" node="0>3|3|0|1|0|0">
			<objectChange node="0>3|3|0|1|0|1" rotationActive="0 0 0" rotationInactive="-95 0 0"/>
	
		</target>
		<target attacherJointIndices="1" type="electric" node="0>3|3|0|2|0|0">
			<objectChange node="0>3|3|0|2|0|1" rotationActive="0 0 0" rotationInactive="-90 0 0"/>
			
		</target>
		<target attacherJointIndices="1" type="electric" node="0>3|3|0|3|0|0">
			<objectChange node="0>3|3|0|3|0|1" rotationActive="0 0 0" rotationInactive="-90 0 0"/>
		
		</target>
		 <target attacherJointIndices="1" type="hydraulicIn" node="0>3|3|0|4|0">
			
			<objectChange node="0>3|3|0|4|1" visibilityActive="false" visibilityInactive="true"/>
			
		</target>
		<target attacherJointIndices="1" type="hydraulicOut" node="0>3|3|0|5|0">
			
			<objectChange node="0>3|3|0|5|1" visibilityActive="false" visibilityInactive="true"/>
			
		</target>
	</connectionHoses>

  
   <attacherJoints>
       
    
		<attacherJoint node="0>3|1|0" jointType="trailer" lowerRotLimit="30 90 100" allowsLowering="false" upperRotRotationOffset="0" allowsJointLimitMovement="false">
            <distanceToGround lower="0.57" upper="1.03" />
            <schema position="1.5 0" rotation="0" invertX="false" />
			
        </attacherJoint>
		
		  <attacherJoint node="0>3|9" jointType="MTBJointCrane" allowsJointLimitMovement="false" allowsLowering="false" lowerRotLimit="0 0 0">
		
            <distanceToGround lower="0.57" upper="1.03" />
            <schema position="1.5 0" rotation="0" invertX="false" />
			
        </attacherJoint>
		
		<sounds>
		        <attach template="attachAirBrake" />
                <detach template="detachAirBrake" />
                
                </sounds>
	</attacherJoints>
	
   <foldable>
		<foldingConfigurations>
			<foldingConfiguration>
				<foldingParts startMoveDirection="0"  posDirectionText="$l10n_close_side" negDirectionText="$l10n_open_side">
					<foldingPart animationName="laidat" speedScale="1"/>
					
				</foldingParts>
			</foldingConfiguration>
		</foldingConfigurations>
	</foldable> 
	
	<cover>
        <coverConfigurations>
            <coverConfiguration>
                <cover openAnimation="pressu" fillUnitIndices="1"  />
				
            </coverConfiguration>
        </coverConfigurations>
    </cover>
	
    <animations>
	
	   <animation name="pressu">
            <part node="0>1|0|3|0" startTime="0"    endTime="0.05" visibility="true" />
            <part node="0>1|0|3|0" startTime="0.05" endTime="0.1"  visibility="false" />
			<part node="0>1|0|3|1" startTime="0"    endTime="0.05" visibility="false" />
            <part node="0>1|0|3|1" startTime="0.05" endTime="0.1"  visibility="true" />
			
			<sound template="fabricCover2" startTime="0.01" direction="1"  volumeScale="1.4" pitchScale="1.5"/>
            <sound template="fabricCover1" startTime="0.05" direction="-1" volumeScale="1.4" pitchScale="1.8"/>
        </animation>
	
		<animation name="kippaus">
			<part node="0>1"        startTime="0.8" endTime="12"  startRot="0 0 0" endRot="-50 0 0" />
			<part node="0>1|0|4|0"            startTime="0.8" endTime="12"   startRot="90 0 0" endRot="140 0 0"/>	
			
			<part node="0>1|0|4|3" startTime="0.8" endTime="12" startRot="0 0 0" endRot="50 0 0" />
			
			<sound template="hydraulicOpen06"  startTime="0.01" endTime="11.99" direction="-1" startPitchScale="0.5" endPitchScale="0.6" volumeScale="0.7" linkNode="0>" fadeIn="0.1" fadeOut="0.1"/>
            <sound template="hydraulicOpen02"  startTime="0.01" endTime="11.99" direction="-1" startPitchScale="1.1" endPitchScale="1.2" volumeScale="1.2" linkNode="0>" fadeIn="0.1" fadeOut="0.1"/>
            <sound template="hydraulicClose01" startTime="0.01" endTime="11.99" direction="1"  pitchScale="0.5"      volumeScale="2.0"                     linkNode="0>" fadeIn="0.1" fadeOut="0.1"/>
            <sound template="hydraulicOpen05"  startTime="0.01" endTime="11.99" direction="1"  pitchScale="1.5"      volumeScale="2.0"                     linkNode="0>" fadeIn="0.1" fadeOut="0.1"/>
		</animation>
		
		
		<animation name="laidat">
		    <part node="0>1|0|2|0" endTime="0.05" startTime="0.55" startTrans="-0.247 0.251 0" endTrans="-0.247 -1.595 0"/>
            <part node="0>1|0|2|1" startTime="0.01"    endTime="0.05" visibility="false" />
			<part node="0>1|0|2|1" startTime="0"    endTime="0.01" visibility="true" />
			<part node="0>1|0|1" startTime="0.1" endTime="2" startRot="0 0 0" endRot="0 -180 0"/>
			<part node="0>1|0|4|2" startTime="2.10" endTime="2.15"  visibility="false" />
			<part node="0>1|0|4|2" startTime="0" endTime="2.10"  visibility="true" />
			
			<sound template="metalOpen" startTime="0.01"  volumeScale="1.4" pitchScale="1.5"/>
			<sound template="metalOpen" startTime="2.1"   volumeScale="1.4" pitchScale="1.5"/>
			<sound template="clackVar1" startTime="2" direction="1"  volumeScale="2" pitchScale="1.5"/>
			<sound template="clackVar1" startTime="0.1" direction="-1"  volumeScale="2" pitchScale="1.5"/>
			
			
        </animation>
		
		<animation name="moveSupport">
           <part node="0>3|2|0|0|0|0"		startTime="3.5"     endTime="4"    startTrans="0.003 0.045 0.874" endTrans="0.003 0.045 1.2"/>
		   <part node="0>3|2|0|0|0"		    startTime="2"     endTime="3"   startRot="0 90 0"   endRot="0 0 0"/>
           <part node="0>3|2|0|0"		startTime="0"     endTime="2"    startTrans="-1.147 0.59 -1.302" endTrans="-0.104 0.59 -1.302"/>
		   
		   <part node="0>3|2|0|1|0|0"		startTime="3.5"     endTime="4"    startTrans="0.003 0.045 0.874" endTrans="0.003 0.045 1.2"/>
		   <part node="0>3|2|0|1|0"		    startTime="2"     endTime="3"   startRot="0 90 0"   endRot="0 0 0"/>
           <part node="0>3|2|0|1"		startTime="0"     endTime="2"    startTrans="1.147 0.59 -1.302" endTrans="0.104 0.59 -1.302"/>
           
		   <part node="0>3|2|1|0|0|0"		startTime="3.5"     endTime="4"    startTrans="0.003 0.045 0.874" endTrans="0.003 0.045 1.2"/>
		   <part node="0>3|2|1|0|0"		    startTime="2"     endTime="3"   startRot="0 90 0"   endRot="0 0 0"/>
           <part node="0>3|2|1|0"		startTime="0"     endTime="2"    startTrans="-1.147 0.59 -1.302" endTrans="-0.104 0.59 -1.302"/>
		   
		   <part node="0>3|2|1|1|0|0"		startTime="3.5"     endTime="4"    startTrans="0.003 0.045 0.874" endTrans="0.003 0.045 1.2"/>
		   <part node="0>3|2|1|1|0"		    startTime="2"     endTime="3"   startRot="0 90 0"   endRot="0 0 0"/>
           <part node="0>3|2|1|1"		startTime="0"     endTime="2"    startTrans="1.147 0.59 -1.302" endTrans="0.104 0.59 -1.302"/>
		   
            <sound template="clackVar6"      startTime="1.9" direction="-1" volumeScale="1.2" pitchScale="0.6"/>
			<sound template="clackVar6"      startTime="3.9" direction="-1" volumeScale="1.2" pitchScale="0.6"/>
			
           
        </animation>
		
    </animations>				

   

    <cylindered>	
	    <movingTools>
		
		<movingTool node="0>3|0"  playSound="false">
               <controls axis="AXIS_CRANE_ARM2" invertAxis="false" mouseSpeedFactor="0.5" iconName="move"/>
                <translation transSpeed="0.3" transAcceleration="80" transMax="-2.628" transMin="-2.878" translationAxis="3"/>
				<inputAttacherJoint value="true" />
	        </movingTool>
	      
		 <movingTool node="0>1" playSound="true">
                <dependentPart node="0>2|0"/>
            </movingTool>
			
			</movingTools>
		<movingParts>	
            <movingPart node="0>2|0" referencePoint="0>1|0|5" referenceFrame="0>">
            <translatingPart node="0>2|0|0"/>
            </movingPart>  
			
		</movingParts>
		 <sounds>
			<hydraulic template="hydraulicOpen02" linkNode="0>"/>
        </sounds>
	</cylindered>
	
	 <fillUnit>
        <fillUnitConfigurations>
            <fillUnitConfiguration>
                <fillUnits allowFoldingWhileFilled="false" foldMaxLimit="0" foldMinLimit="0" >
                
					<fillUnit  shopDisplayUnit="CUBICMETER" fillTypeCategories="SELLINGSTATION_FIELDFRUITS" capacity="48000" allowAILoading="true" foldMaxLimit="0" foldMinLimit="0"  >
					    
						<exactFillRootNode node="0>1|1|0" />
						<autoAimTargetNode node="0>1|1|2" startZ="2.2" endZ="-4.0" invert="false" fillUnitIndex="1" startPercentage="25"/>
					</fillUnit>
					
				</fillUnits>
	
            </fillUnitConfiguration>
			
        </fillUnitConfigurations>
    </fillUnit>
	
	<fillVolume>
		<fillVolumeConfigurations>
			<fillVolumeConfiguration>
				<volumes>
					<volume node="0>1|1|1" maxDelta="0.12" maxAllowedHeapAngle="5" fillUnitIndex="1" />
				</volumes>
			</fillVolumeConfiguration>
		</fillVolumeConfigurations>

		<unloadInfos>
			<unloadInfo>
				<node node="0>1|1|3" width="1.0" length="6" />
			</unloadInfo>            
		</unloadInfos>

		<heightNodes>
			<heightNode>
				<refNode node="0>1|1|4" />
				<refNode node="0>1|1|5" />
				<node node="0>1|0|4|3" baseScale="1 1 1"    transAxis="0 0 0" transMax="0 0.5 0" alignToWorldY="true" />
			</heightNode>             
		</heightNodes>
	</fillVolume>

	<trailer>
		<trailerConfigurations>
			<trailerConfiguration>
				<trailer>
					<tipSide name="$l10n_info_tipSideBack" dischargeNodeIndex="1" unloadInfoIndex="1">
						<animation name="kippaus" speedScale="1.0" startTipTime="0.3" />
					</tipSide>                    
				</trailer>
			</trailerConfiguration>
		</trailerConfigurations>
	</trailer>

	<dischargeable requiresTipOcclusionArea="false">>
		<dischargeNode node="0>3|5" emptySpeed="2800" fillUnitIndex="1" unloadInfoIndex="1" allowAIDischarge="true">
			<info width="2.4" length="0.5" zOffset="0.5"/>
			<effects>
				<effectNode effectClass="TipEffect">
					<effectNode effectNode="0>1|0|4|3|2|0" effectClass="ParticleEffect" materialType="unloadingParticle"/>
					<effectNode effectNode="0>1|0|4|3|1" materialType="unloading" fadeTime="0.5" extraDistanceNode="0>3|5" extraDistance="1.5" alignXAxisToWorldY="true" />
				</effectNode>
				<effectNode effectNode="0>1|0|4|3|0" materialType="unloadingSmoke" fadeTime="0.5" />
			</effects>
		</dischargeNode>        
	</dischargeable>
	
	 <lights>

		<sharedLight linkNode="0>5|3" lightTypes="0" filename="$data/shared/assets/lights/lizard/rearLight79_left.xml" />
		<sharedLight linkNode="0>5|4" lightTypes="0" filename="$data/shared/assets/lights/lizard/rearLight79_right.xml" />
		
		<sharedLight linkNode="0>5|5" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker05_left.xml"/>
		<sharedLight linkNode="0>5|6" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker05_right.xml"/>
		<sharedLight linkNode="0>5|7" lightTypes="0" filename="$data/shared/assets/lights/lizard/plateNumberLight03.xml"/>
		
		<sharedLight linkNode="0>1|2|0" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|1" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|2" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|3" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|4" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|5" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|6" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|7" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|8" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|9" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|10" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|11" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|12" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|13" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|14" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>
		<sharedLight linkNode="0>1|2|15" lightTypes="0" filename="$data/shared/assets/lights/lizard/sideMarker16Orange.xml"/>				
		<sharedLight linkNode="0>5|9|1" lightTypes="2" filename="$data/shared/assets/lights/hella/hellaWorkingLight06.xml" >
            <rotationNode name="rotationNode1" rotation="-70 0 0"/>
			</sharedLight>
        <sharedLight linkNode="0>5|9|2" lightTypes="2" filename="$data/shared/assets/lights/hella/hellaWorkingLight06.xml" >
            <rotationNode name="rotationNode1" rotation="-70 0 0"/>
			</sharedLight>
		
        <states>
            <state lightTypes="0" />
			
        </states>

        <realLights>
            <low>
               
            </low>
            <high>               
                <turnLightLeft node="0>5|1|0" />
                <turnLightRight node="0>5|1|1" />
                <light node="0>5|0|0"       lightTypes="0"/>
				<light node="0>5|8"       lightTypes="0"/>
				<brakeLight node="0>5|0|0" />
				<light node="0>5|9|0"          lightTypes="2"/>
				<reverseLight node="0>5|2|0"/>            
            </high>
        </realLights>
    </lights>
	
    <ai supportsAIJobs="false">
    <agentAttachment/>
    </ai>

    

   <designColorConfigurations useDefaultColors="true" defaultColorIndex="5" title="$l10n_configuration_chassisColor">
        

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

    <designColor2Configurations useDefaultColors="true" defaultColorIndex="5" title="$l10n_configuration_designColor">
        

        <material materialSlotName="runko"/>
        
    </designColor2Configurations>

    <designColor3Configurations useDefaultColors="true" defaultColorIndex="12" title="$l10n_configuration_designColor">
       

        <material materialSlotName="pressu"/>
        
    </designColor3Configurations>
	
	<tensionBelts>
        <tensionBeltsConfigurations>
            <tensionBeltsConfiguration>
                <tensionBelts linkNode="tensionBelts" jointNode="0>" width="0.06" maxEdgeLength="0.1" geometryBias="0.01" ratchetPosition="0.2" defaultOffset="-0.25" defaultOffsetSide="0.1" defaultHeight="4" interactionRadius="1" totalInteractionRadius="6.5" activationTrigger="beltActivationTrigger">
                    <tensionBelt startNode="beltStart1" endNode="beltEnd1"/>
                    <tensionBelt startNode="beltStart2" endNode="beltEnd2"/>
                    <tensionBelt startNode="beltStart3" endNode="beltEnd3"/>
                    <tensionBelt startNode="beltStart4" endNode="beltEnd4"/>
					<tensionBelt startNode="beltStart5" endNode="beltEnd5"/>
                    <tensionBelt startNode="beltStart6" endNode="beltEnd6"/>
					<tensionBelt startNode="beltStart7" endNode="beltEnd7"/>
                    <tensionBelt startNode="beltStart8" endNode="beltEnd8"/>
                    <tensionBelt startNode="beltStart9" endNode="beltEnd9"/>
					<tensionBelt startNode="beltStart10" endNode="beltEnd10"/>
                    <tensionBelt startNode="beltStart11" endNode="beltEnd11"/>
                </tensionBelts>
            </tensionBeltsConfiguration>
        </tensionBeltsConfigurations>
    </tensionBelts>
   
	<licensePlates>
        <licensePlate node="0>3|4"  position="BACK"  preferedType="ELONGATED" placementArea="0.07 0.27 0.17 0.27"/>
    </licensePlates>
	
    <wearable wearDuration="480" workMultiplier="5" fieldMultiplier="2"/>
    <washable dirtDuration="90" washDuration="1" workMultiplier="3" fieldMultiplier="2"/>
	
    <i3dMappings>
       <i3dMapping id="tensionBelts" node="0>1|3" />
        <i3dMapping id="beltStart1" node="0>1|3|0" />
        <i3dMapping id="beltEnd1" node="0>1|3|0|0" />
        <i3dMapping id="beltStart2" node="0>1|3|1" />
        <i3dMapping id="beltEnd2" node="0>1|3|1|0" />
        <i3dMapping id="beltStart3" node="0>1|3|2" />
        <i3dMapping id="beltEnd3" node="0>1|3|2|0" />
        <i3dMapping id="beltStart4" node="0>1|3|3" />
        <i3dMapping id="beltEnd4" node="0>1|3|3|0" />
	    <i3dMapping id="beltStart5" node="0>1|3|4" />
        <i3dMapping id="beltEnd5" node="0>1|3|4|0" />
	    <i3dMapping id="beltStart6" node="0>1|3|5" />
        <i3dMapping id="beltEnd6" node="0>1|3|5|0" />
		<i3dMapping id="beltStart7" node="0>1|3|6" />
        <i3dMapping id="beltEnd7" node="0>1|3|6|0" />
		<i3dMapping id="beltStart8" node="0>1|3|7" />
        <i3dMapping id="beltEnd8" node="0>1|3|7|0" />
		<i3dMapping id="beltStart9" node="0>1|3|8" />
        <i3dMapping id="beltEnd9" node="0>1|3|8|0" />
		<i3dMapping id="beltStart10" node="0>1|3|9" />
        <i3dMapping id="beltEnd10" node="0>1|3|9|0" />
		<i3dMapping id="beltStart11" node="0>1|3|10" />
        <i3dMapping id="beltEnd11" node="0>1|3|10|0" />
        <i3dMapping id="beltActivationTrigger" node="0>1|3|11" />
		
		
    </i3dMappings>

</vehicle>
