JCass 1 Posted March 12, 2018 I have managed to make it quite a bit further since my last post, however I am having trouble getting the turrets to animate correctly. I have 2 hmg turrets on my buggy. I can see them both and fire the weapons, but I cannot move them. I have been doing a lot of trial and error here w cfgSkeleton and cfgModel but nothing is producing the result I am after. Here is my model.cfg and config.cpp. I'm running out of ideas for what to try next, any assistance would be greatly appreciated. config.cpp Quote #include "basicdefines_A3.hpp" class DefaultEventhandlers; class CfgPatches { class Buggy { units[] = {"Buggy"}; weapons[] = {}; requiredVersion = 0.1; requiredAddons[] = { "A3_Soft_F", "A3_Data_F" }; }; }; class WeaponFireGun; class WeaponCloudsGun; class WeaponFireMGun; class WeaponCloudsMGun; class CfgVehicles { class LandVehicle; class Car: LandVehicle { class NewTurret; }; class Car_F: Car { class HitPoints /// we want to use hitpoints predefined for all cars { class HitLFWheel; class HitLF2Wheel; class HitRFWheel; class HitRF2Wheel; class HitBody; }; class EventHandlers; class AnimationSources; class Turrets { class MainTurret: NewTurret { class ViewOptics; class ViewGunner; }; }; }; class Buggy: Car_F { model = "Vehicles\Buggy\Buggy.p3d"; /// 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 displayName = "Buggy"; /// displayed in Editor hiddenSelections[] = {"camo1"}; ///we want to allow changing the color of this selection 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 = 0; /// 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 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 }; driverAction = driver_low01; /// what action is going the driver take inside the vehicle. Non-existent action makes the vehicle inaccessible cargoAction[] = {}; /// the same of all the crew commanderAction = gunner_amv; getInAction = GetInLow; /// how does driver look while getting in getOutAction = GetOutLow; /// and out cargoGetInAction[] = {"GetInLow"}; /// and the same for the rest, if the array has fewer members than the count of crew, the last one is used for the rest cargoGetOutAction[] = {"GetOutLow"}; /// that means all use the same in this case commanderGetInAction = GetInLow; commanderGetOutAction = GetOutLow; hideWeaponsDriver = True; hideWeaponsCargo = True; #include "sounds.hpp" /// sounds are in a separate file to make this one simple #include "physx.hpp" /// PhysX settings are in a separate file to make this one simple 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" }; }; 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 = "ExhaustEffectOffroad"; /// what particle effect is it going to use }; class Exhaust2 { position = "exhaust2_pos"; direction = "exhaust2_dir"; effect = "ExhaustEffectOffroad"; }; }; 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{}; }; class Buggy_Black: Buggy { scope = 2; scopeCurator=2; crew = "I_G_Soldier_F"; side = 2; faction = "IND_G_F"; displayName="Buggy"; author="J0N"; // Author of the skin hiddenSelectionsTextures[] = {"Vehicles\Buggy\data\Tex_0020_1.paa"}; class Turrets: Turrets { class TopTurret: MainTurret { disableSoundAttenuation=1; gunnerLeftHandAnimName="otocHlaven"; gunnerRightHandAnimName="otocHlaven"; body="mainTurret"; gun="mainGun"; animationSourceBody="mainTurret"; animationSourceGun="mainGun"; weapons[]= { "HMG_127_LSV_01" }; magazines[]= { "100Rnd_127x99_mag_Tracer_Red", "100Rnd_127x99_mag_Tracer_Red", "100Rnd_127x99_mag_Tracer_Red" }; minElev=-10; maxElev=40; soundServo[]= { "A3\sounds_f\dummysound", 9.9999977e-007, 1 }; gunnerAction="gunner_mrap_01"; gunnerCompartments="Compartment1"; ejectDeadGunner=0; castGunnerShadow=1; stabilizedInAxes=0; gunBeg="muzzle_beg"; gunEnd="muzzle_end"; memoryPointGunnerOptics="gunnerView"; memoryPointsGetInGunner="pos cargo"; memoryPointsGetInGunnerDir="pos cargo dir"; commanding=-2; primaryGunner=1; optics=1; discreteDistance[]={100,200,300,400,600,800,1000,1200,1500}; discreteDistanceInitIndex=2; turretInfoType="RscOptics_crows"; gunnerOpticsModel="\a3\weapons_f_gamma\reticle\HMG_01_Optics_Gunner_F"; class ViewOptics: ViewOptics { initAngleX=0; minAngleX=-30; maxAngleX=30; initAngleY=0; minAngleY=-100; maxAngleY=100; initFov=0.75; minFov=0.25; maxFov=1.25; visionMode[]= { "Normal", "NVG" }; }; class ViewGunner: ViewGunner { }; }; class CodRiverTurret: MainTurret { proxyType="CPCargo"; gunnerName="$STR_POSITION_COMMANDER"; gunnerLeftHandAnimName="otocHlaven_2"; gunnerRightHandAnimName="otocHlaven_2"; body="CodRiverTurret"; gun="CodRiverGun"; animationSourceBody="CodRiverTurret"; animationSourceGun="CodRiverGun"; weapons[]= { "MMG_02_vehicle" }; magazines[]= { "130Rnd_338_Mag", "130Rnd_338_Mag", "130Rnd_338_Mag" }; class TurnIn { limitsArrayTop[]= { {18.2467,-25.1915}, {13.9927,25.8645} }; limitsArrayBottom[]= { {-9.6644001,-35.7248}, {-9.8597002,27.203501} }; }; class TurnOut: TurnIn { }; soundServo[]= { "A3\sounds_f\dummysound", 9.9999977e-007, 1 }; gunnerAction="gunner_mrap_03"; gunBeg="muzzle_2_beg"; gunEnd="muzzle_2_end"; memoryPointGunnerOptics="gunnerView_2"; memoryPointsGetInGunner="pos_codriver"; memoryPointsGetInGunnerDir="pos_codriver_dir"; commanding=-2; primaryGunner=0; optics=0; discreteDistance[]={100,200,300,400,600,800,1000,1200,1500}; discreteDistanceInitIndex=2; turretInfoType="RscOptics_Offroad_01"; class ViewOptics: ViewOptics { minFov=0.25; maxFov=1.25; initFov=0.75; }; class ViewGunner: ViewGunner { }; }; }; }; }; model.cfg Quote 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", "damageHide","", "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","" }; }; class civil_car: Car { skeletonName = "civil_car"; skeletonInherit="Car"; skeletonBones[]= { "camo1", "damageHide", "mainTurret","", "mainGun","mainTurret", "codRiverTurret","", "codRiverGun","codRiverTurret" }; }; }; 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", "mainTurret","", "mainGun","mainTurret", "codRiverTurret","", "codRiverGun","codRiverTurret" }; }; 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=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"; }; 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 Buggy: Car { skeletonName = "civil_car"; sectionsInherit = "Car"; sections[]= { "Camo1", "body", "karoserie", "palivo" }; class Animations: Animations { class wheel_1_1_Damage: wheel_1_1_Damage{offset1=0.18000001;}; class wheel_1_2_Damage: wheel_1_2_Damage{offset1=0.18000001;}; class wheel_2_1_Damage: wheel_2_1_Damage{offset1=0.18000001;}; class wheel_2_2_Damage: wheel_2_2_Damage{offset1=0.18000001;}; class wheel_1_1_Damper_Damage_BackAnim: wheel_1_1_Damper_Damage_BackAnim{offset1=-0.18000001;}; class wheel_1_2_Damper_Damage_BackAnim: wheel_1_2_Damper_Damage_BackAnim{offset1=-0.18000001;}; class wheel_2_1_Damper_Damage_BackAnim: wheel_2_1_Damper_Damage_BackAnim{offset1=-0.18000001;}; class wheel_2_2_Damper_Damage_BackAnim: wheel_2_2_Damper_Damage_BackAnim{offset1=-0.18000001;}; 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 Wheel_1_1_Damper: 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=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"; }; class MainTurret { type="rotationY"; source="mainTurret"; selection="mainTurret"; axis="mainTurret_Axis"; }; class MainGun { type="rotationX"; source="mainGun"; selection="mainGun"; axis="mainGun_Axis"; }; }; }; }; I have looked through the turret config properties wiki etc. While I think I have a grasp on the basic concepts, I am obviously pretty new to this, and still have much to learn. Please help point me in the right direction. Share this post Link to post Share on other sites
Lenyoga 326 Posted March 22, 2018 I'm in a bit of a turret experimentation/research/despair phase right now, too, I got up to two turrets to function. Here's the things that caught my eye: In CfgVehicles the MainTurret is just fine, the secondary turret needs specific, hardcoded animation sources: body = "mainTurret2"; gun = "mainGun2"; animationSourceBody = "mainTurret2"; animationSourceGun = "mainGun2"; I'm not 100% sure about the next one, but my two turrets only started working once I used the Czech names for skeletonBones[] in the Model.cfg: "otocVez", "", "otocHlaven", "otocVez", "otocVez2", "", "otocHlaven2", "otocVez2", In CfgModels - p3d Name - Animations you should also define the animations for both turrets like this (axis, selection and source probably being the hardcoded parameters) class MainTurret { type="rotationY"; source="mainTurret"; selection="otocVez"; axis="osaVeze"; animPeriod=0; minValue="rad -360"; maxValue="rad +360"; angle0="rad -360"; angle1="rad +360"; memory = 1; }; class MainGun: MainTurret { type="rotationX"; source="mainGun"; selection="otocHlaven"; axis="osaHlavne"; }; class MainTurret2 { type="rotationY"; source="mainTurret2"; selection="otocVez2"; axis="osaVeze2"; animPeriod=0; minValue="rad -360"; maxValue="rad +360"; angle0="rad -360"; angle1="rad +360"; memory = 1; }; class MainGun2: MainTurret2 { type="rotationX"; source="mainGun2"; selection="otocHlaven2"; axis="osaHlavne2"; }; And don't forget renaming the turret body (otocVez) and gun (otocHlaven) in the p3d file. Bit me in the behind a few times... Share this post Link to post Share on other sites
x3kj 1247 Posted March 23, 2018 @Lenyoga czech names are not required for this (i dont use them and it works with multiple turrets). Maybe you missed to change something. turret1 body="PrimaryTurret"; //defines the animation name to be used for the horizontally moving selection of the turret and must be a model.cfg's animation classname gun="PrimaryGun"; // animationSourceBody="tur1_trav_AnimSrc"; //defines anim source for model cfg animationSourceGun="tur1_elev_AnimSrc"; turretAxis="ax_tur1_trav"; //Axis selectionname in MemoryLOD (for the turret axis, ie mouse left and right input). gunAxis="ax_tur1_elev"; //Axis selectionname in MemoryLOD (for the gun axis, ie mouse up and down input). turretCom: turret1 body = "CommanderTurret"; gun = "CommanderGun"; turretAxis="ax_turC_trav"; gunAxis="ax_turC_elev"; animationSourceBody = "turC_trav_AnimSrc"; animationSourceGun = "turC_elev_AnimSrc"; skeleton "tur1_trav","", "tur1_elev","tur1_trav", "turC_trav","tur1_trav", "turC_elev","turC_trav", anim class PrimaryTurret { type="rotationY"; source="tur1_trav_AnimSrc"; selection="tur1_trav"; axis="ax_tur1_trav"; //may also be just a point animPeriod=0; minValue="rad -360"; maxValue="rad +360"; angle0="rad -360"; angle1="rad +360"; memory = 1; }; class PrimaryGun: PrimaryTurret { type="rotationX"; source="tur1_elev_AnimSrc"; selection="tur1_elev"; axis="ax_tur1_elev"; angle0="rad -360"; angle1="rad +360"; }; class CommanderTurret: PrimaryTurret { source="turC_trav_AnimSrc"; selection="turC_trav"; axis="ax_turC_trav"; }; class CommanderGun: PrimaryGun { source="turC_elev_AnimSrc"; selection="turC_elev"; axis="ax_turC_elev"; }; 1 Share this post Link to post Share on other sites