module Base
{
	model Vehicles_ModernCar02_Wrecked
	{
		mesh = vehicles/Vehicles_Modern02_Wrecked,
		shader = vehicle_multiuv,
		invertX = FALSE,
		scale = 0.008,
	}
	vehicle ModernCar02_Wrecked
	{
		specialKeyRing = KeyRing_WestMaple,

		model
		{
			file = Vehicles_ModernCar02_Wrecked,
			scale = 1.8200,
			offset = 0.0000 0.2692 0.0000,
		}

		extents = 0.8901 0.6374 2.3407,
		physicsChassisShape = 0.8901 0.6374 2.3407,
		centerOfMassOffset = 0.0000 0.3077 0.0000,
		shadowExtents = 0.8901 1.9066,
		shadowOffset = 0.0000 -0.2048,
		template = CarModern02Collision,

		physics box
		{
			offset = 0.0000 0.1636 0.0055,
			extents = 0.8571 0.3516 2.2967,
			rotate = 0.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.3791 0.3211,
			extents = 0.7692 0.1758 0.5165,
			rotate = 36.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.4072 -0.6264,
			extents = 0.7692 0.3956 0.1758,
			rotate = 48.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.4707 -0.1868,
			extents = 0.7692 0.2637 0.6923,
			rotate = 0.0000 0.0000 0.0000,
		}

		mechanicType = 3,
		engineRepairLevel = 6,
		playerDamageProtection = 1.1,
		engineRPMType = firebird,
		spawnOffsetY = 0.5,

		skin
		{
			texture = Vehicles/vehicle_moderncar2shell,
		}

		textureMask = Vehicles/vehicle_carmodern2_mask,
		textureLights = Vehicles/vehicle_carmodern2_lights,
		textureDamage1Overlay = Vehicles/Veh_Blood_Mask,
		textureDamage2Overlay = Vehicles/Veh_Blood_Hvy,
		textureDamage1Shell = Vehicles/Veh_Damage1,
		textureDamage2Shell = Vehicles/Veh_Damage2,
		textureRust = Vehicles/Veh_Rust,

		sound
		{
			engine = VehicleEngineModernCar02,
			engineStart = VehicleEngineModernCar02,
			engineTurnOff = VehicleEngineModernCar02,
			horn = VehicleHornStandard,
			ignitionFail = VehicleIgnitionFailModernCar02,
		}

		extents = 0.8901 0.6374 2.3407,
		mass = 800,
		physicsChassisShape = 0.8901 0.6374 2.3407,
		centerOfMassOffset = 0.0000 0.3077 0.0000,
		engineForce = 5000,
		maxSpeed = 90f,
		engineLoudness = 80,
		engineQuality = 70,
		brakingForce = 90,
		stoppingMovementForce = 4.0f,
		rollInfluence = 1.0f,
		steeringIncrement = 0.04,
		steeringClamp = 0.3,
		suspensionStiffness = 40,
		suspensionCompression = 3.83,
		suspensionDamping = 2.88,
		maxSuspensionTravelCm = 10,
		suspensionRestLength = 0.2,
		wheelFriction = 1.4f,
		frontEndHealth = 150,
		rearEndHealth = 150,
		seats = 4,

		wheel FrontLeft
		{
			front = true,
			offset = 0.2527 -0.1593 0.2967,
			radius = 0.15f,
			width = 0.2f,
		}

		wheel FrontRight
		{
			front = true,
			offset = -0.3626 -0.3022 0.6209,
			radius = 0.15f,
			width = 0.2f,
		}

		wheel RearLeft
		{
			front = false,
			offset = 0.3626 -0.3022 -0.6154,
			radius = 0.15f,
			width = 0.2f,
		}

		wheel RearRight
		{
			front = false,
			offset = -0.3626 -0.3022 -0.6154,
			radius = 0.15f,
			width = 0.2f,
		}

		area Engine
		{
			xywh = 0.0000 1.1429 0.8791 0.4725,
		}

		area TruckBed
		{
			xywh = 0.0000 -1.4066 0.8791 0.4725,
		}

		area GasTank
		{
			xywh = 0.6758 -0.6099 0.4725 0.4725,
		}

		area TireFrontLeft
		{
			xywh = 0.6758 0.4231 0.4725 0.4725,
		}

		area TireFrontRight
		{
			xywh = -0.6758 0.6099 0.4725 0.4725,
		}

		area TireRearLeft
		{
			xywh = 0.6758 -0.6099 0.4725 0.4725,
		}

		area TireRearRight
		{
			xywh = -0.6758 -0.6099 0.4725 0.4725,
		}

		template = TrunkDoor,

		part TrunkDoor
		{
			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = Trunk/part/TruckBed,

		part TruckBed
		{
			container
			{
				capacity = 45,
			}
		}

		template = Seat/part/SeatFrontLeft,
		template = Seat/part/SeatFrontRight,
		template = Seat/part/SeatRearLeft,
		template = Seat/part/SeatRearRight,

		part Seat*
		{
			table install
			{
				skills = Mechanics:2,
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				skills = Mechanics:2,
				recipes = Advanced Mechanics,
			}
		}

		part GloveBox
		{
			area = SeatFrontRight,
			itemType = Base.GloveBox,
			mechanicRequireKey = true,
			durability = 3,
			container
			{
				test = Vehicles.ContainerAccess.GloveBox,
			}
			lua
			{
				create = CrashedCars.CreatVehicle,
			}
		}
		template = GasTank,

		part GasTank
		{
			install
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}

			uninstall
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}
		}

		template = CrashedBattery,
		template = Engine,
		template = Muffler,

		part Muffler
		{
			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = EngineDoor,

		part EngineDoor
		{
			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = Heater,

		part Heater
		{
			category = engine,

			lua
			{
				update = Vehicles.Update.Heater,
			}
		}

		part PassengerCompartment
		{
			category = nodisplay,

			lua
			{
				update = Vehicles.Update.PassengerCompartment,
			}
		}

		template = Windshield/part/Windshield,
		template = Windshield/part/WindshieldRear,

		part Windshield*
		{
			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = Window/part/WindowFrontLeft,
		template = Window/part/WindowFrontRight,
		template = Window/part/WindowRearLeft,
		template = Window/part/WindowRearRight,

		part Window*
		{
			anim Open
			{
				sound = VehicleWindowElectricOpen,
			}

			anim Close
			{
				sound = VehicleWindowElectricClose,
			}

			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = Door/part/DoorFrontLeft,
		template = Door/part/DoorFrontRight,
		template = Door/part/DoorRearLeft,
		template = Door/part/DoorRearRight,

		part Door*
		{
			table install
			{
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		template = Tire,
		template = Brake,

		part Brake*
		{
			table install
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}
		}

		template = Suspension,

		part Suspension*
		{
			table install
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}

			table uninstall
			{
				skills = Mechanics:7,
				recipes = Advanced Mechanics,
			}
		}

		template = Radio,
		template = Headlight,
		
		part Headlight*
		{
			lua
			{
				create = CrashedCars.CreatVehicle,
			}
		}
		
		template = CarModern02Collision,

		attachment trailer
		{
			offset = 0.0000 -0.2747 -1.1813,
			rotate = 0.0000 0.0000 0.0000,
			zoffset = -1.0000,
		}

		attachment trailerfront
		{
			offset = 0.0000 -0.2747 1.1978,
			rotate = 0.0000 0.0000 0.0000,
			zoffset = 1.0000,
		}
	}
}
