OFPEC Forum

Addons & Mods Depot => OFP - Addons & Mods General => Topic started by: Eagles Talon on 04 Mar 2003, 08:07:12

Title: how do u make a door on a addon open
Post by: Eagles Talon on 04 Mar 2003, 08:07:12
name says it all, i know i have 2 do something with the memory lod, but i don't know what, and i don't know how to impliment it in the config.cpp??? thanks
Title: Re:how do u make a door on a addon open
Post by: SFG on 04 Mar 2003, 21:44:17
class Animations
               {
                       class gate
                       {
                               type="rotation";
                               animPeriod=1
                               selection="gate";
                               axis="osa_gate";
                               angle0=0
                               angle1=-1.600000;
                       };
               };
               class UserActions
               {
                       class OpenDoors
                       {
                               displayName="$STR_DN_OUT_O_DOOR";
                               position="osa_gate";
                               radius=2.500000;
                               condition="this animationPhase ""gate"" < 0.5";
                               statement="this animate [""gate"", 1]";
                       };
                       class CloseDoors
                       {
                               displayName="$STR_DN_OUT_C_DOOR";
                               position="osa_gate";
                               radius=2.500000;
                               condition="this animationPhase ""gate"" >= 0.5";
                               statement="this animate [""gate"", 0]";
                       };
               };
};

"gate" is the name of the door you want to move...

"osa_gate" is the name of the pivot (memory points)...
Title: Re:how do u make a door on a addon open
Post by: Eagles Talon on 05 Mar 2003, 19:22:21
thx a bunch ;D
Title: Re:how do u make a door on a addon open
Post by: SpclFrcsSnpr on 10 Mar 2003, 03:22:31
Is there anyway to change how much  it rotates cause I'm amking a c130 and when it rotates it turns the back ramp into the ground.
Title: Re:how do u make a door on a addon open
Post by: Wires on 10 Mar 2003, 04:50:02
how far the selection rotates has to do with the angle1 it is all explained pretty well by Col. Klink at his site: http://www.dc3d.co.nz/tutorials/index.htm

Great site with a number of tutes that will help you out  ;)
Title: Re:how do u make a door on a addon open
Post by: SpclFrcsSnpr on 10 Mar 2003, 05:53:48
Well thanks anyway but i started to play around with a couple of the little parts and I got it to work so thanks.