module Rotators
{
	vehicle SemiTrailerCistern
	{
		mechanicType = 2,
		offRoadEfficiency = 2,
		engineRepairLevel = 4,
		playerDamageProtection = 1,

		model
		{
			file = Rotators.TrailerCisternBase,
			scale = 1.1500,
			offset = 0.0000 0.7826 -2.0435,
		}

		skin
		{
			texture = Vehicles/Trailers_rCistern_White,
		}

		extents = 1.7565 1.2348 5.5826,
		physicsChassisShape = 1.7739 1.2348 5.5826,
		centerOfMassOffset = 0.0000 0.2087 -0.9826,
		shadowExtents = 1.8266 8.1865,
		shadowOffset = 0.0000 0.2890,
		mass = 400,
		textureRust = Vehicles/Trailers_rCistern_Rust,
		textureMask = Vehicles/Trailers_rCistern_Mask,
		textureLights = Vehicles/Trailers_rCistern_Lights,
		textureDamage1Overlay = Vehicles/Trailers_rCistern_Overlay_Damaged01,
		textureDamage2Overlay = Vehicles/Trailers_rCistern_Overlay_Damaged02,
		textureDamage1Shell = Vehicles/Trailers_rCistern_Shell_Damaged01,
		textureDamage2Shell = Vehicles/Trailers_rCistern_Shell_Damaged02,
		brakingForce = 1,
		stoppingMovementForce = 1.0f,
		rollInfluence = 0.15f,
		steeringIncrement = 0.03,
		steeringClamp = 0.3,
		suspensionStiffness = 40,
		suspensionCompression = 4.83,
		suspensionDamping = 3.88,
		maxSuspensionTravelCm = 15,
		suspensionRestLength = 0.16f,
		wheelFriction = 2.0f,
		frontEndHealth = 150,
		rearEndHealth = 150,
		seats = 2,
		isSmallVehicle = false,

		wheel FrontLeft
		{
			front = true,
			offset = -0.6000 -0.8870 0.2609,
			radius = 0.40f,
			width = 0.90f,
		}

		wheel FrontRight
		{
			front = true,
			offset = 0.6087 -0.8870 0.2609,
			radius = 0.40f,
			width = 0.90f,
		}

		wheel RearLeft
		{
			front = false,
			offset = -0.6000 -0.8870 -0.7217,
			radius = 0.40f,
			width = 0.90f,
		}

		wheel RearRight
		{
			front = false,
			offset = 0.6087 -0.8870 -0.7217,
			radius = 0.40f,
			width = 0.90f,
		}

		area TruckBed
		{
			xywh = -1.1565 -0.4435 0.6087 1.1130,
		}

		area TireFrontLeft
		{
			xywh = 1.2261 -1.8000 0.4522 0.4870,
		}

		area TireFrontRight
		{
			xywh = -1.2261 -1.8000 0.4522 0.4870,
		}

		area TireRearLeft
		{
			xywh = 1.2261 -2.7826 0.4522 0.4870,
		}

		area TireRearRight
		{
			xywh = -1.2261 -2.7826 0.4522 0.4870,
		}

		template = Rotators.DoubleTires,

		part TireFrontLeft
		{
			model InflatedTirePlusWheel
			{
				file = Rotators.TrailerVanFrontWheelLeft,
			}
		}

		part TireFrontRight
		{
			model InflatedTirePlusWheel
			{
				file = Rotators.TrailerVanFrontWheelRight,
			}
		}

		part TireRearLeft
		{
			model InflatedTirePlusWheel
			{
				file = Rotators.TrailerVanRearWheelLeft,
			}
		}

		part TireRearRight
		{
			model InflatedTirePlusWheel
			{
				file = Rotators.TrailerVanRearWheelRight,
			}
		}

		template = Battery,

		part Battery
		{
			category = nodisplay,

			lua
			{
				create = Vehicles.Create.Battery,
				update = Vehicles.Update.Battery,
			}
		}

		template = Headlight/part/HeadlightRearLeft,
		template = Headlight/part/HeadlightRearRight,
		template = Suspension/part/SuspensionFrontLeft,
		template = Suspension/part/SuspensionFrontRight,
		template = Suspension/part/SuspensionRearLeft,
		template = Suspension/part/SuspensionRearRight,
		template = Trunk/part/TruckBed,

		part TruckBed
		{
			itemType = Base.BigTrunk,

			container
			{
				conditionAffectsCapacity = false,
				capacity = 20,
			}
		}

		template = TrunkDoor,

		part TrunkDoor
		{
			model TrunkDoor
			{
				file = Rotators.TrailerCisternTrunk,
				rotate = 90 0 0,
				scale = 1,
				offset = 0 0 0,
			}

			anim Close
			{
				anim = Toolbox_closing,
				rate = 2.2,
			}

			anim Open
			{
				anim = Toolbox_closing,
				reverse = TRUE,
				rate = 2.0,
			}

			anim Closed
			{
				anim = Toolbox_closing,
				reverse = TRUE,
				animate = FALSE,
			}

			anim Opened
			{
				anim = Toolbox_closing,
				animate = FALSE,
			}

			mechanicRequireKey = false,

			anim ActorOpen
			{
				anim = WindowOpenSuccess,
				rate = 0.15,
				angle = 0.0 90.0 0.0,
			}

			anim ActorClose
			{
				anim = Attack_Shove,
				rate = 0.3,
				angle = 0.0 90.0 0.0,
			}
		}

		area GasTank
		{
			xywh = -1.2348 0.4783 1.0087 3.1478,
		}

		template = TruckTank/part/1000FuelTank,

		physics box
		{
			offset = 0.0000 1.1584 0.2772,
			extents = 1.7822 1.2277 8.1386,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.8317 4.7327,
			extents = 0.1111 0.1111 0.5889,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 1.1913 -3.3478,
			extents = 0.1130 2.4609 0.9043,
			rotate = 0.0000 0.0000 0.0000,
		}

		attachment trailerTruck
		{
			offset = 0.0000 -0.4174 5.6522,
			rotate = 0.0000 0.0000 0.0000,
			canAttach = trailerTruck,
		}
	}
}
