package Vehicle
using RTDB, BaseStats, Driving, Camera

v_sport1_herrera_riptide : Vehicle_4w_Default
{
	entityTemplatePath = "ep1\vehicles\sport\v_sport1_herrera_riptide_01.ent";
	visualTags = 
	[
		"Premium"
	];
	tags += 
	[
		"Sport"
	];
	manufacturer = "Vehicle.Herrera";
	randomPassengers = 
	[
		"Passengers.CitizenRichDriverEntry", "Passengers.CitizenRichPassengerFrontEntry"
	];
	displayName = "LocKey#94003";
	vehicleUIData = "Vehicle.VehicleHerreraRiptideUIData";
	destroyedAppearance = "herrera_riptide__basic_burnt_01";
	fxWheelsDecalsFrontOverride = "Vehicle.FxWheels_Sport_M";
	fxWheelsDecals = "Vehicle.FxWheels_Sport_L";
	destruction = "Vehicle.VehicleDestructionParamsRiptide";
	player_audio_resource = "v_car_herrera_riptide";
	traffic_audio_resource = "v_car_herrera_riptide_traffic";
	vehDataPackage = 
	{
		useAuxiliary = true;
		vehSeatSet = "Vehicle.Vehicle2SeatSetDefault";
		driverCombat = "DriverCombatTypes.Standard";
		entering = 2.4f;
		slideDuration = 0.8f;
		open_close_duration = 1.2f;
		normal_open = 1.7f;
		stealing_open = 4.0f;
		exitDelay = 0.3f;
	} : VehicleDataPackageSport1;
	vehWheelDimensionsSetup = 
	{
		frontPreset = 
		{
			tireRadius = 0.355f;
			rimRadius = 0.275f;
			tireWidth = 0.31f;
			wheelOffset = 0.01f;
		} : VehicleWheelDimensionsPreset;
		backPreset = 
		{
			tireRadius = 0.39f;
			rimRadius = 0.305f;
			tireWidth = 0.39f;
			wheelOffset = 0.01f;
		} : VehicleWheelDimensionsPreset;
	} : VehicleWheelDimensionsSetup;
	vehDriveModelData = "Vehicle.VehicleDriveModelData_Riptide";
	vehEngineData = 
	{
		engineMaxTorque = 740.f;
		finalGearTorqueDecimationScalor = 0.89f;
	} : VehicleEngineData_4_Muscle;
	tppCameraPresets = 
	[
		"Camera.VehicleTPP_4w_herrera_riptide_High_Close", "Camera.VehicleTPP_4w_herrera_riptide_High_Medium", "Camera.VehicleTPP_4w_herrera_riptide_High_Far", "Camera.VehicleTPP_4w_herrera_riptide_High_DriverCombatClose", "Camera.VehicleTPP_4w_herrera_riptide_High_DriverCombatMedium", "Camera.VehicleTPP_4w_herrera_riptide_High_DriverCombatFar", "Camera.VehicleTPP_4w_herrera_riptide_Low_Close", "Camera.VehicleTPP_4w_herrera_riptide_Low_Medium", "Camera.VehicleTPP_4w_herrera_riptide_Low_Far", "Camera.VehicleTPP_4w_herrera_riptide_Low_DriverCombatClose", "Camera.VehicleTPP_4w_herrera_riptide_Low_DriverCombatMedium", "Camera.VehicleTPP_4w_herrera_riptide_Low_DriverCombatFar"
	];
	vehDriver_FPPCameraParams = 
	{
		enable_rear_view = true;
		lookat_offset_vertical = -0.02f;
		is_forward_offset = 1.0f;
		forward_offset_value = 0.08f;
		rear_view_offset = ( 0.0000, -1.0086, 0.8431 );
	} : VehicleDriverFPPCameraParamsDefault;
	vehDriverCombat_FPPCameraParams = 
	{
		lookat_yaw_left_offset = 0.4f;
		lookat_yaw_left_up_offset = 0.1f;
		lookat_yaw_right_offset = 0.25f;
		lookat_yaw_right_up_offset = 0.07f;
		lookat_offset_vertical = -0.02f;
		is_forward_offset = 1.0f;
		forward_offset_value = 0.08f;
	} : VehicleDriverCombatFPPCameraParamsDefault;
	vehAirControl = 
	{
		flippedOverRecoveryPID = 
		[
			-220.f, 0.f, 0.f
		];
	} : VehicleAirControlCar;
	trafficSuspension = "Vehicle.TrafficSuspension_Sport";
}

VehicleWheelDrivingPreset_Riptide_Front : VehicleWheelDrivingPreset_TurboR_Front
{
	maxBrakingTorque = 520.0f;
	frictionMulLongitudinal = 0.93f;
	frictionMulLateral = 0.937f;
	tireLateralSlipEffectsMul = 0.71f;
	swaybarStiffness = 11.0f;
	swaybarLengthScalar = 1.0f;
	springStiffness = 17.0f;
	springDamping = 2900.0f;
	springReboundDamping = 2900.0f;
	springBoundDampingLowRate = 1800.0f;
	springReboundDampingLowRate = 1800.0f;
	springDampingLowRateCompression = 0.18f;
	springDampingHighRateCompression = 0.36f;
	extremeCompressionEventScalor = 0.67f;
	logicalSuspensionCompressionLength = 0.35f;
	visualSuspensionDroop = 0.08f;
	visualSuspensionCompressionLength = 0.08f;
	wheelsVerticalOffset = 0.02f;
}

VehicleWheelDrivingPreset_Riptide_Rear : VehicleWheelDrivingPreset_TurboR_Rear
{
	maxBrakingTorque = 860.0f;
	frictionMulLongitudinal = 0.965f;
	frictionMulLateral = 0.94f;
	swaybarStiffness = 16.0f;
	swaybarLengthScalar = 1.0f;
	springStiffness = 21.0f;
	springDamping = 3600.0f;
	springReboundDamping = 3400.0f;
	springBoundDampingLowRate = 2300.0f;
	springReboundDampingLowRate = 2100.0f;
	springDampingLowRateCompression = 0.20f;
	springDampingHighRateCompression = 0.40f;
	extremeCompressionEventScalor = 0.6f;
	logicalSuspensionCompressionLength = 0.35f;
	visualSuspensionDroop = 0.09f;
	visualSuspensionCompressionLength = 0.12f;
	wheelsVerticalOffset = 0.01f;
}

VehicleDriveModelData_Riptide : VehicleDriveModelData_TurboR_VTech
{
	center_of_mass_offset = ( 0.0f, -0.18f, 0.11f );
	momentOfInertia = ( 1905.0f, 520.0f, 2235.0f );
	chassis_mass = 1510.0f;
	total_mass = 1510.0f;
	airResistanceFactor = 2.25f;
	turnUpdateMidSpeedThreshold = 30.f;
	turnUpdateMaxSpeedThreshold = 44.f;
	turnUpdateMidSpeedTurnMul = 0.5f;
	turnUpdateMidSpeedTurnChangeMul = 2.5f;
	turnUpdateMaxSpeedTurnMul = 0.33f;
	turnUpdateMaxSpeedTurnChangeMul = 1.92f;
	handbrakeBrakingTorque = 1400.0f;
	wheelSetup = 
	{
		frontPreset = "Vehicle.VehicleWheelDrivingPreset_Riptide_Front";
		backPreset = "Vehicle.VehicleWheelDrivingPreset_Riptide_Rear";
	} : VehicleWheelDrivingSetup_4_RWD;
	burnOut = 
	{
		maxDriveWheelSlipRatio = 26.0f;
		lateralAccelForwardSpeedMaxDecimation = 0.63f;
		maxLongFrictionSlipRatioMultipler = 0.75f;
		maxLateralAccelSlipRatioMultipler = 0.71f;
		minLongFrictionCoeff = 0.69f;
		maxBrakeForceModifier = 0.95f;
		gripBonusMaxLaunchSpeed = 8.0f;
	} : VehicleBurnOut_TurboR_VTech;
}

v_sport1_herrera_riptide_terrier : v_sport1_herrera_riptide
{
	displayName = "LocKey#93143";
	appearanceName = "herrera_riptide__basic_player_01";
	vehicleUIData = 
	{
		mass = 1432.0f;
		info = "LocKey#94005";
	} : VehicleHerreraRiptideUIData;
	vehDriveModelData = 
	{
		airResistanceFactor = 2.1f;
	} : VehicleDriveModelData_Riptide;
	vehEngineData = 
	{
		engineMaxTorque = 740.f;
	} : VehicleEngineData_4_Muscle;
}

v_sport1_herrera_riptide_premium : v_sport1_herrera_riptide
{
	visualTags = 
	[
		"Premium"
	];
	randomPassengers = 
	[
		"Passengers.CorporatDriverEntry", "Passengers.CorporatPassengerFrontEntry"
	];
}

VehicleDestructionParamsRiptide : VehicleDestructionParamsDefault_4w
{
	gridDimensions = ( 1.9f, 4.5f, 0.4f );
	gridLocalOffset = ( 0.0f, -0.1f, 0.35f );
	chargePortCenter = ( -0.722114563f, 1.72659588f, 0.330415964f );
	pointDampers = 
	[
		{
			pointIndex = 0;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 1;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 2;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 3;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 5;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 6;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 8;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 9;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 11;
			dampValue = 0.80;
			pointFragility = 2.00;
		}, 
		{
			pointIndex = 12;
			dampValue = 0.80;
			pointFragility = 1.00;
		}, 
		{
			pointIndex = 13;
			dampValue = 0.80;
			pointFragility = 1.00;
		}, 
		{
			pointIndex = 14;
			dampValue = 0.80;
			pointFragility = 1.00;
		}
	];
	glass = 
	[
		{
			component = "window_f_a_01";
			effect = "damage_windshield";
			isWindshield = true;
			gridCells = 
			[
				6, 7
			];
			threshold = 0.15;
		}, 
		{
			component = "window_fl_a";
			effect = "damage_glass_fl_a";
			gridCells = 
			[
				4, 12
			];
			threshold = 0.1;
		}, 
		{
			component = "window_fl_b_01";
			effect = "damage_glass_fl_b_01";
			gridCells = 
			[
				4
			];
			threshold = 0.1;
		}, 
		{
			component = "window_fl_c";
			effect = "damage_glass_fl_c";
			gridCells = 
			[
				4, 12
			];
			threshold = 0.1;
		}, 
		{
			component = "window_fr_a";
			effect = "damage_glass_fr_a";
			gridCells = 
			[
				5, 13
			];
			threshold = 0.1;
		}, 
		{
			component = "window_fr_b_01";
			effect = "damage_glass_fr_b_01";
			gridCells = 
			[
				5
			];
			threshold = 0.1;
		}, 
		{
			component = "window_fr_c";
			effect = "damage_glass_fr_c";
			gridCells = 
			[
				5, 13
			];
			threshold = 0.1;
		}, 
		{
			component = "window_b_01";
			effect = "damage_glass_b_01";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.1;
		}, 
		{
			component = "body_glass_l_01";
			effect = "damage_glass_b_01";
			gridCells = 
			[
				0
			];
			threshold = 0.1;
		}, 
		{
			component = "body_glass_r_01";
			effect = "damage_glass_b_01";
			gridCells = 
			[
				1
			];
			threshold = 0.1;
		}
	];
	detachableParts = 
	[
		{
			name = "Trunk";
			gridCells = 
			[
				6, 7
			];
			threshold = 0.7;
			components = 
			[
				"trunk_a", "trunk_a_shadow"
			];
		}, 
		{
			name = "Trunk_b";
			gridCells = 
			[
				6, 7
			];
			threshold = 0.7;
			components = 
			[
				"trunk_b_01", "trunk_b_01_shadow"
			];
		}, 
		{
			name = "Hood";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.7;
			components = 
			[
				"hood_a", "window_b_01", "hood_a_shadow"
			];
		}, 
		{
			name = "BumperFront";
			gridCells = 
			[
				6, 7
			];
			threshold = 0.6;
			components = 
			[
				"bumper_f_01", "bumper_f_shadow"
			];
		}, 
		{
			name = "License_plate_f";
			gridCells = 
			[
				6, 7
			];
			threshold = 0.07;
			components = 
			[
				"license_plate_f"
			];
		}, 
		{
			name = "BumperBack";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.6;
			components = 
			[
				"bumper_b_01", "bumper_b_shadow"
			];
		}, 
		{
			name = "WingLeft";
			gridCells = 
			[
				0
			];
			threshold = 0.35;
			components = 
			[
				"body_wing_l_01"
			];
		}, 
		{
			name = "WingRight";
			gridCells = 
			[
				1
			];
			threshold = 0.35;
			components = 
			[
				"body_wing_r_01"
			];
		}, 
		{
			name = "License_plate_b";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.07;
			components = 
			[
				"license_plate_b"
			];
		}, 
		{
			name = "MirrorLeft_01";
			gridCells = 
			[
				4
			];
			threshold = 0.1;
			components = 
			[
				"mirror_fl_01"
			];
		}, 
		{
			name = "MirrorRight_01";
			gridCells = 
			[
				5
			];
			threshold = 0.1;
			components = 
			[
				"mirror_fl"
			];
		}, 
		{
			name = "DoorFrontLeft_A";
			gridCells = 
			[
				2
			];
			threshold = 0.8;
			components = 
			[
				"door_fl_a", "door_fl_a_shadow"
			];
		}, 
		{
			name = "DoorFrontLeft_B";
			gridCells = 
			[
				2, 4
			];
			threshold = 0.7;
			components = 
			[
				"door_fl_b", "door_fl_b_shadow", "door_fl_c", "door_fl_c_shadow"
			];
		}, 
		{
			name = "DoorFrontLeft_C";
			gridCells = 
			[
				2, 4
			];
			threshold = 0.6;
			components = 
			[
				"door_fl_c", "door_fl_c_shadow"
			];
		}, 
		{
			name = "DoorFrontRight_A";
			gridCells = 
			[
				3
			];
			threshold = 0.8;
			components = 
			[
				"door_fr_a", "door_fr_a_shadow"
			];
		}, 
		{
			name = "DoorFrontRight_B";
			gridCells = 
			[
				3, 5
			];
			threshold = 0.7;
			components = 
			[
				"door_fr_b", "door_fr_b_shadow", "door_fr_c", "door_fr_c_shadow"
			];
		}, 
		{
			name = "DoorFrontRight_C";
			gridCells = 
			[
				3, 5
			];
			threshold = 0.6;
			components = 
			[
				"door_fr_c", "door_fr_c_shadow"
			];
		}
	];
	deformableParts = 
	[
		{
			component = "hood_a";
			zones = 
			[
				{
					shapes = 
					[
						0, 1, 2, 4, 8, 9, 10, 11, 12, 13, 14
					];
					gridCells = 
					[
						0, 1, 8, 9
					];
				}
			];
		}, 
		{
			component = "trunk_a";
			zones = 
			[
				{
					shapes = 
					[
						1, 2, 3, 4, 5, 6, 7, 8
					];
					gridCells = 
					[
						6, 7, 14, 15
					];
				}
			];
		}, 
		{
			component = "bumper_b_01";
			zones = 
			[
				{
					shapes = 
					[
						0, 1, 2, 3
					];
					gridCells = 
					[
						0, 1, 8, 9
					];
				}
			];
		}, 
		{
			component = "bumper_f_01";
			zones = 
			[
				{
					shapes = 
					[
						0, 1, 2
					];
					gridCells = 
					[
						6, 7, 14, 15
					];
				}
			];
		}, 
		{
			component = "body_01";
			zones = 
			[
				{
					shapes = 
					[
						23, 24, 25, 26, 27, 32
					];
					gridCells = 
					[
						6, 7, 14, 15
					];
				}, 
				{
					shapes = 
					[
						8, 12, 19, 33, 39
					];
					gridCells = 
					[
						0, 1, 8, 9
					];
				}
			];
		}
	];
	wheels = 
	[
		{
			name = "FrontLeft";
			intact = "tire_fl_a_01";
		}, 
		{
			name = "FrontRight";
			intact = "tire_fr_a_01";
		}, 
		{
			name = "BackRight";
			intact = "tire_br_a_01";
			hitsToFlatten = 2;
		}, 
		{
			name = "BackLeft";
			intact = "tire_bl_a_01";
			hitsToFlatten = 2;
		}
	];
	lights = 
	[
		{
			component = "head_light_left_01";
			gridCells = 
			[
				6
			];
			threshold = 0.1f;
		}, 
		{
			component = "head_light_right_01";
			gridCells = 
			[
				7
			];
			threshold = 0.1f;
		}, 
		{
			component = "break_light";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.2f;
		}, 
		{
			component = "head_light";
			gridCells = 
			[
				6, 7
			];
			threshold = 0.2f;
		}, 
		{
			component = "break_light_right_01";
			gridCells = 
			[
				1
			];
			threshold = 0.1f;
		}, 
		{
			component = "break_light_right_02";
			gridCells = 
			[
				1
			];
			threshold = 0.1f;
		}, 
		{
			component = "brake_light_left_01";
			gridCells = 
			[
				0
			];
			threshold = 0.1f;
		}, 
		{
			component = "brake_light_left_02";
			gridCells = 
			[
				0
			];
			threshold = 0.1f;
		}, 
		{
			component = "buttons_light_lf_01";
			gridCells = 
			[
				0, 1
			];
			threshold = 0.1f;
		}, 
		{
			component = "reverse_light";
			gridCells = 
			[
				1
			];
			threshold = 0.15f;
		}, 
		{
			component = "position_light_left_01";
			gridCells = 
			[
				6
			];
			threshold = 0.1f;
		}, 
		{
			component = "position_light_left_02";
			gridCells = 
			[
				0
			];
			threshold = 0.1f;
		}, 
		{
			component = "position_light_right_01";
			gridCells = 
			[
				7
			];
			threshold = 0.1f;
		}, 
		{
			component = "position_light_right_02";
			gridCells = 
			[
				1
			];
			threshold = 0.1f;
		}
	];
}

VehicleHerreraRiptideUIData : VehicleDefaultUIData
{
	productionYear = "2077";
	driveLayout = "LocKey#45371";
	horsepower = 789.0f;
	mass = 1429.0f;
	info = "LocKey#94004";
}

