<?xml version="1.0" encoding="utf-8" standalone="no" ?>
<vehicle type="wheelBarrow">
    <storeData>
        <name>Talicska</name>
        <specs>
            <maxSpeed>10</maxSpeed>
            <capacity>258</capacity>
			<fillTypeCategories>BULK</fillTypeCategories>
        </specs>
        <functions>
            <function>$l10n_function_wheelBarrow</function>
        </functions>
        <image>store/store_wheelBarrow.png</image>
        <price>80</price>
        <lifetime>600</lifetime>
        <rotation>0</rotation>
		<brand>GBF</brand>
        <category>GBFE</category>
    </storeData>

    <base>
        <typeDesc>$l10n_typeDesc_wheelBarrow</typeDesc>
        <filename>sajat/talicska.i3d</filename>
		<supportsRadio>false</supportsRadio>
		<canBeReset>true</canBeReset>
		<supportsPickUp>true</supportsPickUp>
        <size width="1" length="2" lengthOffset="0"/>
        <components maxMass="350">
            <component centerOfMass="0 -0.2 -0.183" solverIterationCount="10" mass="50" />
        </components>
		<schemaOverlay attacherJointPosition="0 0" name="VEHICLE_WHEELBARROW" />
        <sounds volumeFactor="0.8" />
    </base>

    <wheels>
        <wheelConfigurations>
            <wheelConfiguration name="$l10n_configuration_valueDefault" price="0">
                <wheels autoRotateBackSpeed="10.0" speedDependentRotateBack="false">
                    <wheel hasParticles="true" hasTireTracks="true">
                        <physics rotSpeed="1" restLoad="0.6" repr="wheelMiddle" showSteeringAngle="false" radius="0.25" width="0.1" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
						<tire maxDeformation="0" tireTrackAtlasIndex="4" isCareWheel="true"/>
                    </wheel>
                    <wheel hasParticles="false" hasTireTracks="false">
                        <physics tipOcclusionAreaGroupId="1" rotSpeed="1" restLoad="0.6" repr="wheelLeft"  showSteeringAngle="false"  radius="0.23" width="0.27" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
                        <tire maxDeformation="0" tireTrackAtlasIndex="4" isCareWheel="true"/>
                    </wheel>
                    <wheel hasParticles="false" hasTireTracks="false">
                        <physics tipOcclusionAreaGroupId="1" rotSpeed="1" restLoad="0.6" repr="wheelRight"  showSteeringAngle="false"  radius="0.23" width="0.27" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
                        <tire maxDeformation="0" tireTrackAtlasIndex="4" isCareWheel="true"/>
                    </wheel>
                </wheels>
            </wheelConfiguration>

			<wheelConfiguration name="$l10n_configuration_valueOffRoad" price="0">
                <wheels autoRotateBackSpeed="10.0" speedDependentRotateBack="false">
					<wheel filename="$data/shared/wheels/tires/mitas/FL02/7_R12.xml" hasTireTracks="true" hasParticles="false" >
                        <physics rotSpeed="1" restLoad="0.5" repr="wheelMiddle" showSteeringAngle="false" useReprDirection="false" radius="0.20" width="0.15" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
						<tire maxDeformation="0.02" isCareWheel="true"/>
					</wheel>
					
                    <wheel hasParticles="false" hasTireTracks="false">
                        <physics tipOcclusionAreaGroupId="1" rotSpeed="1" restLoad="0.6" repr="wheelLeft"  showSteeringAngle="false"  radius="0.23" width="0.27" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
                        <tire maxDeformation="0" tireTrackAtlasIndex="4" isCareWheel="true"/>
                    </wheel>
                    <wheel hasParticles="false" hasTireTracks="false">
                        <physics tipOcclusionAreaGroupId="1" rotSpeed="1" restLoad="0.6" repr="wheelRight"  showSteeringAngle="false"  radius="0.23" width="0.27" forcePointRatio="0.5" initialCompression="25" suspTravel="0.09" spring="20" damper="3" frictionScale="2.5" mass="0.01"/>
                        <tire maxDeformation="0" tireTrackAtlasIndex="4" isCareWheel="true"/>
                    </wheel>
				</wheels>
				<objectChange node="wheelMiddle" scaleActive="0.62 0.64 0.64" />
				<objectChange node="wheelMiddle" translationActive="0 0.256 0.456" />
				<objectChange node="wheelAxle" visibilityActive="true"/>
            </wheelConfiguration>
        </wheelConfigurations>

        <ackermannSteeringConfigurations>
            <ackermannSteering rotSpeed="70" rotMax="20" rotCenter="0 0"/>
        </ackermannSteeringConfigurations>
    </wheels>

	<enterable isTabbable="true" enterText="$l10n_enterText_wheelBarrow">
        <enterReferenceNode node="enterReferenceNode" interactionRadius="2.0"/>
        <exitPoint node="enterReferenceNode"/>
		<nicknameRenderNode node="playerNode" offset="0 2 0"/>
        
		<cameras>
            <camera node="outdoorCamera" rotatable="true" rotateNode="outdoorCameraTarget" limit="true" useWorldXZRotation="true" rotMinX="-1.4" rotMaxX="1" transMin="3" transMax="20">
                <raycastNode node="cameraRaycastNode1"/>
                <raycastNode node="cameraRaycastNode2"/>
            </camera>
            <camera node="indoorCamera" rotatable="true" limit="true" rotMinX="-1.1" rotMaxX="0.4" transMin="0" transMax="0" useMirror="true" isInside="false" />
        </cameras>

		<characterNode node="skeleton" animationNode="2" cameraMinDistance="0.25" spineRotation="270 0 90" useAnimation="true" />
		<enterAnimation name="enterAnimation"/>
    </enterable>

	<motorized turnOnText="$l10n_action_farmEquipmentOnText" turnOffText="$l10n_action_farmEquipmentOffText">
        <differentialConfigurations>
            <differentialConfiguration>
                <differentials>
                    <differential torqueRatio="0.2" maxSpeedRatio="3.0" wheelIndex1="2" wheelIndex2="3"/>
                </differentials>
            </differentialConfiguration>
        </differentialConfigurations>
       	
		<motorConfigurations>
            <motorConfiguration hp="0">
				<motor torqueScale="0.077" minRpm="850" maxRpm="2200" maxForwardSpeed="10" maxBackwardSpeed="5" brakeForce="0.1" lowBrakeForceScale="0.001" accelerationLimit="2" dampingRateFullThrottle="0.00005" dampingRateZeroThrottleClutchEngaged="0.00033" dampingRateZeroThrottleClutchDisengaged="0.00033">
                    <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>
                <transmission minForwardGearRatio="79" maxForwardGearRatio="300" minBackwardGearRatio="170" maxBackwardGearRatio="250" />
            </motorConfiguration>
        </motorConfigurations>
    </motorized>

	<pushHandTool>
        <raycast node1="raycast01" node2="raycast02" playerNode="playerNode"/>
        <wheels front="1" back="2 3"/>

        <ikChains>
            <target ikChain="rightArm"  targetNode="playerRightHandTarget" poseId="wideFingers" /> 
            <target ikChain="leftArm"   targetNode="playerLeftHandTarget" poseId="wideFingers"/>
        </ikChains>

		<customChainLimits>
            <customChainLimit chainId="leftArm" nodeIndex="1" minRx="-30" maxRx="30" minRy="40" maxRy="65" minRz="-90" maxRz="40" localLimits="true"/>
            <customChainLimit chainId="leftArm" nodeIndex="2" minRx="-25" maxRx="25" minRy="0" maxRy="0" minRz="-144" maxRz="-3" localLimits="true"/>

            <customChainLimit chainId="rightArm" nodeIndex="1" minRx="-30" maxRx="30" minRy="40" maxRy="65" minRz="-90" maxRz="40" localLimits="true"/>
            <customChainLimit chainId="rightArm" nodeIndex="2" minRx="-25" maxRx="25" minRy="0" maxRy="0" minRz="-144" maxRz="-3" localLimits="true"/>
        </customChainLimits>

        <playerConditionalAnimation>
            <item id="idle" entryTransitionDuration="0.25" exitTransitionDuration="0.25" >
                <clips>
                    <clip clipName="idleSource" />
                </clips>
                <conditions>
                    <conditionGroup>
                        <condition parameter="absSmoothedForwardVelocity" lower="0.2" />
                    </conditionGroup>
                </conditions>
            </item>
            <item id="walk" entryTransitionDuration="0.25" exitTransitionDuration="0.25" >
                <clips speedScaleType="distance" speedScaleParameter="2">
                    <clip clipName="walkFwdLoopSource" />
                </clips>
                <conditions>
                    <conditionGroup>
                        <condition parameter="smoothedForwardVelocity" between="0.2, 4"/>
                    </conditionGroup>
                </conditions>
            </item>
            <item id="walkBack" entryTransitionDuration="0.5" exitTransitionDuration="0.25" >
                <clips speedScaleType="distance" speedScaleParameter="2">
                    <clip clipName="walkBwdLoopSource" />
                </clips>
                <conditions>
                    <conditionGroup>
                        <condition parameter="smoothedForwardVelocity" between="-3, -0.2" />
                    </conditionGroup>
                </conditions>
            </item>
        </playerConditionalAnimation>
    </pushHandTool>

	<lights>
	</lights>

	<ai supportsAIJobs="false" />

	<mower fruitTypeConverter="MOWER">
    </mower>

	<drivable>
        <sounds>
            <waterSplash template="WATER_SPLASH_01"/>
        </sounds>
        <cruiseControl enabled="false"/>
    </drivable>

	<shovel>
		<shovelNode node="pickUpNode" fillUnitIndex="1" width="1" length="3" yOffset="-0.5" zOffset="0" needsMovement="false" needsActivation="true" fillLitersPerSecond="500" needsAttacherVehicle="false"/>   
		<dischargeInfo node="dischargeNode" minSpeedAngle="125" maxSpeedAngle="180" />
    </shovel>

    <fillUnit>
        <fillUnitConfigurations>
            <fillUnitConfiguration>
                <fillUnits>
                    <fillUnit shopDisplayUnit="CUBICMETER" fillTypeCategories="bulk" capacity="258" startFillLevel="1"  minFillLevel="1" maxFillLevel="258" updateFillLevelMass="true" showOnHud="true">
                        <exactFillRootNode node="exactFillRootNode"/>
                    </fillUnit>
                </fillUnits>
            </fillUnitConfiguration>
        </fillUnitConfigurations>
    </fillUnit>

    <fillVolume>
        <fillVolumeConfigurations>
            <fillVolumeConfiguration>
                <volumes>
                    <volume node="fillVolume" maxDelta="1.2" maxAllowedHeapAngle="45" maxSubDivEdgeLength="0.9" fillUnitIndex="1"  />
                </volumes>
            </fillVolumeConfiguration>
        </fillVolumeConfigurations>

		<loadInfos>
            <loadInfo>
                <node node="fillVolumeLoadNode" width="0.5" length="0.5" />
            </loadInfo>
        </loadInfos>

        <unloadInfos>
            <unloadInfo>
                <node node="fillVolumeUnloadNode" width="0.2" length="0.2" />
            </unloadInfo>
        </unloadInfos>
    </fillVolume>

	<cylindered>
        <movingTools>
            <movingTool node="wheelBarrow_vis" playSound="false" isActiveDirty="true">
                <controls axis="AXIS_FRONTLOADER_ARM" invertAxis="true" mouseSpeedFactor="0.6" iconName="WHEELBARROW_UNLOAD_ROTATION" />
				<animation animName="dischargeAnimation" animSpeed="1" allowSaving="false"/>
            </movingTool>
        </movingTools>
    </cylindered>

	<dischargeable requiresTipOcclusionArea="false">
        <dischargeNode node="dischargeNode" fillUnitIndex="1" emptySpeed="400" unloadInfoIndex="1" loadInfoIndex="1" canStartDischargeAutomatically="false">
            <raycast node="dischargeNode" maxDistance="6" useWorldNegYDirection="true" yOffset="0"/>
            <info width="1.0" length="0.5" zOffset="0.5"/>

			<effects>
				<effectNode effectNode="emitterShape" effectClass="ParticleEffect" materialType="unloadingParticle" lifespan="0.2"/>
                <effectNode effectNode="effectSmoke" materialType="unloadingSmoke" fadeTime="0.5" />
            </effects>
        </dischargeNode>
    </dischargeable>
		
    <animations>
        <animation name="enterAnimation">
            <part node="wheelBarrow_vis" startTime="0" endTime="0.5" startRot="0 0 0" endRot="9.5 0 0"  />
        </animation>
        <animation name="dischargeAnimation" resetOnStart="false">
            <part node="wheelBarrow_vis" startTime="0" endTime="0.8" startRot="9.5 0 0" endRot="50 0 0"   />
			<part node="playerRightHandTarget" startTime="0" endTime="0.5" startRot="0 0 40"  endRot="-55 0 40" />
			<part node="playerLeftHandTarget"  startTime="0" endTime="0.5" startRot="0 0 -40" endRot="55 0 -40"  />
			<part node="skeleton"  startTime="0" endTime="0.8" startTrans="0 0 0" endTrans="0 0 0.63"  />
        </animation>

		<animation name="turnedAnimation">
			<part node="0>9|0"  startTime="0.0" endTime="0.05" visibility="false"  />
			<part node="0>9|0"  startTime="0.05" endTime="0.10" visibility="true"  />
			<part node="0>10|1"  startTime="0.0" endTime="0.05" visibility="false"  />
			<part node="0>10|1"  startTime="0.05" endTime="0.10" visibility="true"  />
        </animation>

		<animation name="turnedOnAnimation" resetOnStart="true" looping="true">
			<part node="0>9|1" startTime="0" endTime="3.875" animationClip="lapatosSource" clipStartTime="0" clipEndTime="5875" />
			<part node="0>10|0" startTime="0" endTime="3.875" animationClip="lapatSource" clipStartTime="0" clipEndTime="5833" />
        </animation>
    </animations>

	<turnOnVehicle requiresMotorTurnOn="false" turnedOnByAttacherVehicle="false" turnOffOnDeactivate="false" motorNotStartedWarning="workModeNotStarted_warning" toggleButton="TOGGLE_WORKMODE" turnOnText="$l10n_turnOn_barrowPickup" turnOffText="$l10n_turnOff_barrowPickup">
		<turnedAnimation name="turnedAnimation"/>
		<turnedOnAnimation name="turnedOnAnimation"/>
		<sounds>
            <work file="sounds/shovelPickup.wav" innerRadius="15.0" outerRadius="45.0"  linkNode="0>11" >
				<volume indoor="1.00" outdoor="1.00" />
			</work>	
        </sounds>
	</turnOnVehicle>
	
	<tensionBeltObject>
        <meshNodes>
            <meshNode node="wheelBarrow_vis"/>
        </meshNodes>
    </tensionBeltObject>	

	<baseMaterial>
        <material name="test1" baseNode="0>1|0|11|3">
			<shaderParameter name="colorMat0" value="FORTSCHRITT_BLUE"/>
		</material>
		<material name="test3" baseNode="0>10|1|1">
			<shaderParameter name="colorMat0" value="FORTSCHRITT_BLUE"/>
		</material>
		<material name="test2" baseNode="0>0|0|0">
			<shaderParameter name="colorMat1" value="GESSNER_BLACK2"/>
		</material>
    </baseMaterial>

	<baseMaterialConfigurations price="0" useDefaultColors="true" defaultColorIndex="0">
		<baseMaterialConfiguration color="FORTSCHRITT_BLUE"/>
		<baseMaterialConfiguration color="FENDT_OLDGREEN1"/>
		<baseMaterialConfiguration name="FORTSCHRITT_BLUE" material="16" color="1 1 1 1"/>
		<baseMaterialConfiguration name="ZINC" material="4" color="0.5 0.5 0.5 4"/>
		<material name="test1" shaderParameter="colorMat0" />
		<material name="test3" shaderParameter="colorMat0" />
    </baseMaterialConfigurations>

	<designMaterialConfigurations price="0" useDefaultColors="true" defaultColorIndex="0">
		<baseMaterialConfiguration color="GESSNER_BLACK2"/>
        <designMaterialConfiguration name="ZINC" material="4" color="0.5 0.5 0.5 4"/>
        <designMaterialConfiguration name="STAINLESS STEEL" material="8" color="1 1 1 8"/>
        <material name="test2" shaderParameter="colorMat1" />
    </designMaterialConfigurations>


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

	<i3dMappings>
		<i3dMapping id="wheelBarrow_main_component1" node="0>" />
		<i3dMapping id="wheelMiddle" node="0>0|0" />
		<i3dMapping id="wheelAxle" node="0>0|0|0" />
		<i3dMapping id="wheelLeft" node="0>0|1" />
		<i3dMapping id="wheelRight" node="0>0|2" />
		<i3dMapping id="wheelBarrowRotationNode" node="0>1" />
		<i3dMapping id="wheelBarrow_vis" node="0>1|0" />
		<i3dMapping id="exactFillRootNode" node="0>1|0|0" />
		<i3dMapping id="dischargeNode" node="0>1|0|1" />
		<i3dMapping id="fillVolume" node="0>1|0|2|0" />
		<i3dMapping id="fillVolumeUnloadNode" node="0>1|0|3" />
		<i3dMapping id="fillVolumeLoadNode" node="0>1|0|3" />
		<i3dMapping id="effects" node="0>1|0|4" />
		<i3dMapping id="effectUnloading" node="0>1|0|4|0" />
		<i3dMapping id="effectSmoke" node="0>1|0|4|1" />
		<i3dMapping id="emitterShape" node="0>1|0|4|2" />
		<i3dMapping id="enterReferenceNode" node="0>2" />
		<i3dMapping id="outdoorCameraTarget" node="0>3|0" />
		<i3dMapping id="outdoorCamera" node="0>3|0|0" />
		<i3dMapping id="indoorCamera" node="0>3|1" />
		<i3dMapping id="cameraRaycastNode1" node="0>3|2" />
		<i3dMapping id="cameraRaycastNode2" node="0>3|3" />
		<i3dMapping id="aiCollisionTrigger" node="0>4" />
		<i3dMapping id="steeringBase" node="0>5" />
		<i3dMapping id="steeringWheel" node="0>5|0" />
		<i3dMapping id="playerRightHandTarget" node="0>1|0|5|0" />
		<i3dMapping id="playerLeftHandTarget" node="0>1|0|5|2" />
		<i3dMapping id="player" node="0>6" />
		<i3dMapping id="playerNode" node="0>5|0" />
		<i3dMapping id="skeleton" node="0>5|0|0" />
		<i3dMapping id="raycast01" node="0>5|1" />
		<i3dMapping id="raycast02" node="0>5|2" />
		<i3dMapping id="pickUpNode" node="0>7" />
	</i3dMappings>
</vehicle>
