Jump to content
Sign in to follow this  
granQ

CfgModel for ArmA

Recommended Posts

A basic tank,car would be great.

Got my stuff ingame, but they not behaving correctly..

Share this post


Link to post
Share on other sites

download vilas pack and upbo it. he retextured some tanks so you can look at the config there.

Share this post


Link to post
Share on other sites

downloaded two packs from him but none of them contained a cfg model.

Now, the wheels are rotating like they should, but not turning when I turn..

Current config parts:

Same but easier to read

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

{

class Car; //Declare base class.

class my_Car: Car

{

sectionsInherit = "Car";

sections[] ={"section1","brzdove svetlo","levy predni","pravy predni","pravy zadni","levy zadni","L svetlo", "P svetlo","clan"};

skeletonName = "Car";

class Animations

{

class my_CarFrontWheelR

{

type = "rotationX";

source = "wheel";

selection = "wheel";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class my_CarFrontWheelL

{

type = "rotationX";

source = "wheel";

selection = "wheel";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class my_CarRearWheelR

{

type = "rotationX";

source = "wheel";

selection = "pravy zadni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class my_CarRearWheelL

{

type = "rotationX";

source = "wheel";

selection = "levy zadni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

};

};

};

Share this post


Link to post
Share on other sites

OKey, double post but anyway.

its working. thanks for the help everyone, here is some working code for anyone that comes after me looking for the same thing.

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

{

class Car; //Declare base class.

class RC_ExempelCar: Car

{

sectionsInherit = "";

sections[] ={"section1","brzdove svetlo","levy predni","pravy predni","pravy zadni","levy zadni","L svetlo", "P svetlo","clan"};

skeletonName = "Car";

class Animations

{

class RC_ExempelCarFrontWheelR

{

type = "rotationX";

source = "wheel";

selection = "pravy predni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class RC_ExempelCarFrontWheelL

{

type = "rotationX";

source = "wheel";

selection = "levy predni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class RC_ExempelCarFrontWheelRTurn

{

type = "rotationY";

source = "drivingWheel";

selection = "pravy predni";

axis = "";

memory = true;

sourceAddress = "clamp";

minValue = -1;

maxValue = 1;

angle0 = "rad 25";

angle1 = "rad -25";

};

class RC_ExempelCarFrontWheelLTurn

{

type = "rotationY";

source = "drivingWheel";

selection = "levy predni";

axis = "";

memory = true;

sourceAddress = "clamp";

minValue = -1;

maxValue = 1;

angle0 = "rad 25";

angle1 = "rad -25";

};

class RC_ExempelCarRearWheelR

{

type = "rotationX";

source = "wheel";

selection = "pravy zadni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class RC_ExempelCarRearWheelL

{

type = "rotationX";

source = "wheel";

selection = "levy zadni";

axis = "";

memory = true;

sourceAddress = "loop";

minValue = 0;

maxValue = 1;

angle0 = 0;

angle1 = "rad -360";

};

class RC_ExempelCarDrivingWheel

{

type = "rotationZ";

source = "drivingWheel";

selection = "volant";

axis = "osavolantkon";

memory = true;

sourceAddress = "mirror";

minValue = -1;

maxValue = 1;

angle0 = "rad -35";

angle1 = "rad 35";

};

};

};

};

Share this post


Link to post
Share on other sites
Oh sorry, I was thinking CfgVehicles.

no problem, atleast you tired to help.

Personaly i feel the cfgmodels is the tricky part, cfgvehicles stuff is basicly same as in OFP.

Share this post


Link to post
Share on other sites

I'm currently creating a tutorial in the Biki, if you want some information right now, check my Sandbox.

Share this post


Link to post
Share on other sites
I'm currently creating a tutorial in the Biki, if you want some information right now, check my Sandbox.

Bump it and say recommend yay.gif

Really great stuff there, working with the bones now, see if i got it right smile_o.gif

Share this post


Link to post
Share on other sites

Lol so sorry , just to fix a typo (must be how you spell in your native language)

example is the english way of spelling Exempel

Share this post


Link to post
Share on other sites
Lol so sorry , just to fix a typo (must be how you spell in your native language)

example is the english way of spelling Exempel

well, in german it is:

exempel

In swedish it is:

exempel

in english it is:

Exemple

So I think it makes more sense for english to adapt.. wink_o.gif

Anyway, alot of thanks for this tutorial, I just read the model config and thought there was no way we could do anything without binarize. Tonight I got a "midsteering" vehicle working. But no idea whats the english name is for it..

Like the volvo dumper

Share this post


Link to post
Share on other sites

Having understood the new animation system it's pretty easy to use actually, and pretty flexible, too.

Thanks for your comments, feel free to make suggestions.

I'll also add a few example configs for choppers (including a turret) as well as a wheeled vehicles.

Share this post


Link to post
Share on other sites

Good to see some experts are looking into this and get themself familiar with the new code (regarding animations). Interesting tutorial, keep it up.

Little request (if allowed and not meant to jack the topic here), but what about building animations-tutorial? I wasn't a very good cfg editor in the past, but simple animations (like doors etc) worked. Now with ArmA i can't seam to get them to work.

I browsed all the ArmA cfg's, but didn't found much usefull info. Looks like BIS doors are somehow hardcoded (AnimationSource, if i'm not mistaken). Unless i overlooked something...

Anyway, i was able to get the icons and user actions (actions worked..open-close door) but animation part didn't.

Share this post


Link to post
Share on other sites

@"hardcoded": As BI told us on last year's workshop, the model config files are "attached" to the model during binarisation, the CfgModels usually is not in the main config. So as long as we can't de-binarise the new p3d format, there's no way to "look something up"... beside in the biki article. smile_o.gif

Share this post


Link to post
Share on other sites

actually i think it would be working. Got wheels turning, turrets rotating. To get a door open shouldnt be a problem.

Kinda stoped explorering ArmA right now, waiting for some project to do, mission to play.. or a computer that makes it all possible (got a slow cpu..)

But doors shouldnt be a problem at all.

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  

×