module Base
{
	model Vehicles_ModernCar_Wrecked
	{
		mesh = vehicles/Vehicles_Modern_Wrecked,
		shader = vehicle_multiuv,
		static = TRUE,
		invertX = FALSE,
		scale = 0.008,
	}
	vehicle ModernCar_Wrecked
	{
		model
		{
			file = Vehicles_ModernCar_Wrecked,
			scale = 1.8200,
			offset = 0.0000 0.1978 0.0000,
		}

		extents = 0.9231 0.6374 2.3077,
		physicsChassisShape = 0.9231 0.6374 2.3077,
		centerOfMassOffset = 0.0000 0.1978 0.0000,
		shadowExtents = 0.9231 2.3077,
		shadowOffset = 0.0000 0.0000,
		template = CarModernCollision,
		mechanicType = 3,
		engineRepairLevel = 6,
		playerDamageProtection = 1.1,
		engineRPMType = firebird,
		spawnOffsetY = 0.5,

		skin
		{
			texture = Vehicles/vehicle_moderncarshell,
		}

		textureMask = Vehicles/vehicle_carmodern_mask,
		textureLights = Vehicles/vehicle_carmodern_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 = VehicleEngineModernCar,
			engineStart = VehicleEngineModernCar,
			engineTurnOff = VehicleEngineModernCar,
			horn = VehicleHornStandard,
			ignitionFail = VehicleIgnitionFailModernCar,
		}

		extents = 0.9231 0.6374 2.3077,
		mass = 800,
		physicsChassisShape = 0.9231 0.6374 2.3077,
		centerOfMassOffset = 0.0000 0.1978 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.3626 -0.3022 0.6100,
			radius = 0.15f,
			width = 0.2f,
		}

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

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

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

		area Engine
		{
			xywh = 0.0000 1.3901 0.9231 0.4725,
		}

		area TruckBed
		{
			xywh = 0.0000 -1.3901 0.9231 0.4725,
		}

		area GasTank
		{
			xywh = 0.6978 -0.6264 0.4725 0.4725,
		}

		area TireFrontLeft
		{
			xywh = 0.6978 0.7198 0.4725 0.4725,
		}

		area TireFrontRight
		{
			xywh = -0.6978 0.7198 0.4725 0.4725,
		}

		area TireRearLeft
		{
			xywh = 0.6978 -0.6264 0.4725 0.4725,
		}

		area TireRearRight
		{
			xywh = -0.6978 -0.6264 0.4725 0.4725,
		}

		template = TrunkDoor,

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

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

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

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

			table uninstall
			{
				recipes = Advanced Mechanics,
			}
		}

		part GloveBox
		{
			area = SeatFrontRight,
			itemType = Base.GloveBox,
			mechanicRequireKey = true,
			durability = 3,
			container
			{
				test = Vehicles.ContainerAccess.GloveBox,
			}
		}

		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 = CarModernCollision,

		physics box
		{
			offset = 0.0000 0.0934 0.0055,
			extents = 0.8901 0.3297 2.2308,
			rotate = 2.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.2885 0.3846,
			extents = 0.8022 0.1758 0.5495,
			rotate = 30.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.2955 -0.7033,
			extents = 0.8022 0.5385 0.2198,
			rotate = 63.0000 0.0000 0.0000,
		}

		physics box
		{
			offset = 0.0000 0.3776 -0.1648,
			extents = 0.8022 0.2747 0.7033,
			rotate = 2.0000 0.0000 0.0000,
		}

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

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