<?xml version="1.0" encoding="utf-8" standalone="no" ?>
<vehicle type="KramerKL600Red">
    <annotation>Copyright (C) GIANTS Software GmbH, All Rights Reserved.</annotation>

    <name>
        <de>imt540</de>
        <en>imt540</en>
    </name>

    <filename>imt540.i3d</filename>

    <size width="3.5" length="5" />

    <wheels autoRotateBackSpeed="1">
        <wheel forcePointRatio="0.2" restLoad="1.3" width="0.2" initialCompression="50" frictionScale="1.5" hasTyreTracks="true" tyreTrackAtlasIndex="4" tireType="street" rotSpeed="1" repr="1>3" driveNode="1>3|0" radius="0.365"  spring="60" damper="30" mass="0.5" />
        <wheel forcePointRatio="0.2" restLoad="1.3" width="0.2" initialCompression="50" frictionScale="1.5" hasTyreTracks="true" tyreTrackAtlasIndex="4" tireType="street" rotSpeed="1" repr="1>4" driveNode="1>4|0" radius="0.365"  spring="60" damper="30" mass="0.5" />
        <wheel forcePointRatio="0.3" restLoad="1.0" width="0.4" initialCompression="50" frictionScale="1.5" hasTyreTracks="true" rotSpeed="0" repr="2" radius="0.579" suspTravel="0.02" spring="300" damper="90" mass="0.5" />
        <wheel forcePointRatio="0.3" restLoad="1.0" width="0.4" initialCompression="50" frictionScale="1.5" hasTyreTracks="true" rotSpeed="0" repr="3" radius="0.579" suspTravel="0.02" spring="300" damper="90" mass="0.5" />
    </wheels>
    <driveGroundParticleSystems>
        <driveGroundParticleSystem file="$data/vehicles/particleAnimations/shared/drivingParticleSystem.i3d" wheel="1" />
        <driveGroundParticleSystem file="$data/vehicles/particleAnimations/shared/drivingParticleSystem.i3d" wheel="2" />
        <driveGroundParticleSystem file="$data/vehicles/particleAnimations/shared/drivingParticleSystem.i3d" wheel="3" />
        <driveGroundParticleSystem file="$data/vehicles/particleAnimations/shared/drivingParticleSystem.i3d" wheel="4" />
    </driveGroundParticleSystems>

    <ackermannSteering rotSpeed="60" rotMax="45" rotCenterWheel1="2" rotCenterWheel2="3" />
	
    <dynamicallyLoadedParts>
        <dynamicallyLoadedPart node="1|1" linkNode="1>3|0" filename="Textures/VR.i3d" />
        <dynamicallyLoadedPart node="1|0" linkNode="1>4|0" filename="Textures/VR.i3d" />
        <dynamicallyLoadedPart node="0|0" linkNode="2"   filename="Textures/HR.i3d" />
        <dynamicallyLoadedPart node="0|1" linkNode="3"   filename="Textures/HR.i3d" />
    </dynamicallyLoadedParts>
	
    <differentials>
        <differential torqueRatio="0.5" maxSpeedRatio="1.55" wheelIndex1="2" wheelIndex2="3" /> <!-- back left-right -->
     </differentials>

    <motor torqueScale="0.598" minRpm="100" maxRpm="1500" maxBackwardSpeed="10" brakeForce="4" lowBrakeForceScale="0.5" lowBrakeForceSpeedLimit="1" minForwardGearRatio="19.7" maxForwardGearRatio="130" minBackwardGearRatio="50" maxBackwardGearRatio="130">
        <torque normRpm="0.45" torque="0.9"/>
        <torque normRpm="0.5" torque="0.97"/>
        <torque normRpm="0.59" torque="1"/>
        <torque normRpm="0.72" torque="1"/>
        <torque normRpm="0.86" torque="0.88"/>
        <torque normRpm="1" torque="0.72"/>
    </motor>

    <fuelCapacity>100</fuelCapacity>
    <fuelUsage>20</fuelUsage>
	
	<bunkerSiloCompacter compactingScale="0.7"/>

    <cameras count="2">
        <camera1 index="4|0|0" rotatable="true" rotateNode="4|0" limit="true" useWorldXZRotation="true" rotMinX="-1.4" rotMaxX="1" transMin="4" transMax="35" >
            <raycastNode index="0>19"/>
            <raycastNode index="0>20"/>
        </camera1>
        <camera2 index="4|1" rotatable="true" limit="true" rotMinX="-1" rotMaxX="1.4" transMin="0" transMax="0" isInside="true" />
    </cameras>


    <lights>
        <light realLight="0>5|0"  decoration="0>39|0|0" lightType="0"/>
        <light realLight="0>5|1" decoration="0>39|1|0" lightType="1"/>
    </lights>

    <indoorHud>
        <rpm animName="rpmDisplay" />
    </indoorHud>

    <beaconLights>
        <beaconLight index="0>36|10|0|0" speed="0.018" filename="$data/vehicles/shared/beaconLight01.i3d" />
    </beaconLights>

    <turnSignals>
        <turnSignalLeft index="0>31|0" />
        <turnSignalRight index="0>31|1" />
    </turnSignals>
	
	    
	<exitPoint index="6" />
    <steering index="7|0" indoorRotation="540" outdoorRotation="80" />
	<betterSteeringAnimation steerKnobRot="7|0|1" />
    <enterReferenceNode index="0>" />

    <motorStartDuration>1500</motorStartDuration>
    <attachSound file="$data/vehicles/shared/attach.wav" pitchOffset="1" />
    <motorStartSound file="kramerKL600_start.wav" pitchOffset="0.795" volume="1" />
    <motorSound file="kramerKL600_idle.wav" pitchOffset="1" pitchScale="0.02" pitchMax="1.35" volume="1.3" radius="48" innerRadius="20" />
    <motorSoundRun file="podler.wav" pitchOffset="0.65" pitchScale="0.009" pitchMax="1.175" volume="0.875" />
	<motorSoundRun2 file="podler.wav" pitchOffset="0.75" volume="0.3" pitchMax="1.25" volumeMax="1"/>
    <motorStopSound file="kramerKL600_stop.wav" pitchOffset="1" volume="0.5" />
    <compressedAirSound file="Sound/Brakesystem.wav" pitchOffset="1" volume="1.25"/>
    <compressionSound file="$data/vehicles/shared/brakeBig.wav" pitchOffset="1" volume="1.5"/>
    <hydraulicSound file="$data/vehicles/shared/hydraulicUp.wav" pitchOffset="0.55" volume="0.8" />
    <honkSound file="$data/vehicles/shared/horn.wav" volume="1" radius="70" innerRadius="10" />

    <exhaustEffects>
        <exhaustEffect index="0>15" filename="$data/vehicles/particleAnimations/shared/exhaust.i3d"  minRpmColor="0.5 0.5 0.5 0.05" maxRpmColor="0 0 0 3" minRpmScale="0.05" maxRpmScale="0.5" forwardXRotations="-250 0 50" forwardZRotations="0 0 0" steerXRotations="0 0 0" steerZRotations="-100 0 100" />
    </exhaustEffects>
	<newExhaustEffects maxMotorLoad="0.2">
		<particle node="0>32|1|0" position="0 0.14 0.05" rotation="0 0 0" file="newRealParticles.i3d" />
	</newExhaustEffects>
	
	<realExhaustParticleSystem hasSecondPS="true" parameter="exhaustingSystem" minAlpha="0.1" maxAlpha="1" flap="1|6" flapMaxRot="-79">
		<SecondParticleSystem node="0>32|1|0" position="0 0.05 0.05" rotation="0 0 0" file="newRealParticles.i3d" />
	</realExhaustParticleSystem>	
	
    <attacherJoints>
        <attacherJoint index="9|0|0" rotationNode="9" minRot="28 0 0" minRot2="-24 0 0" maxRot="12 0 0" rotationNode2="9|0" maxRot2="-12 0 0" maxTransLimit="0 0.5 0" maxRotLimit="0 0 20" moveTime="1.5" ptoOutputNode="0>21" ptoFilename="$data/vehicles/shared/powerTakeoff.i3d">
            <bottomArm rotationNode="10" translationNode="10|0" referenceNode="10|0|0" zScale="-1" />
            <topArm baseNode="11" filename="$data/vehicles/shared/upperLink.i3d" zScale="-1" />
        </attacherJoint>
		<attacherJoint index="12|0" jointType="trailer" maxRotLimit="10 50 50" minRotRotationOffset="0" allowsJointLimitMovement="false" ptoOutputNode="0>21" ptoFilename="$data/vehicles/shared/powerTakeoff.i3d"/>
        <attacherJoint index="12|1" jointType="trailer" maxRotLimit="10 50 50" minRotRotationOffset="0" allowsJointLimitMovement="false" />
        <attacherJoint index="13" jointType="trailerLow" maxRotLimit="10 50 50" minRotRotationOffset="0" allowsJointLimitMovement="false" ptoOutputNode="0>21" ptoFilename="$data/vehicles/shared/powerTakeoff.i3d" />
        <attacherJoint index="0>36|3" jointType="attachableFrontloader" minRot="0 0 0" minRot2="0 0 0" maxRot="0 0 0" maxRot2="0 0 0" maxTransLimit="0 0 0" maxRotLimit="0 0 0" moveTime="2" />
    </attacherJoints>

	<characterNode index="8|0" cameraMinDistance="1.5" filename="$dataS2/character/player/player.i3d" characterMesh="1" characterGloves="2" characterSkin="0" spineNode="0|0" leftArmIKChainId="leftArm" rightArmIKChainId="rightArm" spineRotation="180 0 107" >
        <ikChains>
            <ikChain id="rightFoot" target="8|1" targetOffset="0 0.1 0" alignToTarget="true" isDirtyOnLoad="true" >
                <node index="0|1" />
                <node index="0|1|0"     minRx="0" maxRx="0" minRy="-30" maxRy="30" minRz="0"   maxRz="90" />
                <node index="0|1|0|0"   minRx="0" maxRx="0" minRy="0"   maxRy="0"  minRz="-100" maxRz="-7" />
                <node index="0|1|0|0|0" />
            </ikChain>
            <ikChain id="leftFoot" target="8|2" targetOffset="0 0.1 0" alignToTarget="true" isDirtyOnLoad="true">
                <node index="0|2"     />
                <node index="0|2|0"     minRx="0" maxRx="0" minRy="-30" maxRy="30" minRz="0"   maxRz="90" />
                <node index="0|2|0|0"   minRx="0" maxRx="0" minRy="0"   maxRy="0"  minRz="-100" maxRz="-7" />
                <node index="0|2|0|0|0" />
            </ikChain>
            <ikChain id="rightArm" target="7|0|1|0" targetOffset="0.025 0.066 0" alignToTarget="true" isDirtyOnLoad="true">
                <node index="0|0|0|1" />
                <node index="0|0|0|1|0" minRx="-20" maxRx="20" minRy="-20" maxRy="20" minRz="-80" maxRz="80" />
                <node index="0|0|0|1|0|0" minRx="-10" maxRx="10" minRy="0" maxRy="0" minRz="7"   maxRz="130" />
                <node index="0|0|0|1|0|0|0" />
                <rotationNode index="0|0|0|1|0|0|0|0" rotation="0 0 -60" />
                <rotationNode index="0|0|0|1|0|0|0|0|0" rotation="0 0 -60" />
                <rotationNode index="0|0|0|1|0|0|0|1" rotation="-90 20 -40" />
                <rotationNode index="0|0|0|1|0|0|0|1|0" rotation="0 0 -40" />
            </ikChain>
            <ikChain id="leftArm" target="8|3" targetOffset="-0.025 0.066 0" alignToTarget="true" isDirtyOnLoad="true">
                <node index="0|0|0|2" />
                <node index="0|0|0|2|0" minRx="-20" maxRx="20" minRy="-20" maxRy="20" minRz="-80" maxRz="80" />
                <node index="0|0|0|2|0|0" minRx="-10" maxRx="10" minRy="0" maxRy="0" minRz="7"   maxRz="130" />
                <node index="0|0|0|2|0|0|0" />
                <rotationNode index="0|0|0|2|0|0|0|0" rotation="0 0 -60" />
                <rotationNode index="0|0|0|2|0|0|0|0|0" rotation="0 0 -60" />
                <rotationNode index="0|0|0|2|0|0|0|1" rotation="-90 20 -40" />
                <rotationNode index="0|0|0|2|0|0|0|1|0" rotation="0 0 -40" />
            </ikChain>
        </ikChains>
    </characterNode>
	
    <aiTrafficCollisionTrigger index="14" />

	<steeringAnimationNodes>
		<animationNode wheelIndex="0" index="0>38|2" minXRot="30" maxXRot="-30" />
		<animationNode wheelIndex="1" index="0>38|3" minXRot="-30" maxXRot="30" />
	</steeringAnimationNodes>

    <movingTools>
        <!-- attacher joint back bottom-->
        <movingTool index="0>10">
            <dependentPart index="0>22" />
        </movingTool>
    </movingTools>

    <movingParts>
        <!-- attacher joint back bottom-->
        <movingPart index="0>22" referencePoint="0>10|0|1" localReferencePoint="0>22|0" referenceFrame="0>24" >
            <dependentPart index="0>22|0" />
        </movingPart>
        <movingPart index="0>22|0" referencePoint="0>10|0|1" referenceFrame="0>10|0|1" />

        <!-- steering -->
		<movingPart index="0>38|2|0" referencePoint="1>4|1|1" referenceFrame="1>" scaleZ="false" isActiveDirty="true" >
        </movingPart>
		<movingPart index="0>38|3|0" referencePoint="1>3|2|1" referenceFrame="0>" scaleZ="false" isActiveDirty="true" >
        </movingPart>

		<!-- Vorderachse -->
		<movingPart index="0>37|0" referencePoint="1>6" referenceFrame="1>" scaleZ="true" isActiveDirty="true" >
        </movingPart>
		<movingPart index="0>37|1" referencePoint="1>7" referenceFrame="0>" scaleZ="true" isActiveDirty="true" >
        </movingPart>
    </movingParts>
	<ZylinderV2> 
		<Rotations count="2">
			<Rotation1 index="23" ref="1>4" addDegrees="0" rotAxis="x" getRotAxis="y" lengthMultiplicator="-1" />
			<Rotation2 index="38" ref="1>3" addDegrees="0" rotAxis="x" getRotAxis="y" lengthMultiplicator="1" />
   		</Rotations>
		<Directions count="2">
			<Direction1 index="23|0" ref="1>4|2" doScaleBool="true" scaleRef="23|0|0" /> <!-- Spurstange -->
			<Direction2 index="38|0" ref="1>3|2" doScaleBool="true" scaleRef="38|0|0" /> <!-- Spurstange -->
		</Directions>		
	</ZylinderV2>
	
	<animations>
		<animation name="engineCover">
			<part node="0>36|2|2" startTime="0" duration="0.1" startTrans="0 0 0" endTrans="2.101 -1 0" startRot="0 0 0" endRot="0 0 90"/>
			<part node="0>36|3|2" startTime="0" duration="0.1" startTrans="0 0 0" endTrans="-0.911 -1.518 -1.78" startRot="0 0 0" endRot="-27.995 -3.343 -4.258"/>
        </animation>
		<animation name="doorr">
			<part node="0>36|3" startTime="0" duration="2" startRot="0 0 0" endRot="0 140 0"/>
        </animation>	
		<animation name="doorl">
			<part node="0>36|2" startTime="0" duration="2" startRot="0 0 0" endRot="0 -140 0"/>
        </animation>	
		<animation name="rearwindow">
            <part node="0>36|4" startTime="0" duration="2" startRot="0 0 0" endRot="23 0 0" />
        </animation>
		<animation name="poklopacdesni">
            <part node="0>36|5|1" startTime="0" duration="2" startRot="0 0 0" endRot="0 0 -85" />
        </animation>
		<animation name="poklopaclevi">
			<part node="0>36|5|2" startTime="0" duration="2" startRot="0 0 0" endRot="0 0 85"/>
        </animation>
		<animation name="rpmDisplay">
            <part node="0>36|6|0" startTime="0" endTime="1" startRot="0 0 0" endRot="0 -159 0" />
        </animation>
		<animation name="cep1">
			<part node="0>36|5|3" startTime="0" duration="2" startRot="0 0 0" endRot="0 0 90"/>
	    </animation>
		<animation name="cep2">
			<part node="0>36|5|4" startTime="0" duration="2" startRot="0 0 0" endRot="0 0 90"/>
	    </animation>
	</animations>

	<interactiveComponents>
		<windows>
            <window name="poklopacdesni"    mark="0>36|5|1|2" 		   size="0.1" animName="poklopacdesni" 	 nMessage="ic_component_open" offMessage="ic_component_close"/>
     		<window name="rearwindow"    	mark="0>36|4|1" 		   size="0.1" animName="rearwindow" 	onMessage="ic_component_open" offMessage="ic_component_close"/>
			<window name="doorr"    		mark="0>36|3|1" 		   size="0.1" animName="doorr" 			onMessage="ic_component_open" offMessage="ic_component_close"/>
			<window name="doorl"    		mark="0>36|2|1" 		   size="0.1" animName="doorl" 			onMessage="ic_component_open" offMessage="ic_component_close"/>
			<window name="poklopaclevi"     mark="0>36|5|2|2" 		   size="0.1" animName="poklopaclevi" 	onMessage="ic_component_open" offMessage="ic_component_close"/>
			<window name="cep1"    		    mark="0>36|5|3|1" 		   size="0.1" animName="cep1" 			onMessage="ic_component_open" offMessage="ic_component_close"/>
			<window name="cep2"    		    mark="0>36|5|4|1" 		   size="0.1" animName="cep2" 			onMessage="ic_component_open" offMessage="ic_component_close"/>
		</windows>
	</interactiveComponents>
	<!-- Door Opener -->
	<doorOpener trigger="0>36|2|2" icIndex="1" />
	<doorOpener trigger="0>36|3|2" icIndex="1" />
	<!---->
	<controlPanels count="2" >
		<controlPanel1 index="0>36|0" />
		<controlPanel2 index="0>42|1" />
	</controlPanels>
	
    <ventelator1 index="0>36|7"/>
	<ventelator2 index="0>36|8"/>
	
    <components count="2">
        <component1 centerOfMass="0 0.3 -0.4" solverIterationCount="10" />
        <component2 centerOfMass="0 0 0" solverIterationCount="10" />
       <joint component1="0" component2="1" index="1>0" rotLimit="0 0 8" transLimit="0 0.01 0" rotLimitSpring="0 0 8" rotLimitDamping="0 0 8" />
    </components>

    <washable dirtDuration="10" washDuration="1" workMultiplier="4" />
	
    <schemaOverlay file="$dataS2/menu/schemas/vehicleSchema.png" fileSelected="$dataS2/menu/schemas/vehicleSchemaSelected.png" width="0.5" height="0.5" attacherJointPosition="0.5 0">
        <attacherJoint position="1 0" rotation="0" invertX="false" />
        <attacherJoint position="1 0" rotation="0" invertX="false" />
        <attacherJoint position="0 0" rotation="0" invertX="true" />
        <attacherJoint position="1 0" rotation="0" invertX="false" />
    </schemaOverlay>

</vehicle>
