OFPEC Forum

Addons & Mods Depot => Arma2 - Configs & Scripting => Topic started by: Bebop182 on 04 May 2012, 16:47:58

Title: Animated Object troubles
Post by: Bebop182 on 04 May 2012, 16:47:58
Hi there,
For a custom mission ( soon to be released ;P ) purpose i had to create a new object, namely a "Coffre Fort" or a Safe. I had few trouble with texturing (UVmapping and stuff) but that's an other story. Now comes the time to make my model a real object for Arma 2...
The model is animated, the handle rotates and the door can be opened (no shit! =D). This part is working well in the Buldozer.
But in game, animations doesn't work for the resolution lod (but does for the geometry lod, the invisible door push away the player when the animation is triggered).

Thanks to this topic: http://www.ofpec.com/forum/index.php?topic=33184.0 (http://www.ofpec.com/forum/index.php?topic=33184.0)
i found out it was a inheritance matter. My safe was defined like this in the cpp:
Code: [Select]
class CfgVehicles {
class All;
class Thing;
class FoldTable; // External class reference

class coffre : FoldTable {...

Animation issues seems to be related to the attribute simulation="thing" from the Thing class. All animation works when simulation="house" is used instead... so what's the matter since i know how to solve this...? The problem is my Safe is not a HOUSE!

So i tried to write a new class Objets {}; which inherits from class All. But there are so much attributes that i can't get my model to work as it should.

So that's why i'm asking for help. I need to know what attributes matters in order to make an object work like an object. I'm actually studying Arma 2 classes.

Please help, it will make a great COOP 6 reach the release stage.

Config.cpp and model.cfg can be given on demand.

Thank you for reading this.

Long live the Banana King!

SOLVED
Title: Re: Animated Object troubles
Post by: h- on 04 May 2012, 20:06:42
It would be nice if you would actually post how you solved it, there might be others coming in with a similar/same problem.  ;)
Title: Re: Animated Object troubles
Post by: Bebop182 on 04 May 2012, 20:47:18
I did not solved it, i dropped the idea of creating a custom class "objets" from scratch.
I asked for informations about attributes of the class All in thiq topic. But it's too general, i won't get any answer this way. So i changed my method, i'll solve one problem after another.
And here is my first one: http://www.ofpec.com/forum/index.php?topic=36072.msg247611#msg247611 (http://www.ofpec.com/forum/index.php?topic=36072.msg247611#msg247611)