Αplion 1122 Posted March 16, 2011 (edited) Hi again ... as I said in a previous topic, I'm making a building (I know not a big deal :D ) .. This building has 2 doors and I'm trying to make them working ... so far one of them is working properly but the other one refuse to comply :) Wondering if someone can take a look in my model.cfg and config.cpp providing some help ... Thanks in advance. Model.cfg class CfgSkeletons { class Default { isDiscrete = 1; skeletonInherit = ""; skeletonBones[] = {}; }; class APLION_obj_skeleton : Default { isDiscrete=1; skeletonInherit=""; skeletonBones[]= { "door1","","door2" }; }; }; class CfgModels { class rotation; class Default { sectionsInherit=""; sections[]={}; skeleton=""; class Animations {}; }; class APLION_obj { sectionsInherit=""; sections[]= {}; skeletonName="APLION_obj_skeleton"; }; class build2 : APLION_obj { sectionsInherit="APLION_obj"; sections[]={}; class Animations { class door_button1 : Rotation { type="rotation"; source="user"; selection="door1"; axis="door_axis1"; memory = 1; sourceAddress = "clamp"; minValue = 0.0; maxValue = 1; angle0=0; angle1= -1.6; }; class door_button2 : Rotation { type="rotation"; source="user"; selection="door2"; axis="door_axis2"; memory = 1; sourceAddress = "clamp"; minValue = 0.0; maxValue = 1; angle0=0; angle1= 1.6; }; }; }; }; Config.cpp class CfgPatches { class APLION_Diorofo { units[] = {}; weapons[] = {}; requiredVersion = 1.0; requiredAddons[] = {}; }; }; class CfgVehicleClasses { class APLION_DiorofoVehicleClass { displayName = "Aplion Houses "; }; }; class CfgVehicles { class All; class HouseBase; class APLION_Base_Object : All { scope = 0; side = 3; icon = "iconStaticObject"; nameSound = "object"; simulation = "house"; picture = "pictureStaticObject"; model="APLION_buildings\Build1\build2.p3d"; sound = "Building"; placement = "vertical"; ladders[] = {}; vehicleClass = ""; displayName = ""; coefInside = 1; coefInsideHeur = 0.25; mapSize = 7.5; animated = true; armor = 200; destrType = "DestructBuilding"; damageResistance = 0.004; class DestructionEffects { class Sound { simulation = "sound"; type = "DestrHouse"; position = "destructionEffect1"; intensity = 1; interval = 1; lifeTime = 0.05; }; class DestroyPhase1 { simulation = "destroy"; type = "DelayedDestruction"; lifeTime = 2.5; position = ""; intensity = 1; interval = 1; }; class DamageAround1 { simulation = "damageAround"; type = "DamageAroundHouse"; position = ""; intensity = 1; interval = 1; lifeTime = 1; }; }; }; class APLION_Housebase : APLION_Base_Object { scope = 1; model = ""; icon = ""; displayName = ""; animated = true; vehicleClass = "APLION_DiorofoVehicleClass"; nameSound = "house"; accuracy = 0.2; typicalCargo[] = {}; transportAmmo = 0; transportRepair = 0; transportFuel = 0; mapSize = 11; cost = 0; armor = 800; /*extern*/ class DestructionEffects; }; class Land_build2: APLION_Housebase { model = "APLION_buildings\Build1\build2.p3d"; displayName = "Diorofo"; nameSound = ""; mapSize = 8; icon = "iconStaticObject"; accuracy = 1000; armor = 450; destrType = "DestructBuilding"; scope = 2; class DestructionEffects : DestructionEffects { }; class AnimationSources { class door_button1 { source = "user"; animPeriod = 1.5; initPhase = 0; }; class door_button2 { source = "user"; animPeriod = 1.5; initPhase = 0; }; }; class UserActions { class Open_door { displayName="Open Door"; onlyforplayer = true; position="door_button1"; radius=2; condition="this animationPhase ""door_button1"" < 0.5"; statement="this animate [""door_button1"", 1]"; }; class Close_Door : Open_door { displayName="Close Door"; condition="this animationPhase ""door_button1"" >= 0.5"; statement="this animate [""door_button1"", 0]"; }; class Open_door2 { displayName="Open Door"; onlyforplayer = true; position="door_button2"; radius=2; condition="this animationPhase ""door_button2"" < 0.5"; statement="this animate [""door_button2"", 1]"; }; class Close_Door2 : Open_door2 { displayName="Close Door"; condition="this animationPhase ""door_button2"" >= 0.5"; statement="this animate [""door_button2"", 0]"; }; }; }; }; Edited March 17, 2011 by Aplion Share this post Link to post Share on other sites
Αplion 1122 Posted March 18, 2011 Still need help if any ... Share this post Link to post Share on other sites
beton 2 Posted March 19, 2011 Maybe the problem is in your model? I always used the configs from the arma1 samplemodels... Otherwise ask PvPscene, he is the master of desaster when there is a question with the config. Share this post Link to post Share on other sites
[aps]gnat 28 Posted March 20, 2011 Does it animate in the Buldozer preview, using the mouse wheel? The model.cfg has to be in the project directory. Suspect this is your problem. TIP for ALL; Define your skeleton in PAIRS, its much easier to spot problems skeletonBones[]= { "door1","", "door2","" }; Share this post Link to post Share on other sites
Αplion 1122 Posted March 24, 2011 @Gnat ... no there is no animation in Buldozer preview also for this door ... only one door is animate even in Buldozer ... and yes the model.cfg is in the project directory. ---------- Post added at 10:37 AM ---------- Previous post was at 10:33 AM ---------- Update ... problem solved using Gnat tip above ... !!! Thanks a lot mate. Share this post Link to post Share on other sites