﻿<?xml version="1.0" encoding="utf-8" standalone="no" ?>
<vehicle type="livestockTrailer" 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>Belvedere</name>
        <specs>
            <combination xmlFilename="$data/vehicles/lizard/pickup1986/pickup1986.xml" />
            <combination xmlFilename="$data/vehicles/lizard/pickup2017/pickup2017.xml" />
        </specs>
        <functions>
            <function>$l10n_function_livestockTrailer</function>
        </functions>
        <image>$data/vehicles/kingstonTrailers/belvedere/store_belvedere.png</image>
        <price>22000</price>
        <lifetime>600</lifetime>
        <rotation>0</rotation>
        <brand>KINGSTON</brand>
        <category>animalTransport</category>
        <shopTranslationOffset>0 0.095 0</shopTranslationOffset>
        <shopRotationOffset>-0.242 0 0</shopRotationOffset>
        <vertexBufferMemoryUsage>1857280</vertexBufferMemoryUsage>
        <indexBufferMemoryUsage>335872</indexBufferMemoryUsage>
        <textureMemoryUsage>2883584</textureMemoryUsage>
        <instanceVertexBufferMemoryUsage>0</instanceVertexBufferMemoryUsage>
        <instanceIndexBufferMemoryUsage>0</instanceIndexBufferMemoryUsage>
        <audioMemoryUsage>0</audioMemoryUsage>
    </storeData>

    <base>
        <typeDesc>$l10n_typeDesc_livestockTrailer</typeDesc>
        <filename>$data/vehicles/kingstonTrailers/belvedere/belvedere.i3d</filename>
        <size width="3.2" length="7.5" height="3"/>
        <components>
            <component centerOfMass="0 0.3 0" solverIterationCount="10" mass="1470" />
            <component centerOfMass="0 0 0" solverIterationCount="10" mass="200" />
            <joint component1="1" component2="2" node="backdoorJoint"  rotLimit="0 0 0" transLimit="0 0 0"/>
        </components>
        <schemaOverlay attacherJointPosition="0 0" name="IMPLEMENT" />
        <mapHotspot type="TRAILER" />
    </base>

    <wheels>
        <wheelConfigurations>
            <wheelConfiguration name="$l10n_configuration_valueDefault" price="0" brand="CONTINENTAL" saveId="CONTINENTAL_DEFAULT">
                <wheels>
                    <wheel filename="$data/shared/wheels/tires/continental/terrainContactHT/275_65R18.xml" isLeft="true" hasTireTracks="true" configId="rimsPickup01">
                        <physics restLoad="0.3" repr="wheelFrontLeft"  forcePointRatio="0.5" initialCompression="25" suspTravel="0.12" spring="9" damper="15" frictionScale="2.5" />
                        <tire isCareWheel="false"/>
                        <wheelChock isInverted="true" filename="$data/shared/assets/wheelChocks/wheelChock04.i3d"/>
                    </wheel>
                    <wheel filename="$data/shared/wheels/tires/continental/terrainContactHT/275_65R18.xml" isLeft="false" hasTireTracks="true" configId="rimsPickup01">
                        <physics restLoad="0.3" repr="wheelFrontRight" forcePointRatio="0.5" initialCompression="25" suspTravel="0.12" spring="9" damper="15" frictionScale="2.5" />
                        <tire isCareWheel="false"/>
                    </wheel>
                    <wheel filename="$data/shared/wheels/tires/continental/terrainContactHT/275_65R18.xml" isLeft="true" hasTireTracks="true" hasParticles="true" configId="rimsPickup01">
                        <physics restLoad="0.3" repr="wheelBackLeft"   forcePointRatio="0.5" initialCompression="25" suspTravel="0.12" spring="9" damper="15" frictionScale="2.5" yOffset="0.005" />
                        <tire isCareWheel="false"/>
                        <wheelChock filename="$data/shared/assets/wheelChocks/wheelChock04.i3d"/>
                    </wheel>
                    <wheel filename="$data/shared/wheels/tires/continental/terrainContactHT/275_65R18.xml" isLeft="false" hasTireTracks="true" hasParticles="true" configId="rimsPickup01">
                        <physics restLoad="0.3" repr="wheelBackRight"  forcePointRatio="0.5" initialCompression="25" suspTravel="0.12" spring="9" damper="15" frictionScale="2.5" yOffset="0.005" />
                        <tire isCareWheel="false"/>
                    </wheel>
                </wheels>
            </wheelConfiguration>
        </wheelConfigurations>
    </wheels>

    <rimColorConfigurations useDefaultColors="false" >
        <rimColorConfiguration name="$l10n_ui_colorChrome" color="SHARED_WHITE2" material="3" price="2000"/>
        <rimColorConfiguration name="$l10n_ui_colorSilver" color="SHARED_WHITE1" material="18" price="0"/>
        <rimColorConfiguration name="$l10n_ui_colorWhite"  color="SHARED_WHITE2" material="1" price="0"/>
        <rimColorConfiguration name="$l10n_ui_colorBlack"  color="SHARED_DA_METAL_BLACK" material="1" price="0"/>
    </rimColorConfigurations>

    <attachable>
        <inputAttacherJoints>
            <inputAttacherJoint node="attacherJoint" jointType="semitrailerCar" />
        </inputAttacherJoints>
        <brakeForce force="0.25"/>
        <support animationName="moveSupport" />
    </attachable>

    <connectionHoses>
        <hose inputAttacherJointIndices="1" type="electric" node="electric" length="0.3" diameter="0.008" straighteningFactor="2.0" isTwoPointHose="true">
            <objectChange node="electric_detached" visibilityActive="false" visibilityInactive="true"/>
        </hose>
    </connectionHoses>

    <dynamicallyLoadedParts>
        <dynamicallyLoadedPart node="1|1" linkNode="electric_connector" filename="$data/shared/connectionHoses/connectors.i3d" />
    </dynamicallyLoadedParts>

    <lights>
        <sharedLight linkNode="redRectangle_01"    filename="$data/shared/assets/reflectors/lizard/redRectangle_01.xml" />
        <sharedLight linkNode="redRectangle_02"    filename="$data/shared/assets/reflectors/lizard/redRectangle_01.xml" />
        <sharedLight linkNode="redRectangle_03"    filename="$data/shared/assets/reflectors/lizard/redRectangle_01.xml" />
        <sharedLight linkNode="redRectangle_04"    filename="$data/shared/assets/reflectors/lizard/redRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_01" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_02" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_03" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_04" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_05" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />
        <sharedLight linkNode="yellowRectangle_06" filename="$data/shared/assets/reflectors/lizard/yellowRectangle_01.xml" />

        <sharedLight linkNode="plateNumberLight02" filename="$data/shared/assets/lights/lizard/plateNumberLight02.xml" />

        <realLights>
            <high>
                <light node="backLightsHigh1"       lightTypes="0"/>
                <light node="licensePlateLightHigh" lightTypes="0"/>
                <light node="workLightBackHigh1"    lightTypes="1"/>
                <light node="workLightBackHigh2"    lightTypes="1"/>
                <brakeLight node="backLightsHigh1" />
                <turnLightLeft node="turnLightLeftBack" />
                <turnLightRight node="turnLightRightBack" />
                <reverseLight node="reverseLightHigh" excludedLightTypes="1"/>
            </high>
        </realLights>

        <defaultLights>
            <defaultLight shaderNode="defaultLightsGlass_static" lightTypes="0"/>
            <defaultLight shaderNode="backLightsGlass_static"    lightTypes="0" intensity="20"/>
            <defaultLight shaderNode="interiorLightGlass_static" lightTypes="0"/>
            <defaultLight shaderNode="worklightGlass01_static"   lightTypes="1"/>
            <defaultLight shaderNode="worklightGlass02_static"   lightTypes="1"/>
        </defaultLights>

        <brakeLights>
            <brakeLight shaderNode="brakelightGlass_static"/>
            <brakeLight shaderNode="backLightsGlass_static"/>
        </brakeLights>

        <turnLights>
            <turnLightLeft  shaderNode="turnlightLeft_static"  intensity="50"/>
            <turnLightRight shaderNode="turnlightRight_static" intensity="50"/>
        </turnLights>

        <reverseLights>
            <reverseLight shaderNode="reverseLight_static" excludedLightTypes="1"/>
            <reverseLight shaderNode="reverseLightGlass_static"/>
        </reverseLights>
    </lights>

    <licensePlates>
        <licensePlate node="licensePlateBack" position="BACK" preferedType="SQUARISH" placementArea="0.07 0.14 0.07 0.14" frame="false"/>
    </licensePlates>

    <foldable>
        <foldingConfigurations>
            <foldingConfiguration>
                <foldingParts startMoveDirection="-1" requiresPower="false">
                    <foldingPart animationName="folding" speedScale="0.75" />
                </foldingParts>
            </foldingConfiguration>
        </foldingConfigurations>
    </foldable>

    <animations>
        <animation name="moveSupport">
            <part node="supportArm"       startTime="0.10" endTime="0.50" startTrans="0 0.16 0" endTrans="0 -0.05 0" />
            <part node="supportArmPart"   startTime="0.10" endTime="0.50" startTrans="0 0.16 0" endTrans="0 -0.05 0" />
            <part node="supportCrank"     startTime="0.00" endTime="0.10" startRot="0 0 0" endRot="0 0 90" />
            <part node="supportCrank"     startTime="0.10" endTime="0.50" startRot="0 0 90" endRot="0 720 90" />
            <part node="supportCrank"     startTime="0.50" endTime="0.60" startRot="0 720 90" endRot="0 720 0" />
            <part node="supportCrankPart" startTime="0.10" endTime="0.50" startRot="0 0 0" endRot="720 0 0" />

            <sound template="clackVar1"   startTime="0.09" direction="0"   volumeScale="1.3"   pitchScale="1.7" linkNode="supportCrank"/>
            <sound template="clackVar2"   startTime="0.09" direction="0"   volumeScale="1.6"   pitchScale="2.2" linkNode="supportCrank"/>
            <sound template="clackVar1"   startTime="0.4"  direction="0"   volumeScale="1.3"   pitchScale="1.5" linkNode="supportCrank"/>
            <sound template="clackVar2"   startTime="0.6"  direction="0"   volumeScale="1.6"   pitchScale="2.5" linkNode="supportCrank"/>
            <sound template="metalClose"  startTime="0.1"  direction="-1"  volumeScale="0.5"   pitchScale="2.6" linkNode="supportArmPart"/>
            <sound template="metalClose"  startTime="0.6"  direction="1"   volumeScale="0.5"   pitchScale="2.0" linkNode="supportArmPart"/>
        </animation>

        <animation name="folding">
            <part node="door01" startTime="0.2" endTime="1.5" startRot="0 0 0" endRot="0 -265 0" />
            <part node="door01Lock" startTime="0" endTime="0.2" startRot="0 0 0" endRot="0 45 0" />
            <part node="door01Lock" startTime="1" endTime="1.5" startRot="0 45 0" endRot="0 0 0" />
            <part node="door02" startTime="0.2" endTime="1.5" startRot="0 0 0" endRot="0 265 0" />
            <part node="door02Lock" startTime="0" endTime="0.2" startRot="0 0 0" endRot="0 -45 0" />
            <part node="door02Lock" startTime="1" endTime="1.5" startRot="0 -45 0" endRot="0 0 0" />
            <part node="arm01Part" startTime="0" endTime="0.5" startRot="0 0 0" endRot="0 0 -35" />
            <part node="arm01" startTime="0.5" endTime="1.0" startRot="0 0 0" endRot="0 -90 0" />
            <part node="arm01Part" startTime="0.5" endTime="1" startRot="0 0 -35" endRot="-35 0 90" />
            <part node="arm02Part" startTime="0" endTime="0.5" startRot="0 0 0" endRot="0 0 35" />
            <part node="arm02" startTime="0.5" endTime="1.0" startRot="0 0 0" endRot="0 90 0" />
            <part node="arm02Part" startTime="0.5" endTime="1" startRot="0 0 35" endRot="35 0 -90" />
            <part node="backdoorJoint" startTime="1.3" endTime="3.0" startRot="0 0 0" endRot="-90 0 0" />
            <part componentJointIndex="1" startTime="2" endTime="3" startRotLimit="0 0 0" endRotLimit="60 0 0" />

            <sound template="metalDoorsLoop"  startTime="0.01" endTime="1.4"  volumeScale="1.2" pitchScale="1"    linkNode="backdoorJoint" fadeIn="0.1" fadeOut="0.2"/>
            <sound template="metalDoorsClose" startTime="0.2"  direction="-1" volumeScale="1.4" pitchScale="1"    linkNode="backdoorJoint"/>
            <sound template="metalDoorsOpen"  startTime="1.5"  direction="1"  volumeScale="1.4" pitchScale="1"    linkNode="backdoorJoint"/>
            <sound template="metalOpen"       startTime="2.7"  direction="1"  volumeScale="2.5" pitchScale="3"    linkNode="backdoorJoint"/>
            <sound template="clackVar6"       startTime="2.7"  direction="1"  volumeScale="1.5" pitchScale="0.8"  linkNode="backdoorJoint"/>
            <sound template="metalClose"      startTime="1.2"  direction="-1" volumeScale="3"   pitchScale="2"    linkNode="backdoorJoint"/>
            <sound template="cylinderPunch"   startTime="1.2"  direction="-1" volumeScale="0.5" pitchScale="2"    linkNode="backdoorJoint"/>
            <sound template="latchSmall"      startTime="0.01" direction="1"  volumeScale="0.3" pitchScale="2"    linkNode="backdoorJoint"/>
            <sound template="slideOpen"       startTime="2.61" direction="-1" volumeScale="4.3" pitchScale="0.6"  linkNode="backdoorJoint"/>
            <sound template="slideClose"      startTime="1.31" direction="1"  volumeScale="4.3" pitchScale="0.85" linkNode="backdoorJoint"/>
            <sound template="clackVar1"       startTime="0.1"  direction="0"  volumeScale="1.3" pitchScale="1.5"  linkNode="backdoorJoint"/>
            <sound template="clackVar2"       startTime="0.8"  direction="0"  volumeScale="1.6" pitchScale="1.7"  linkNode="backdoorJoint"/>
        </animation>
    </animations>

    <cylindered>
        <movingTools>
            <movingTool node="backdoorJoint" playSound="true">
                <componentJoint index="1" anchorActor="0" />
            </movingTool>
        </movingTools>

        <movingParts>
            <movingPart node="backDoor" referencePoint="backDoorRef" referenceFrame="backDoorRef" isActiveDirty="true" maxUpdateDistance="100"/>
            <movingPart node="backDoorPart" referencePoint="backDoorPartRef" referenceFrame="backDoorPartRef" isActiveDirty="true" maxUpdateDistance="100" scaleZ="true"/>
        </movingParts>
    </cylindered>

    <livestockTrailer>
        <animal type="horse" node="horseSlots" numSlots="2" />
        <loadTrigger node="loadTrigger" />
        <spawnPlaces>
            <spawnPlace node="spawnPlace1" width="6" />
            <spawnPlace node="spawnPlace2" width="6" />
            <spawnPlace node="spawnPlace3" width="6" />
        </spawnPlaces>
    </livestockTrailer>

    <ai>
        <agentAttachment jointNode="attacherJoint" rotCenterWheelIndices="1 2 3 4" width="2.6" height="3" length="7" lengthOffset="2.2"/>
    </ai>

    <foliageBending>
        <bendingNode minX="-1.35" maxX="1.35" minZ="-3.6" maxZ="1.3" yOffset="0.3" />
        <bendingNode minX="-1.02" maxX="1.02" minZ="0" maxZ="1.35" yOffset="0" node="backDoor"/>
        <bendingNode minX="-1.1" maxX="1.1" minZ="1.3" maxZ="3.55" yOffset="1.6" />
    </foliageBending>

    <wearable wearDuration="480" workMultiplier="5" fieldMultiplier="2"/>
    <washable dirtDuration="90" washDuration="1" workMultiplier="4" fieldMultiplier="2"/>

    <i3dMappings>
        <i3dMapping id="belvedere_main_component1" node="0>" />
        <i3dMapping id="wheelFrontLeft" node="0>0|0|0" />
        <i3dMapping id="wheelFrontRight" node="0>0|0|1" />
        <i3dMapping id="wheelBackLeft" node="0>0|0|2" />
        <i3dMapping id="wheelBackRight" node="0>0|0|3" />
        <i3dMapping id="redRectangle_01" node="0>0|1|0|0" />
        <i3dMapping id="redRectangle_02" node="0>0|1|0|1" />
        <i3dMapping id="redRectangle_03" node="0>0|1|0|2" />
        <i3dMapping id="redRectangle_04" node="0>0|1|0|3" />
        <i3dMapping id="yellowRectangle_01" node="0>0|1|0|4" />
        <i3dMapping id="yellowRectangle_02" node="0>0|1|0|5" />
        <i3dMapping id="yellowRectangle_03" node="0>0|1|0|6" />
        <i3dMapping id="yellowRectangle_04" node="0>0|1|0|7" />
        <i3dMapping id="yellowRectangle_05" node="0>0|1|0|8" />
        <i3dMapping id="yellowRectangle_06" node="0>0|1|0|9" />
        <i3dMapping id="defaultLightsGlass_static" node="0>0|1|1|0" />
        <i3dMapping id="backLightsGlass_static" node="0>0|1|1|1" />
        <i3dMapping id="brakelightGlass_static" node="0>0|1|1|2" />
        <i3dMapping id="turnlightLeft_static" node="0>0|1|1|3" />
        <i3dMapping id="turnlightRight_static" node="0>0|1|1|4" />
        <i3dMapping id="worklightGlass01_static" node="0>0|1|1|5" />
        <i3dMapping id="worklightGlass02_static" node="0>0|1|1|6" />
        <i3dMapping id="interiorLightGlass_static" node="0>0|1|1|7" />
        <i3dMapping id="reverseLight_static" node="0>0|1|1|8" />
        <i3dMapping id="reverseLightGlass_static" node="0>0|1|1|9" />
        <i3dMapping id="backLightsHigh1" node="0>0|1|2|0" />
        <i3dMapping id="workLightBackHigh1" node="0>0|1|3|0" />
        <i3dMapping id="workLightBackHigh2" node="0>0|1|3|1" />
        <i3dMapping id="turnLightLeftBack" node="0>0|1|4|0" />
        <i3dMapping id="turnLightRightBack" node="0>0|1|4|1" />
        <i3dMapping id="reverseLightHigh" node="0>0|1|5|0" />
        <i3dMapping id="attacherJoint" node="0>0|2|0" />
        <i3dMapping id="electric" node="0>0|2|1" />
        <i3dMapping id="electric_detached" node="0>0|2|1|0" />
        <i3dMapping id="electric_connector" node="0>0|2|1|0|0" />
        <i3dMapping id="supportArm" node="0>0|2|2" />
        <i3dMapping id="supportArmPart" node="0>0|2|2|0" />
        <i3dMapping id="supportCrankPart" node="0>0|2|3" />
        <i3dMapping id="supportCrank" node="0>0|2|4|0" />
        <i3dMapping id="backDoor" node="0>0|3|0" />
        <i3dMapping id="backDoorPartRef" node="0>0|3|0|2" />
        <i3dMapping id="licensePlateBack" node="0>0|3|0|3" />
        <i3dMapping id="plateNumberLight02" node="0>0|3|0|4" />
        <i3dMapping id="licensePlateLightHigh" node="0>0|3|0|5" />
        <i3dMapping id="arm01" node="0>0|3|1" />
        <i3dMapping id="arm01Part" node="0>0|3|1|0" />
        <i3dMapping id="arm02" node="0>0|3|2" />
        <i3dMapping id="arm02Part" node="0>0|3|2|0" />
        <i3dMapping id="door01" node="0>0|3|3" />
        <i3dMapping id="door01Lock" node="0>0|3|3|4" />
        <i3dMapping id="door02" node="0>0|3|4" />
        <i3dMapping id="door02Lock" node="0>0|3|4|4" />
        <i3dMapping id="backDoorPart" node="0>0|3|5" />
        <i3dMapping id="horseSlots" node="0>0|4" />
        <i3dMapping id="horse1" node="0>0|4|0" />
        <i3dMapping id="horse2" node="0>0|4|1" />
        <i3dMapping id="loadTrigger" node="0>0|4|2" />
        <i3dMapping id="spawnPlace1" node="0>0|4|3|0" />
        <i3dMapping id="spawnPlace2" node="0>0|4|3|1" />
        <i3dMapping id="spawnPlace3" node="0>0|4|3|2" />
        <i3dMapping id="backdoorJoint" node="0>0|5" />
        <i3dMapping id="backDoorRef" node="1>0" />
    </i3dMappings>
</vehicle>
