Jump to content

Sign in to follow this  
norsu

Problem with vehicle hatches

Recommended Posts

I've been trying to get hatches work properly but haven't been very successful so far. I'm using BIS' Stryker model.cfg as base for my vehicle as it has everything I need. Here's the config for hatches:

(I have left out most of the config to reduce message length)

  [b said:
Quote[/b] ]

class Rotation;

class CfgSkeletons

{

class amvSkeleton

{

isDiscrete=1;

skeletonInherit="";

skeletonBones[]=

{

...........

"hatch_driver",

"",

"hatch_gunner",

"",

};

};

};

class CfgModels

{

class Vehicle;

class amv: Vehicle

{

skeletonName="amvSkeleton";

sectionsInherit="Vehicle";

sections[]=

{

"Light_1_1",

"Light_1_2",

"Light_brake",

"Light_back",

"clan",

"clan_sign",

"zasleh",

"karoserie",

"vez",

"motor",

"palivo",

"zbran"

};

class Animations

{

.........

class HatchDriver: Rotation

{

source="hatchDriver";

selection="hatch_driver";

axis="hatch_driver_axis";

memory="false";

angle1="rad -20";

};

class HatchGunner: Rotation

{

source="hatchGunner";

selection="hatch_gunner";

axis="hatch_gunner_axis";

memory="false";

angle1="rad -110";

};

};

};

};

Error message I'm getting complains about missing type in HatchDriver and HatchGunner. Hatches are missing type="rotation" just like in Stryker's model.cfg but that doesn't work here for some reason. If I add the type it complains about missing angle0, once again this is missing from Stryker too. And if I add both type and angle0, the vehicle starts acting very oddly (turns slowly itself when static).

Share this post


Link to post
Share on other sites

After further testing I found out that BIS' Stryker has the same odd turning effect so I guess I just have to live with it. I added both type="rotation" and angle0 so it works for now.

Share this post


Link to post
Share on other sites

calling an external class like

rotation;

vehicle;

doesn't work in model.cfg. you need to find the original class from within the bis mlod models.

replace rotation; with:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class Rotation

{

type="rotation";

source = "";

selection = "";

axis = "";

maxValue = 1;

angle0 = 0;

angle1 = 1;

memory=1;

sourceAddress="clamp";

};

and vehicle; with:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class Default

{

sectionsInherit="";

sections[] = {};

skeletonName = "";

};

class Vehicle: Default

{

sections[] =

{

"cislo",

"grupa",

"side",

"sektor",

"clan",

"clan_sign",

"podsvit pristroju",

"poskozeni",

"L svetlo",

"P svetlo",

"zasleh"

};

};

Another thing to try is to put your axis points in the memory lod and set memory=1 in the animations. good luck!

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  

×