Jump to content
Sign in to follow this  
JustMathew

Need help understanding model.cfg, wheels not working

Recommended Posts

Hi!

 

I am currently working on a 8-wheeled truck and I'm experiencing some weird bugs when I get it in game. The first version had the 4 front wheels all the way at the top of the damper, whereas the rear 4 wheels were relaxed. You can see the different heights in this picture:

107410_20160815123628_1.png

 

When I was messing around trying to fix this issue, I tried changing the parent-classes in my model.cfg, so my class inherits from "Truck" instead of "Car", as I could suspect "Car" does not support 8 wheels. 

As I did so, the model animations stopped working completely, it now does nothing. 

 

I therefore need some assistance understanding which classes my class can inherit from in model.cfg. How come I can not inherit from "Truck"?

 

I've attached my config.cpp and model.cfg, in case you need to see them.

 

Config.cpp

#include "basicdefines_A3.hpp"
class DefaultEventhandlers;

#include "CfgPatches.hpp"

class WeaponFireGun;
class WeaponCloudsGun;
class WeaponFireMGun;
class WeaponCloudsMGun;

class CfgVehicles
{
	class Car;
	class Car_F: Car
	{
		class HitPoints;
		class Turrets;
	};
	class Truck_F: Car_F
	{
		unitInfoType = "RscUnitInfoNoWeapon";
		class Exhausts
		{
			class Exhaust1
			{
				position = "exhaust1_pos";
				direction = "exhaust1_dir";
				effect = "ExhaustEffectHEMTT";
			};
		};
		class HitPoints: HitPoints
		{
			class HitRGlass;
			class HitLGlass;
			class HitGlass1;
			class HitGlass2;
			class HitGlass3;
			class HitGlass4;
			class HitGlass5;
			class HitBody;
			class HitFuel;
			class HitLFWheel;
			class HitLBWheel;
			class HitLMWheel;
			class HitLF2Wheel;
			class HitRFWheel;
			class HitRBWheel;
			class HitRMWheel;
			class HitRF2Wheel;
			class HitEngine;
		};
		class EventHandlers;
		class AnimationSources;
		class Turrets: Turrets
		{
			class MainTurret;
			class ViewGunner;
		};
	};
	
	
		class Truck_01_base_F: Truck_F
	{
		author = "$STR_A3_Bohemia_Interactive";
		mapSize = 12.02;
		_generalMacro = "Truck_01_base_F";
		class Library
		{
			libTextDesc = "$STR_A3_CfgVehicles_Truck_01_base_Library0";
		};
		editorSubcategory = "EdSubcat_Cars";
		vehicleClass = "Car";
		transportSoldier = 1;
		memoryPointTaskMarker = "TaskMarker_1_pos";
		slingLoadCargoMemoryPoints[] = {"SlingLoadCargo1","SlingLoadCargo2","SlingLoadCargo3","SlingLoadCargo4"};
		armor = 200;
		class HitPoints: HitPoints
		{
			class HitFuel: HitFuel
			{
				armor = 1.0;
				passThrough = 1;
				minimalHit = 0.1;
				explosionShielding = 1.5;
				radius = 0.45;
			};
			class HitEngine: HitEngine
			{
				armor = 0.5;
				passThrough = 1;
				minimalHit = 0.1;
				explosionShielding = 0.5;
				radius = 0.45;
			};
			class HitBody: HitBody
			{
				armor = 1.0;
				passThrough = 1;
				minimalHit = 0.0;
				explosionShielding = 1.5;
				radius = 0.33;
			};
			class HitLFWheel: HitLFWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitLBWheel: HitLBWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitLMWheel: HitLMWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitLF2Wheel: HitLF2Wheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitRFWheel: HitRFWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitRBWheel: HitRBWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitRMWheel: HitRMWheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitRF2Wheel: HitRF2Wheel
			{
				armor = 0.5;
				minimalHit = 0.02;
				passThrough = 0.3;
				explosionShielding = 4;
				radius = 0.33;
			};
			class HitGlass1: HitGlass1
			{
				armor = 1.5;
				passThrough = 0;
				explosionShielding = 3;
				radius = 0.33;
			};
			class HitGlass2: HitGlass2
			{
				armor = 1.5;
				passThrough = 0;
				explosionShielding = 3;
				radius = 0.33;
			};
			class HitGlass3: HitGlass3
			{
				armor = 1.5;
				passThrough = 0;
				explosionShielding = 3;
				radius = 0.33;
			};
			class HitGlass4: HitGlass4
			{
				armor = 1.5;
				passThrough = 0;
				explosionShielding = 3;
				radius = 0.33;
			};
		};
		cost = 50000;
		weapons[] = {"TruckHorn2"};
		driverAction = "driver_hemtt";
		cargoAction[] = {"passenger_generic01_foldhands","passenger_apc_generic02","passenger_apc_generic04","passenger_apc_generic03","passenger_apc_generic01","passenger_apc_narrow_generic01","passenger_generic01_foldhands","passenger_generic01_leanleft","passenger_generic01_leanright","passenger_apc_generic01","passenger_generic01_leanleft","passenger_generic01_foldhands","passenger_apc_generic02","passenger_apc_generic03","passenger_apc_narrow_generic01","passenger_apc_narrow_generic03","passenger_generic01_foldhands"};
		cargoIsCoDriver[] = {1,0};
		cargo[] = {"GetOutMedium","GetOutHighHemtt"};
		getInAction = "GetInMRAP_01";
		getOutAction = "GetOutLow";
		cargoGetInAction[] = {"GetInMRAP_01","GetInHemttBack"};
		hideWeaponsDriver = 1;
		hideWeaponsCargo = 1;
		driverCompartments = "Compartment1";
		cargoCompartments[] = {"Compartment1","Compartment2"};
		destrType = "DestructWreck";
		showNVGCargo[] = {0,1};
		soundAttenuationCargo[] = {1,0};
		attenuationEffectType = "CarAttenuation";
		soundGetIn[] = {"A3\Sounds_F\vehicles\soft\Truck_02\getin",0.56234133,1};
		soundGetOut[] = {"A3\Sounds_F\vehicles\soft\Truck_02\getout",0.56234133,1,20};
		soundDammage[] = {"",0.56234133,1};
		soundEngineOnInt[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_start",0.70794576,1.0};
		soundEngineOnExt[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_start",0.70794576,1.0,200};
		soundEngineOffInt[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_stop",0.70794576,1.0};
		soundEngineOffExt[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_stop",0.70794576,1.0,200};
		buildCrash0[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_1",1.0,1,200};
		buildCrash1[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_2",1.0,1,200};
		buildCrash2[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_3",1.0,1,200};
		buildCrash3[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_4",1.0,1,200};
		soundBuildingCrash[] = {"buildCrash0",0.25,"buildCrash1",0.25,"buildCrash2",0.25,"buildCrash3",0.25};
		WoodCrash0[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_wood_ext_1",1.0,1,200};
		WoodCrash1[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_wood_ext_1",1.0,1,200};
		WoodCrash2[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_wood_ext_1",1.0,1,200};
		WoodCrash3[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_wood_ext_1",1.0,1,200};
		soundWoodCrash[] = {"woodCrash0",0.25,"woodCrash1",0.25,"woodCrash2",0.25,"woodCrash3",0.25};
		armorCrash0[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_1",1.0,1,200};
		armorCrash1[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_2",1.0,1,200};
		armorCrash2[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_3",1.0,1,200};
		armorCrash3[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_4",1.0,1,200};
		soundArmorCrash[] = {"ArmorCrash0",0.25,"ArmorCrash1",0.25,"ArmorCrash2",0.25,"ArmorCrash3",0.25};
		Crash0[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_1",1.0,1,200};
		Crash1[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_2",1.0,1,200};
		Crash2[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_3",1.0,1,200};
		Crash3[] = {"A3\Sounds_F\vehicles\crashes\cars\cars_coll_big_default_ext_4",1.0,1,200};
		soundCrashes[] = {"Crash0",0.25,"Crash1",0.25,"Crash2",0.25,"Crash3",0.25};
		class Sounds
		{
			class Idle_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_00",0.56234133,1,200};
				frequency = "0.95	+	((rpm/	3000) factor[(100/	3000),(800/	3000)])*0.15";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(10/	3000),(50/	3000)])	*	((rpm/	3000) factor[(800/	3000),(600/	3000)]))";
			};
			class Engine
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_01",0.63095737,1,200};
				frequency = "0.8	+	((rpm/	3000) factor[(610/	3000),(1200/	3000)])*0.2";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(620/	3000),(820/	3000)])	*	((rpm/	3000) factor[(1200/	3000),(1000/	3000)]))";
			};
			class Engine1_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_02",0.70794576,1,200};
				frequency = "0.8	+	((rpm/	3000) factor[(1000/	3000),(1500/	3000)])*0.2";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(950/	3000),(1150/	3000)])	*	((rpm/	3000) factor[(1500/	3000),(1300/	3000)]))";
			};
			class Engine2_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_03",0.7943282,1,250};
				frequency = "0.8	+	((rpm/	3000) factor[(1300/	3000),(1850/	3000)])*0.2";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(1260/	3000),(1500/	3000)])	*	((rpm/	3000) factor[(1850/	3000),(1600/	3000)]))";
			};
			class Engine3_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_04",1.1220185,1,300};
				frequency = "0.8	+	((rpm/	3000) factor[(1600/	3000),(2200/	3000)])*0.1";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(1550/	3000),(1800/	3000)])	*	((rpm/	3000) factor[(2200/	3000),(1950/	3000)]))";
			};
			class Engine4_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_05",1.4125376,1,350};
				frequency = "0.8	+	((rpm/	3000) factor[(2000/	3000),(2600/	3000)])*0.1";
				volume = "engineOn*camPos*(((rpm/	3000) factor[(1900/	3000),(2150/	3000)])	*	((rpm/	3000) factor[(2600/	3000),(2300/	3000)]))";
			};
			class Engine5_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_engine_06",1.7782794,1,400};
				frequency = "0.8	+	((rpm/	3000) factor[(2300/	3000),(3000/	3000)])*0.1";
				volume = "engineOn*camPos*((rpm/	3000) factor[(2300/	3000),(2700/	3000)])";
			};
			class IdleThrust
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_00",1.0,1,250};
				frequency = "0.8	+	((rpm/	3000) factor[(100/	3000),(800/	3000)])*0.15";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(10/	3000),(50/	3000)])	*	((rpm/	3000) factor[(800/	3000),(600/	3000)]))";
			};
			class EngineThrust
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_01",1.2589254,1,300};
				frequency = "0.8	+	((rpm/	3000) factor[(610/	3000),(1200/	3000)])*0.2";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(620/	3000),(820/	3000)])	*	((rpm/	3000) factor[(1200/	3000),(1000/	3000)]))";
			};
			class Engine1_Thrust_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_02",1.4125376,1,350};
				frequency = "0.8	+	((rpm/	3000) factor[(1000/	3000),(1500/	3000)])*0.2";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(950/	3000),(1150/	3000)])	*	((rpm/	3000) factor[(1500/	3000),(1300/	3000)]))";
			};
			class Engine2_Thrust_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_03",1.5848932,1,400};
				frequency = "0.8	+	((rpm/	3000) factor[(1300/	3000),(1850/	3000)])*0.2";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1260/	3000),(1500/	3000)])	*	((rpm/	3000) factor[(1850/	3000),(1600/	3000)]))";
			};
			class Engine3_Thrust_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_04",1.9952624,1,450};
				frequency = "0.8	+	((rpm/	3000) factor[(1600/	3000),(2200/	3000)])*0.1";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1550/	3000),(1800/	3000)])	*	((rpm/	3000) factor[(2200/	3000),(1950/	3000)]))";
			};
			class Engine4_Thrust_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_05",1.9952624,1,450};
				frequency = "0.8	+	((rpm/	3000) factor[(2000/	3000),(2600/	3000)])*0.1";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1900/	3000),(2150/	3000)])	*	((rpm/	3000) factor[(2600/	3000),(2300/	3000)]))";
			};
			class Engine5_Thrust_ext
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\ext_exhaust_06",2.2387211,1,500};
				frequency = "0.8	+	((rpm/	3000) factor[(2300/	3000),(3000/	3000)])*0.1";
				volume = "engineOn*camPos*(0.4+(0.6*(thrust factor[0.1,1])))*((rpm/	3000) factor[(2300/	3000),(2700/	3000)])";
			};
			class Idle_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_00",0.39810717,1};
				frequency = "0.8	+	((rpm/	3000) factor[(100/	3000),(800/	3000)])*0.15";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(10/	3000),(50/	3000)])	*	((rpm/	3000) factor[(800/	3000),(600/	3000)]))";
			};
			class Engine_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_01",0.4466836,1};
				frequency = "0.8	+	((rpm/	3000) factor[(610/	3000),(1200/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(620/	3000),(820/	3000)])	*	((rpm/	3000) factor[(1200/	3000),(1000/	3000)]))";
			};
			class Engine1_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_02",0.5011872,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1000/	3000),(1500/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(950/	3000),(1150/	3000)])	*	((rpm/	3000) factor[(1500/	3000),(1300/	3000)]))";
			};
			class Engine2_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_03",0.5011872,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1300/	3000),(1850/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(1260/	3000),(1500/	3000)])	*	((rpm/	3000) factor[(1850/	3000),(1600/	3000)]))";
			};
			class Engine3_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_04",0.56234133,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1600/	3000),(2200/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(1550/	3000),(1800/	3000)])	*	((rpm/	3000) factor[(2200/	3000),(1950/	3000)]))";
			};
			class Engine4_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_05",0.56234133,1};
				frequency = "0.8	+	((rpm/	3000) factor[(2000/	3000),(2600/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*(((rpm/	3000) factor[(1900/	3000),(2150/	3000)])	*	((rpm/	3000) factor[(2600/	3000),(2300/	3000)]))";
			};
			class Engine5_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_engine_06",0.63095737,1};
				frequency = "0.8	+	((rpm/	3000) factor[(2300/	3000),(3000/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*((rpm/	3000) factor[(2300/	3000),(2700/	3000)])";
			};
			class IdleThrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_00",0.5011872,1};
				frequency = "0.8	+	((rpm/	3000) factor[(100/	3000),(800/	3000)])*0.15";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(10/	3000),(50/	3000)])	*	((rpm/	3000) factor[(800/	3000),(600/	3000)]))";
			};
			class EngineThrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_01",0.56234133,1};
				frequency = "0.8	+	((rpm/	3000) factor[(610/	3000),(1200/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(620/	3000),(820/	3000)])	*	((rpm/	3000) factor[(1200/	3000),(1000/	3000)]))";
			};
			class Engine1_Thrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_02",0.63095737,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1000/	3000),(1500/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(950/	3000),(1150/	3000)])	*	((rpm/	3000) factor[(1500/	3000),(1300/	3000)]))";
			};
			class Engine2_Thrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_03",0.63095737,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1300/	3000),(1850/	3000)])*0.2";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1260/	3000),(1500/	3000)])	*	((rpm/	3000) factor[(1850/	3000),(1600/	3000)]))";
			};
			class Engine3_Thrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_04",0.70794576,1};
				frequency = "0.8	+	((rpm/	3000) factor[(1600/	3000),(2200/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1550/	3000),(1800/	3000)])	*	((rpm/	3000) factor[(2200/	3000),(1950/	3000)]))";
			};
			class Engine4_Thrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_05",0.7943282,1};
				frequency = "0.8	+	((rpm/	3000) factor[(2000/	3000),(2600/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*(((rpm/	3000) factor[(1900/	3000),(2150/	3000)])	*	((rpm/	3000) factor[(2600/	3000),(2300/	3000)]))";
			};
			class Engine5_Thrust_int
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\Truck_02\int_exhaust_06",1.0,1};
				frequency = "0.8	+	((rpm/	3000) factor[(2300/	3000),(3000/	3000)])*0.1";
				volume = "engineOn*(1-camPos)*(0.4+(0.6*(thrust factor[0.1,1])))*((rpm/	3000) factor[(2300/	3000),(2700/	3000)])";
			};
			class Movement
			{
				sound = "soundEnviron";
				frequency = "1";
				volume = "0";
			};
			class TiresRockOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext_tires_dirt_soft_1",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*rock*(speed factor[2, 20])";
			};
			class TiresSandOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext-tires-sand1",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*sand*(speed factor[2, 20])";
			};
			class TiresGrassOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext_tires_dirt_soft_2",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*grass*(speed factor[2, 20])";
			};
			class TiresMudOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext-tires-mud2",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*mud*(speed factor[2, 20])";
			};
			class TiresGravelOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext_tires_gravel_1",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*gravel*(speed factor[2, 20])";
			};
			class TiresAsphaltOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\ext_tires_asfalt_2",1.0,1.0,60};
				frequency = "1";
				volume = "camPos*asphalt*(speed factor[2, 20])";
			};
			class NoiseOut
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\noise_int_car_3",1.0,1.0,90};
				frequency = "1";
				volume = "camPos*(damper0 max 0.02)*(speed factor[0, 8])";
			};
			class TiresRockIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int_tires_dirt_soft_1",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*rock*(speed factor[2, 20])";
			};
			class TiresSandIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int-tires-sand2",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*sand*(speed factor[2, 20])";
			};
			class TiresGrassIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int_tires_dirt_soft_2",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*grass*(speed factor[2, 20])";
			};
			class TiresMudIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int-tires-mud2",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*mud*(speed factor[2, 20])";
			};
			class TiresGravelIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int_tires_gravel_1",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*gravel*(speed factor[2, 20])";
			};
			class TiresAsphaltIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\tires\int_tires_asfalt_2",0.70794576,1.0};
				frequency = "1";
				volume = "(1-camPos)*asphalt*(speed factor[2, 20])";
			};
			class NoiseIn
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\noise_int_car_3",0.70794576,1.0};
				frequency = "1";
				volume = "(damper0 max 0.1)*(speed factor[0, 8])*(1-camPos)";
			};
			class breaking_ext_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_04",0.70794576,1,80};
				frequency = 1;
				volume = "engineOn*camPos*asphalt*(LongSlipDrive Factor[-0.15, -0.3])*(Speed Factor[2, 10])";
			};
			class acceleration_ext_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02",0.70794576,1,80};
				frequency = 1;
				volume = "engineOn*camPos*asphalt*(LongSlipDrive Factor[0.15, 0.3])*(Speed Factor[10, 0])";
			};
			class turn_left_ext_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02",0.70794576,1,80};
				frequency = 1;
				volume = "engineOn*camPos*asphalt*(latSlipDrive Factor[0.15, 0.3])*(Speed Factor[0, 10])";
			};
			class turn_right_ext_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02",0.70794576,1,80};
				frequency = 1;
				volume = "engineOn*camPos*asphalt*(latSlipDrive Factor[-0.15, -0.3])*(Speed Factor[0, 10])";
			};
			class breaking_ext_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_14_dirt_breaking",0.70794576,1,60};
				frequency = 1;
				volume = "engineOn*camPos*(1-asphalt)*(LongSlipDrive Factor[-0.15, -0.3])*(Speed Factor[2, 10])";
			};
			class acceleration_ext_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\acceleration_dirt_ext_1",0.70794576,1,60};
				frequency = 1;
				volume = "engineOn*camPos*(1-asphalt)*(LongSlipDrive Factor[0.15, 0.3])*(Speed Factor[10, 0])";
			};
			class turn_left_ext_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_18_dirt",0.70794576,1,60};
				frequency = 1;
				volume = "engineOn*camPos*(1-asphalt)*(latSlipDrive Factor[0.15, 0.3])*(Speed Factor[0, 10])";
			};
			class turn_right_ext_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_18_dirt",0.70794576,1,60};
				frequency = 1;
				volume = "engineOn*camPos*(1-asphalt)*(latSlipDrive Factor[-0.15, -0.3])*(Speed Factor[0, 10])";
			};
			class breaking_int_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_04_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*asphalt*(1-camPos)*(LongSlipDrive Factor[-0.15, -0.3])*(Speed Factor[2, 6])";
			};
			class acceleration_int_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*asphalt*(1-camPos)*(LongSlipDrive Factor[0.15, 0.3])*(Speed Factor[10, 0])";
			};
			class turn_left_int_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*asphalt*(1-camPos)*(latSlipDrive Factor[0.15, 0.3])*(Speed Factor[0, 10])";
			};
			class turn_right_int_road
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_loop_02_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*asphalt*(1-camPos)*(latSlipDrive Factor[-0.15, -0.3])*(Speed Factor[0, 10])";
			};
			class breaking_int_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_14_dirt_breaking_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*(1-asphalt)*(1-camPos)*(LongSlipDrive Factor[-0.15, -0.3])*(Speed Factor[2, 6])";
			};
			class acceleration_int_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\acceleration_dirt_int_1",0.63095737,1};
				frequency = 1;
				volume = "engineOn*(1-asphalt)*(1-camPos)*(LongSlipDrive Factor[0.15, 0.3])*(Speed Factor[10, 0])";
			};
			class turn_left_int_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_18_dirt_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*(1-asphalt)*(1-camPos)*(latSlipDrive Factor[0.15, 0.3])*(Speed Factor[0, 10])";
			};
			class turn_right_int_dirt
			{
				sound[] = {"A3\Sounds_F\vehicles\soft\noises\slipping_tires_18_dirt_int",0.63095737,1};
				frequency = 1;
				volume = "engineOn*(1-asphalt)*(1-camPos)*(latSlipDrive Factor[-0.15, -0.3])*(Speed Factor[0, 10])";
			};
		};
		thrustDelay = 0.5;
		brakeIdleSpeed = 1.78;
		maxSpeed = 80;
		fuelCapacity = 45;
		antiRollbarForceCoef = 0;
		antiRollbarForceLimit = 5;
		antiRollbarSpeedMin = 0;
		antiRollbarSpeedMax = 20;
		idleRpm = 600;
		redRpm = 3000;
		class complexGearbox
		{
			GearboxRatios[] = {"R1",-10.094,"N",0,"D1",5.562,"D2",3.456,"D3",2.623,"D4",1.678,"D5",1.078};
			TransmissionRatios[] = {"High",5.0};
			gearBoxMode = "auto";
			moveOffGear = 1;
			driveString = "D";
			neutralString = "N";
			reverseString = "R";
		};
		simulation = "carx";
		dampersBumpCoef = 6.0;
		differentialType = "all_limited";
		frontRearSplit = 0.5;
		frontBias = 1.3;
		rearBias = 1.3;
		centreBias = 1.3;
		clutchStrength = 55.0;
		enginePower = 450;
		maxOmega = 320;
		peakTorque = 1950;
		dampingRateFullThrottle = 0.08;
		dampingRateZeroThrottleClutchEngaged = 2.0;
		dampingRateZeroThrottleClutchDisengaged = 0.35;
		torqueCurve[] = {{0.0,0.2},{0.278,0.5},{0.35,0.85},{0.461,1.0},{0.7,0.95},{0.75,0.85},{0.8,0.7},{1.0,0.5}};
		switchTime = 0.51;
		class Wheels
		{
			class L1
			{
				boneName = "wheel_1_1_damper";
				steering = 1;
				side = "left";
				center = "wheel_1_1_axis";
				boundary = "wheel_1_1_bound";
				width = "0.2";
				mass = 80;
				MOI = 40;
				dampingRate = 0.1;
				dampingRateDamaged = 1.0;
				dampingRateDestroyed = 1000.0;
				maxBrakeTorque = 10000;
				maxHandBrakeTorque = 0;
				suspTravelDirection[] = {0,-1,0};
				suspForceAppPointOffset = "wheel_1_1_axis";
				tireForceAppPointOffset = "wheel_1_1_axis";
				maxCompression = 0.15;
				mMaxDroop = 0.15;
				sprungMass = 250;
				springStrength = 6250;
				springDamperRate = 1000;
				longitudinalStiffnessPerUnitGravity = 10000;
				latStiffX = 25;
				latStiffY = 180;
				frictionVsSlipGraph[] = {{0,1},{0.5,1},{1,1}};
			};
			class L2: L1
			{
				boneName = "wheel_1_2_damper";
				steering = 0;
				center = "wheel_1_2_axis";
				boundary = "wheel_1_2_bound";
				suspForceAppPointOffset = "wheel_1_2_axis";
				tireForceAppPointOffset = "wheel_1_2_axis";
			};
			class L3: L1
			{
				boneName = "wheel_1_3_damper";
				steering = 0;
				center = "wheel_1_3_axis";
				boundary = "wheel_1_3_bound";
				suspForceAppPointOffset = "wheel_1_3_axis";
				tireForceAppPointOffset = "wheel_1_3_axis";
				maxHandBrakeTorque = 300000;
			};
			class L4: L1
			{
				boneName = "wheel_1_4_damper";
				steering = 0;
				center = "wheel_1_4_axis";
				boundary = "wheel_1_4_bound";
				suspForceAppPointOffset = "wheel_1_4_axis";
				tireForceAppPointOffset = "wheel_1_4_axis";
				maxHandBrakeTorque = 300000;
			};
			class R1: L1
			{
				boneName = "wheel_2_1_damper";
				center = "wheel_2_1_axis";
				boundary = "wheel_2_1_bound";
				suspForceAppPointOffset = "wheel_2_1_axis";
				tireForceAppPointOffset = "wheel_2_1_axis";
				steering = 1;
				side = "right";
			};
			class R2: R1
			{
				boneName = "wheel_2_2_damper";
				steering = 0;
				center = "wheel_2_2_axis";
				boundary = "wheel_2_2_bound";
				suspForceAppPointOffset = "wheel_2_2_axis";
				tireForceAppPointOffset = "wheel_2_2_axis";
			};
			class R3: R1
			{
				boneName = "wheel_2_3_damper";
				steering = 0;
				center = "wheel_2_3_axis";
				boundary = "wheel_2_3_bound";
				suspForceAppPointOffset = "wheel_2_3_axis";
				tireForceAppPointOffset = "wheel_2_3_axis";
				maxHandBrakeTorque = 300000;
			};
			class R4: R1
			{
				boneName = "wheel_2_4_damper";
				steering = 0;
				center = "wheel_2_4_axis";
				boundary = "wheel_2_4_bound";
				suspForceAppPointOffset = "wheel_2_4_axis";
				tireForceAppPointOffset = "wheel_2_4_axis";
				maxHandBrakeTorque = 300000;
			};
		};
		class RenderTargets
		{
			class mirrorL
			{
				renderTarget = "rendertarget0";
				class mirror
				{
					pointPosition = "PIP0_pos";
					pointDirection = "PIP0_dir";
					renderVisionMode = 4;
					renderQuality = 2;
					fov = 0.5;
				};
			};
		};
		extCameraPosition[] = {0,3,-15};
		class Turrets{};
		class Damage
		{
			/*
			tex[] = {};
			mat[] = {"A3\soft_f_beta\Truck_01\Data\Truck_01_cargo.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_cargo_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_cargo_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_cover.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_cover_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_cover_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_01.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_01_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_01_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_02.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_02_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_ext_02_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base_VP.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base_VP_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_base_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board_destruct.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board_VP.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board_VP_damage.rvmat","A3\soft_f_beta\Truck_01\Data\Truck_01_int_board_destruct.rvmat","A3\data_f\Glass_veh.rvmat","A3\data_f\Glass_veh_armored_damage.rvmat","A3\data_f\Glass_veh_armored_damage.rvmat","A3\data_f\Glass_veh_int.rvmat","A3\data_f\Glass_veh_armored_damage.rvmat","A3\data_f\Glass_veh_armored_damage.rvmat"};
			*/
		};
		class Reflectors
		{
			class Left
			{
				color[] = {1900,1300,950};
				ambient[] = {5,5,5};
				position = "Light_L";
				direction = "Light_L_end";
				hitpoint = "Light_L";
				selection = "Light_L";
				size = 1;
				innerAngle = 100;
				outerAngle = 179;
				coneFadeCoef = 10;
				intensity = 1;
				useFlare = 0;
				dayLight = 0;
				flareSize = 1.0;
				class Attenuation
				{
					start = 1.0;
					constant = 0;
					linear = 0;
					quadratic = 0.25;
					hardLimitStart = 30;
					hardLimitEnd = 60;
				};
			};
			class Right: Left
			{
				position = "Light_R";
				direction = "Light_R_end";
				hitpoint = "Light_R";
				selection = "Light_R";
			};
			class Right2: Right
			{
				useFlare = 1;
				position = "light_R_flare";
			};
			class Left2: Left
			{
				useFlare = 1;
				position = "light_L_flare";
			};
		};
		aggregateReflectors[] = {{"Left","Right","Left2","Right2"}};		
		numberPhysicalWheels = 8;
	};
	
	
	class JustMathew_M1070_Truck_01_base: Truck_01_base_F
	{
		model 	= "\JustMathew_M1070_Truck_01\JustMathew_M1070_Truck_01";  /// simple path to model
		picture	= "\A3\Weapons_F\Data\placeholder_co.paa"; /// just some icon in command bar
		Icon	= "\A3\Weapons_F\Data\placeholder_co.paa"; /// icon in map

		

		terrainCoef 	= 6.5; 	/// different surface affects this car more, stick to tarmac
		turnCoef 		= 2.5; 	/// should match the wheel turn radius
		precision 		= 10; 	/// how much freedom has the AI for its internal waypoints - lower number means more precise but slower approach to way
		brakeDistance 	= 3.0; 	/// how many internal waypoints should the AI plan braking in advance
		acceleration 	= 15; 	/// how fast acceleration does the AI think the car has

		fireResistance 	= 5; 	/// lesser protection against fire than tanks
		armor 			= 32; 	/// just some protection against missiles, collisions and explosions
		cost			= 50000; /// how likely is the enemy going to target this vehicle

		transportMaxBackpacks 	= 3; /// just some backpacks fit the trunk by default
		transportSoldier 		= 3; /// number of cargo except driver

		/// some values from parent class to show how to set them up
		wheelDamageRadiusCoef 	= 0.9; 			/// for precision tweaking of damaged wheel size
		wheelDestroyRadiusCoef 	= 0.4;			/// for tweaking of rims size to fit ground
		maxFordingDepth 		= 0.5;			/// how high water would damage the engine of the car
		waterResistance 		= 1;			/// if the depth of water is bigger than maxFordingDepth it starts to damage the engine after this time
		crewCrashProtection		= 0.25;			/// multiplier of damage to crew of the vehicle => low number means better protection
		driverLeftHandAnimName 	= "drivewheel"; /// according to what bone in model of car does hand move
		driverRightHandAnimName = "drivewheel";	/// beware, non-existent bones may cause game crashes (even if the bones are hidden during play)

		/*
		class TransportItems /// some first aid kits in trunk according to safety regulations
		{
			item_xx(FirstAidKit,4);
		};
		*/
		
		
		class Turrets{}; /// doesn't have any gunner nor commander
		class HitPoints: HitPoints
		{
			class HitLFWheel: HitLFWheel	{armor=0.125; passThrough=0;}; /// it is easier to destroy wheels than hull of the vehicle
			class HitLF2Wheel: HitLF2Wheel	{armor=0.125; passThrough=0;};

			class HitRFWheel: HitRFWheel	{armor=0.125; passThrough=0;};
			class HitRF2Wheel: HitRF2Wheel 	{armor=0.125; passThrough=0;};

			class HitFuel 			{armor=0.50; material=-1; name="fueltank"; visual=""; passThrough=0.2;}; /// correct points for fuel tank, some of the damage is aFRLied to the whole
			class HitEngine 		{armor=0.50; material=-1; name="engine"; visual=""; passThrough=0.2;};
			class HitBody: HitBody 	{name = "body"; visual="camo1"; passThrough=1;}; /// all damage to the hull is aFRLied to total damage

			class HitGlass1: HitGlass1 {armor=0.25;}; /// it is pretty easy to puncture the glass but not so easy to remove it
			class HitGlass2: HitGlass2 {armor=0.25;};
			class HitGlass3: HitGlass3 {armor=0.25;};
			class HitGlass4: HitGlass4 {armor=0.25;};
		};

		
		
		class PlayerSteeringCoefficients /// steering sensitivity configuration
		{
			 turnIncreaseConst 	= 0.3; // basic sensitivity value, higher value = faster steering
			 turnIncreaseLinear = 1.0; // higher value means less sensitive steering in higher speed, more sensitive in lower speeds
			 turnIncreaseTime 	= 1.0; // higher value means smoother steering around the center and more sensitive when the actual steering angle gets closer to the max. steering angle

			 turnDecreaseConst 	= 5.0; // basic caster effect value, higher value = the faster the wheels align in the direction of travel
			 turnDecreaseLinear = 3.0; // higher value means faster wheel re-centering in higher speed, slower in lower speeds
			 turnDecreaseTime 	= 0.0; // higher value means stronger caster effect at the max. steering angle and weaker once the wheels are closer to centered position

			 maxTurnHundred 	= 0.7; // coefficient of the maximum turning angle @ 100km/h; limit goes linearly to the default max. turn. angle @ 0km/h
		};

		/// memory points where do tracks of the wheel appear
		// front left track, left offset
		memoryPointTrackFLL = "TrackFLL";
		// front left track, right offset
		memoryPointTrackFLR = "TrackFLR";
		// back left track, left offset
		memoryPointTrackBLL = "TrackBLL";
		// back left track, right offset
		memoryPointTrackBLR = "TrackBLR";
		// front right track, left offset
		memoryPointTrackFRL = "TrackFRL";
		// front right track, right offset
		memoryPointTrackFRR = "TrackFRR";
		// back right track, left offset
		memoryPointTrackBRL = "TrackBRL";
		// back right track, right offset
		memoryPointTrackBRR = "TrackBRR";

		class Damage /// damage changes material in specific places (visual in hitPoint)
		{
			/*
			tex[]={};
			mat[]=
			{
				"A3\data_f\glass_veh_int.rvmat", 		/// material mapped in model
				"A3\data_f\Glass_veh_damage.rvmat", 	/// changes to this one once damage of the part reaches 0.5
				"A3\data_f\Glass_veh_damage.rvmat",		/// changes to this one once damage of the part reaches 1

				"A3\data_f\glass_veh.rvmat",			/// another material
				"A3\data_f\Glass_veh_damage.rvmat",		/// changes into different ones
				"A3\data_f\Glass_veh_damage.rvmat"
			};
			*/
		};
		/*	DEFINED EARLIER
		class Exhausts /// specific exhaust effects for the car
		{
			class Exhaust1 /// the car has two exhausts - each on one side
			{
				position 	= "exhaust1_pos";  		/// name of initial memory point
				direction 	= "exhaust1_dir";	/// name of memory point for exhaust direction
				effect 		= "ExhaustsEffect";	/// what particle effect is it going to use
			};

		};
		*/

		class Reflectors	/// only front lights are considered to be reflectors to save CPU
		{
			class LightCarHeadL01 	/// lights on each side consist of two bulbs with different flares
			{
				color[] 		= {1900, 1800, 1700};		/// approximate colour of standard lights
				ambient[]		= {5, 5, 5};				/// nearly a white one
				position 		= "LightCarHeadL01";		/// memory point for start of the light and flare
				direction 		= "LightCarHeadL01_end";	/// memory point for the light direction
				hitpoint 		= "Light_L";				/// point(s) in hitpoint lod for the light (hitPoints are created by engine)
				selection 		= "Light_L";				/// selection for artificial glow around the bulb, not much used any more
				size 			= 1;						/// size of the light point seen from distance
				innerAngle 		= 100;						/// angle of full light
				outerAngle 		= 179;						/// angle of some light
				coneFadeCoef 	= 10;						/// attenuation of light between the above angles
				intensity 		= 1;						/// strength of the light
				useFlare 		= true;						/// does the light use flare?
				dayLight 		= false;					/// switching light off during day saves CPU a lot
				flareSize 		= 1.0;						/// how big is the flare

				class Attenuation
				{
					start 			= 1.0;
					constant 		= 0;
					linear 			= 0;
					quadratic 		= 0.25;
					hardLimitStart 	= 30;		/// it is good to have some limit otherwise the light would shine to infinite distance
					hardLimitEnd 	= 60;		/// this allows adding more lights into scene
				};
			};

			class LightCarHeadL02: LightCarHeadL01
			{
				position 	= "LightCarHeadL02";
				direction 	= "LightCarHeadL02_end";
				FlareSize 	= 0.5;						/// side bulbs aren't that strong
			};

			class LightCarHeadR01: LightCarHeadL01
			{
				position 	= "LightCarHeadR01";
				direction 	= "LightCarHeadR01_end";
				hitpoint 	= "Light_R";
				selection 	= "Light_R";
			};

			class LightCarHeadR02: LightCarHeadR01
			{
				position 	= "LightCarHeadR02";
				direction 	= "LightCarHeadR02_end";
				FlareSize 	= 0.5;
			};
		};

		aggregateReflectors[] = {{"LightCarHeadL01", "LightCarHeadL02"}, {"LightCarHeadR01", "LightCarHeadR02"}}; /// aggregating reflectors helps the engine a lot
		/// it might be even good to aggregate all lights into one source as it is done for most of the cars
		
		
		/*
		class EventHandlers: EventHandlers
		{
			// (_this select 0): the vehicle
			// """" Random texture source (pick one from the property textureList[])
			// []: randomize the animation sources (accordingly to the property animationList[])
			// false: Don't change the mass even if an animation source has a defined mass
			init="if (local (_this select 0)) then {[(_this select 0), """", [], false] call bis_fnc_initVehicle;};";
		};
		*/
		// Must be kept as fail-safe in case of issue with the function
		// hiddenSelectionsTextures[]={"\A3\Weapons_F\Data\placeholder_co.paa"};	 /// we could use any texture to cover the car

		/*
		class MFD /// Clocks on the car board
		{
			class ClockHUD
			{
				#include "cfgHUD.hpp"
			};
		};
		*/
	};
	class JustMathew_M1070_Truck_01: JustMathew_M1070_Truck_01_base
	{
		scope	= 2; 			/// makes the car visible in editor
		scopeCurator=2;			/// scope 2 means it's available in Zeus mode (0 means hidden)
		crew 	= "B_crew_F"; 	/// we need someone to fit into the car
		side	= 1; 			/// civilian car should be on civilian side
		faction	= BLU_F;		/// and with civilian faction
		
		displayName = "M1070 HET"; /// displayed in Editor
	};
	
	
	/*
	// Derivate from the base class
	class JustMathew_M1070_Truck_01_Olive: JustMathew_M1070_Truck_01 /// some class that is going to be visible in editor
	{
		scope	= 2; 			/// makes the car visible in editor
		scopeCurator=2;			// scope 2 means it's available in Zeus mode (0 means hidden)
		crew 	= "B_crew_F"; 	/// we need someone to fit into the car
		side	= 1; 			/// civilian car should be on civilian side
		faction	= BLU_F;		/// and with civilian faction
	};
	// Derivate from the base class
	class JustMathew_M1070_Truck_01_Sand: JustMathew_M1070_Truck_01_Olive /// some class that is going to be visible in editor
	{
		forceInGarage=1; 	// This will force the garage to display this vehicle, otherwise it won't because it shares the same p3d as the previous
		displayName="Test Car (Black)";
		scope=2; 			/// makes the car visible in editor
		scopeCurator=2;		// scope 2 means it's available in Zeus mode (0 means hidden)
		crew="C_man_1"; 	/// we need someone to fit into the car
		side=3; 			/// civilian car should be on civilian side
		faction	= CIV_F;	/// and with civilian faction
		// the texture source used will be the green one, whatever it probability because it's the only one defined here
		textureList[]=
		{
			"black", 1
		};
	};
	*/
}; 

 

Model.cfg

class Rotation
{
	type = "rotation";
	memory = 1;
	minValue = 0;
	maxValue = 1;
	angle0 = 0;
	angle1 = 1;
};
class CfgSkeletons
{
	class Default
	{
		isDiscrete = 1;
		skeletonInherit = "";
		skeletonBones[] = {};
	};
	class Vehicle : Default {};
	class Car : Vehicle {
		skeletonBones[]=
		{
			"drivewheel","",

			"wheel_1_1_damper_land","",
			"wheel_1_2_damper_land","",
			"wheel_1_3_damper_land","",
			"wheel_1_4_damper_land","",

			"wheel_2_1_damper_land","",
			"wheel_2_2_damper_land","",
			"wheel_2_3_damper_land","",
			"wheel_2_4_damper_land","",

			"wheel_1_1_damper","wheel_1_1_damper_land",
			"wheel_1_2_damper","wheel_1_2_damper_land",
			"wheel_1_3_damper","wheel_1_3_damper_land",
			"wheel_1_4_damper","wheel_1_4_damper_land",

			"wheel_2_1_damper","wheel_2_1_damper_land",
			"wheel_2_2_damper","wheel_2_2_damper_land",
			"wheel_2_3_damper","wheel_2_3_damper_land",
			"wheel_2_4_damper","wheel_2_4_damper_land",

			"wheel_1_1_steering","wheel_1_1_damper",
			"wheel_1_2_steering","wheel_1_2_damper",
			"wheel_1_3_steering","wheel_1_3_damper",
			"wheel_1_4_steering","wheel_1_4_damper",

			"wheel_2_1_steering","wheel_2_1_damper",
			"wheel_2_2_steering","wheel_2_2_damper",
			"wheel_2_3_steering","wheel_2_3_damper",
			"wheel_2_4_steering","wheel_2_4_damper",

			"wheel_1_1","wheel_1_1_steering",
			"wheel_1_2","wheel_1_2_steering",
			"wheel_1_3","wheel_1_3_steering",
			"wheel_1_4","wheel_1_4_steering",

			"wheel_2_1","wheel_2_1_steering",
			"wheel_2_2","wheel_2_2_steering",
			"wheel_2_3","wheel_2_3_steering",
			"wheel_2_4","wheel_2_4_steering",

			"wheel_1_1_unhide","wheel_1_1",
			"wheel_1_2_unhide","wheel_1_2",
			"wheel_1_3_unhide","wheel_1_3",
			"wheel_1_4_unhide","wheel_1_4",

			"wheel_2_1_unhide","wheel_2_1",
			"wheel_2_2_unhide","wheel_2_2",
			"wheel_2_3_unhide","wheel_2_3",
			"wheel_2_4_unhide","wheel_2_4",

			"wheel_1_1_hide","wheel_1_1",
			"wheel_1_2_hide","wheel_1_2",
			"wheel_1_3_hide","wheel_1_3",
			"wheel_1_4_hide","wheel_1_4",

			"wheel_2_1_hide","wheel_2_1",
			"wheel_2_2_hide","wheel_2_2",
			"wheel_2_3_hide","wheel_2_3",
			"wheel_2_4_hide","wheel_2_4",

			"OtocVez","",
			"OtocHlaven","OtocVez",

			"damageHide","",
			"damageVez","OtocVez",
			"damageHlaven","OtocHlaven",

			"ukaz_rychlo","",
			"ukaz_rychlo2","",
			"ukaz_rpm","",
			"mph","",
			"rpm","",
			"fuel","",
			"fuel_1","",
			"fuel_01","",
			"fuel_2","",
			"fuel_3","",
			"prop_01","",
			"prop_02","",
			"prop_2","",
			"prop_1","",
			"glass1","damageHide",
			"glass2","damageHide",
			"glass3","damageHide",
			"glass4","damageHide"
		};
	};
	
	class Truck: Car;
	class JustMathew_M1070_Truck_01_bones: Truck
	{
		skeletonInherit="Truck";
		skeletonBones[]=
		{
			"reverse_light","",
			"daylights","damageHide",
			"door1","",
			"door2","",
			"glass5","damageHide"
		};
	};
	
};

class CfgModels
{
	class Default
	{
		sectionsInherit = "";
		sections[] = {};
		skeletonName = "";
	};
	class Vehicle: Default
	{
		sections[] =
		{
			"cislo",
			"grupa",
			"side",
			"sektor",
			"clan",
			"clan_sign",
			"podsvit pristroju",
			"poskozeni",
			"L svetlo",
			"P svetlo",
			"zasleh"
		};
	};	
	
	class Car: Vehicle
	{
		htMin = 60;		// Minimum half-cooling time (in seconds)
		htMax = 180;	// Maximum half-cooling time (in seconds)
		afMax = 100;	// Maximum temperature in case the model is alive (in celsius)
		mfMax = 8;		// Maximum temperature when the model is moving (in celsius)
		mFact = 1;		// Metabolism factor - number from interval <0, 1> (0 - metabolism has no influence, 1 - metabolism has full influence (no other temperature source will be considered)).
		tBody = 150;	// Metabolism temperature of the model (in celsius)

		sections[]=
		{
			"ammo",
			"zadni svetlo",
			"brzdove svetlo",
			"spz",
			"motor",
			"body",
			"clan",
			"clan_sign",
			"zasleh",
			"Light_R",
			"Light_L",
			"podsvit pristroju",
			"glass1",
			"glass2",
			"glass3",
			"glass4",
			"glass5",
			"glass6"
		};
		skeletonName="Car";
		class Animations
		{
			// destruct START
			class damageHide
			{
				type="hide";
				source="damage";
				selection="damageHide";
				hideValue=1.0;
			};
			class damageHideVez:damageHide
			{
				selection="OtocVez";
			};
			class damageHideHlaven:damageHide
			{
				selection="OtocHlaven";
			};

			// Wheels START
			// Wheels Complete Destruct START
			class wheel_1_1_destruct
			{
				type="hide";
				selection="wheel_1_1_hide";
				source="HitLFWheel";
				minValue = 0; // upravit na 0.99
				maxValue = 1; // upravit na 1.0
				hidevalue = 0.99999;
			};
			class wheel_1_2_destruct: wheel_1_1_destruct {source="HitLBWheel";selection="wheel_1_2_hide";};
			class wheel_1_3_destruct: wheel_1_1_destruct {source="HitLMWheel";selection="wheel_1_3_hide";};
			class wheel_1_4_destruct: wheel_1_1_destruct {source="HitLF2Wheel";selection="wheel_1_4_hide";};

			class wheel_2_1_destruct: wheel_1_1_destruct {source="HitRFWheel";selection="wheel_2_1_hide";};
			class wheel_2_2_destruct: wheel_1_1_destruct {source="HitRBWheel";selection="wheel_2_2_hide";};
			class wheel_2_3_destruct: wheel_1_1_destruct {source="HitRMWheel";selection="wheel_2_3_hide";};
			class wheel_2_4_destruct: wheel_1_1_destruct {source="HitRF2Wheel";selection="wheel_2_4_hide";};

			class wheel_1_1_destruct_unhide
			{
				type="hide";
				selection="wheel_1_1_unhide";
				source="HitLFWheel";
				minValue = 0; 
				maxValue = 1; 
				hidevalue = 0.00000;
				UnHidevalue = 1.00000;
			};
			class wheel_1_2_destruct_unhide: wheel_1_1_destruct_unhide {source="HitLBWheel";selection="wheel_1_2_unhide";};
			class wheel_1_3_destruct_unhide: wheel_1_1_destruct_unhide {source="HitLMWheel";selection="wheel_1_3_unhide";};
			class wheel_1_4_destruct_unhide: wheel_1_1_destruct_unhide {source="HitLF2Wheel";selection="wheel_1_4_unhide";};

			class wheel_2_1_destruct_unhide: wheel_1_1_destruct_unhide {source="HitRFWheel";selection="wheel_2_1_unhide";};
			class wheel_2_2_destruct_unhide: wheel_1_1_destruct_unhide {source="HitRBWheel";selection="wheel_2_2_unhide";};
			class wheel_2_3_destruct_unhide: wheel_1_1_destruct_unhide {source="HitRMWheel";selection="wheel_2_3_unhide";};
			class wheel_2_4_destruct_unhide: wheel_1_1_destruct_unhide {source="HitRF2Wheel";selection="wheel_2_4_unhide";};

			// Wheels Complete Destruct END

			#define DamageOffset 0.2

			// Wheels Damage START
			class wheel_1_1_Damage: wheel_1_1_destruct
			{
				type="translation";
				axis="Basic_Damper_Destruct_Axis";
				memory=1;
				selection="wheel_1_1_damper";
				source="HitLFWheel";
				minValue = 0.0;
				maxValue = 1;
				offset0 = 0;
				offset1 = DamageOffset;
			};
			class wheel_1_2_Damage: wheel_1_1_Damage {source="HitLBWheel";selection="wheel_1_2_damper";};
			class wheel_1_3_Damage: wheel_1_1_Damage {source="HitLMWheel";selection="wheel_1_3_damper";};
			class wheel_1_4_Damage: wheel_1_1_Damage {source="HitLF2Wheel";selection="wheel_1_4_damper";};

			class wheel_2_1_Damage: wheel_1_1_Damage {source="HitRFWheel";selection="wheel_2_1_damper";};
			class wheel_2_2_Damage: wheel_1_1_Damage {source="HitRBWheel";selection="wheel_2_2_damper";};
			class wheel_2_3_Damage: wheel_1_1_Damage {source="HitRMWheel";selection="wheel_2_3_damper";};
			class wheel_2_4_Damage: wheel_1_1_Damage {source="HitRF2Wheel";selection="wheel_2_4_damper";};


			class wheel_1_1_Damper_Damage_BackAnim: wheel_1_1_Damage {selection="wheel_1_1_damper";offset1 = -1.2*DamageOffset;};
			class wheel_1_2_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitLBWheel";selection="wheel_1_2_damper";};
			class wheel_1_3_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitLMWheel";selection="wheel_1_3_damper";};
			class wheel_1_4_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitLF2Wheel";selection="wheel_1_4_damper";};

			class wheel_2_1_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitRFWheel";selection="wheel_2_1_damper";};
			class wheel_2_2_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitRBWheel";selection="wheel_2_2_damper";};
			class wheel_2_3_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitRMWheel";selection="wheel_2_3_damper";};
			class wheel_2_4_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim {source="HitRF2Wheel";selection="wheel_2_4_damper";};

			// Wheels Damage END
			// Wheels END

				//Glass Damage START
				class Glass1_destruct
				{
					type="hide";
					selection="glass1";
					source="HitGlass1";
					minValue = 0; 
					maxValue = 1; 
					hidevalue = 0.99999;
				};
				class Glass2_destruct: Glass1_destruct {selection="glass2";source="HitGlass2";}; // Inherits from the the glass 1, only the selection and the source will be changed
				class Glass3_destruct: Glass1_destruct {selection="glass3";source="HitGlass3";};
				class Glass4_destruct: Glass1_destruct {selection="glass4";source="HitGlass4";};
				class Glass5_destruct: Glass1_destruct {selection="glass5";source="HitGlass5";};
				class Glass6_destruct: Glass1_destruct {selection="glass6";source="HitGlass6";};
				//Glass Damage END

			// destruct END
			class Fuel: Rotation
			{
				source="fuel";
				selection="fuel";
				axis="fuel_axis";
				maxValue=1;
				memory=1;
				angle0="rad -110";
				angle1=0;
			};
			class IndicatorSpeed: Rotation
			{
				source="speed";
				selection="mph";
				axis="mph_axis";
				memory=1;
				maxValue=38.900002;
				angle1="rad -265";
			};
			class IndicatorFuel: Rotation
			{
				type="rotation";
				source="fuel";
				selection="fuel_1";
				axis="fuel_1_axis";
				memory=1;
				minValue=0.000000;
				maxValue=1.000000;
				angle0=-0.087266;
				angle1=-1.658063;
			};
			class IndicatorRPM: Rotation
			{
				source="rpm";
				selection="rpm";
				axis="rpm_axis";
				memory=1;
				angle1="rad 80";
			};
			class DrivingWheel: Rotation
			{
				source="drivingWheel";
				selection="drivewheel";
				axis="drivewheel_axis";
				minValue=-1;
				maxValue=1;
				angle0=(rad 80);
				angle1=(rad -80);
			};
			class Steering_1_1
			{
				type="rotationY";
				source="drivingWheel";
				selection="wheel_1_1_steering";
				axis="wheel_1_1_steering_axis";
				memory=1;
				minValue= -1;
				maxValue= 1;
				angle0=1.047198;
				angle1=-1.047198;
			};
			class Steering_2_1: Steering_1_1
			{
				selection="wheel_2_1_steering";
				axis="wheel_2_1_steering_axis";
			};
			class Wheel_1_1
			{
				type="rotationX";
				source="wheel";
				selection="wheel_1_1";
				axis="wheel_1_1_axis";
				memory=1;
				sourceAddress="loop";
				minValue=0;
				maxValue=1;
				angle0=0;
				angle1="rad -360";
			};
			class wheel_2_1: Wheel_1_1
			{
				selection="wheel_2_1";
				axis="wheel_2_1_axis";
			};
			class wheel_1_2: Wheel_1_1
			{
				selection="wheel_1_2";
				axis="wheel_1_2_axis";
			};
			class wheel_1_3: Wheel_1_1
			{
				selection="wheel_1_3";
				axis="wheel_1_3_axis";
			};
			class Wheel_2_2: Wheel_1_1
			{
				selection="wheel_2_2";
				axis="wheel_2_2_axis";
			};
			class Wheel_2_3: Wheel_1_1
			{
				selection="wheel_2_3";
				axis="wheel_2_3_axis";
			};
			class Wheel_1_4: Wheel_1_1
			{
				selection="wheel_1_4";
				axis="wheel_1_4_axis";
			};
			class Wheel_2_4: Wheel_1_1
			{
				selection="wheel_2_4";
				axis="wheel_2_4_axis";
			};
			class Wheel_1_1_Damper
			{
				type="translation";
				source="damper";
				selection="wheel_1_1_damper_land";
				axis="posun wheel_1_1";
				animPeriod = 1;
				minValue="0";
				maxValue="1";
				offset0= "0.5";
				offset1= "-0.5";
				memory=0;
			};
			class wheel_2_1_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_1_damper_land";
			};
			class wheel_1_2_Damper: Wheel_1_1_Damper
			{
				selection="wheel_1_2_damper_land";
			};
			class Wheel_1_3_Damper: Wheel_1_1_Damper
			{
				selection="wheel_1_3_damper_land";
			};
			class Wheel_1_4_Damper: Wheel_1_1_Damper
			{
				selection="wheel_1_4_damper_land";
			};
			class Wheel_2_2_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_2_damper_land";
			};
			class Wheel_2_3_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_3_damper_land";
			};
			class Wheel_2_4_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_4_damper_land";
			};
			
			class daylights
			{
				type="hide";
				source="rpm";
				selection="daylights";
				minValue=-0.8;
				maxValue=0.2;
				unhidevalue=1;
				sourceAddress="clamp";
			};
			
			class reverse_light
			{
				type="Hide";
				selection="reverse_light";
				sourceAddress="clamp";
				source="Gear";
				minValue = -1;
				maxValue = 0;
				hideValue = "0.2";	
			};			
		};
	};
	
	class Truck: Car
	{
		skeletonName="Truck";
		sectionsInherit = "Car";
		sections[] ="";
	};

	
	class JustMathew_M1070_Truck_01: Truck
	{
		skeletonName = "JustMathew_M1070_Truck_01_bones";
		sectionsInherit = "Truck";
		sections[]=
		{
			"Camo1",
			"Camo2",
			"Camo3",
			"body",
			"karoserie",
			"palivo"
		};
		class Animations: Animations
		{
			
			class DrivingWheel
			{
				type="rotation";
				source="drivingWheel";
				selection="drivewheel";
				axis="drivewheel_axis";
				memory=1;
				minValue=-1;
				maxValue=1;
				angle0=(rad 70);
				angle1=(rad -70);
			};
			class Steering_1_1
			{
				type="rotationY";
				source="drivingWheel";
				selection="wheel_1_1_steering";
				axis="wheel_1_1_steering_axis";
				memory=1;
				minValue="rad -90";
				maxValue="rad +90";
				angle0=1.0471981;
				angle1=-1.0471981;
			};
			class Steering_2_1: Steering_1_1
			{
				selection="wheel_2_1_steering";
				axis="wheel_2_1_steering_axis";
				angle0=1.0471981;
				angle1=-1.0471981;
			};
			class IndicatorSpeed: Rotation
			{
				source="speed";
				selection="mph";
				axis="mph_axis";
				memory=1;
				maxValue=28;
				angle0=0.17453299;
				angle1=-3.141593;
			};
			class IndicatorRPM: Rotation
			{
				type="rotation";
				source="rpm";
				selection="rpm";
				axis="rpm_axis";
				memory=1;
				minValue=0;
				maxValue=7500;
				angle0=(rad 0);
				angle1=(rad 250);
			};				
			class fuel
			{
				type="rotation";
				source="fuel";
				selection="fuel";
				axis="fuel_axis";
				memory=1;
				minValue=0;
				maxValue=1;
				angle0=0;
				angle1="rad +55";
			};
			class prop_01
			{
				type="rotation";
				source="rpm";
				selection="prop_1";
				axis="prop_1_axis";
				memory=1;
				minValue=1000;
				maxValue=7000;
				angle0="rad 30";
				angle1="rad 35";
			};
			
			class daylights
			{
				type="hide";
				source="rpm";
				selection="daylights";
				minValue=-0.8;
				maxValue=0.2;
				unhidevalue=1;
				sourceAddress="clamp";
			};
			
			class reverse_light
			{
				type="Hide";
				selection="reverse_light";
				sourceAddress="clamp";
				source="Gear";
				minValue = -1;
				maxValue = 0;
				hideValue = "0.2";	
			};
			
			class damageHidedoor1: damageHide
			{
				selection="door1";
			};
			class damageHidedoor2: damageHide
			{
				selection="door2";
			};	
			
			class Glass5_destruct
			{
				type="hide";
				selection="glass5";
				source="HitGlass5";
				minValue = 0;
				maxValue = 1;
				hidevalue = 0.99999;
			};	
			class Wheel_1_1_Damper: Wheel_1_1_Damper
			{
				type="translation";
				source="damper";
				selection="wheel_1_1_damper_land";
				axis="basic_damper_destruct_axis";
				animPeriod = 1;
				minValue="0";
				maxValue="1";
				offset0= "0.5";
				offset1= "-0.5";
				memory=1;
			};
			class wheel_2_1_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_1_damper_land";			
			};
			class wheel_1_2_Damper: Wheel_1_1_Damper
			{
				selection="wheel_1_2_damper_land";						
			};
			class Wheel_2_2_Damper: Wheel_1_1_Damper
			{
				selection="wheel_2_2_damper_land";		
			};			
		};
	};
};

 

 

Update:

I figured out how to get wheel dampers working, I forgot to define the rear 4 wheels in my class at the end of model.cfg. At this point I'm trying to get the dampers working the right way. When t should go up it goes down, and vice versa.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×