User Tools

Site Tools


arma2:modeling:user_animation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
arma2:modeling:user_animation [2011/06/30 18:10] – created user_animation initial page. snakemanarma2:modeling:user_animation [2024/08/01 22:06] (current) – links added. snakeman
Line 1: Line 1:
-====== User Animation Tutorial ======+====== ArmA 2 User Animation Tutorial ====== 
 + 
 +[[https://www.pmctactical.org/forum/viewforum.php?f=50|ArmA 2 Forum]], [[:arma2|ArmA 2 Home]], [[arma2:config|ArmA 2 Config]], [[arma2:file_formats|ArmA 2 File Formats]], [[arma2:missions|ArmA 2 Missions]], [[arma2:modeling|ArmA 2 3D Modeling]], [[arma2:scripting|ArmA 2 Scripting]], [[arma2:terrain|ArmA 2 Terrain]], [[arma2:texturing|ArmA 2 Texturing]], [[arma2:tools|ArmA 2 Tools]]
  
 Primary target - Vehicles Primary target - Vehicles
  
-This tutorial is to show the basics of how to animate a section of a vehicle model with a USER action. Specific subject pictures are a aeroplane ramp, but any vehicle can have similar.+This tutorial is to show the basics of how to animate a section of a vehicle model with a USER action. Specific subject pictures are a aircraft ramp, but any vehicle can have similar.
  
  
Line 134: Line 136:
  
 RADIUS is the radius in meters around the ACTION_RAMP1 points that players will see the action in menu. RADIUS is the radius in meters around the ACTION_RAMP1 points that players will see the action in menu.
 +
 +
 +====== House Door ======
 +
 +**model.cfg**:
 +<code cpp>
 +class cfgSkeletons
 +
 + class VTE_tigercage_Skeleton: Default
 + {
 + skeletonInherit = "Default";
 + skeletonBones[] =
 + {
 + "VTE_tg1_door", ""
 + };
 + };
 +
 +class CfgModels
 +
 + class VTE_tigercage: Default
 + {
 + skeletonName = "VTE_tigercage_Skeleton";
 + sections[] = {};
 +
 + class Animations
 + {
 + class vte_tigercage_door: Rotation
 + {
 + axis = "axis_door";
 + selection = "VTE_tg1_door";
 + };
 + };
 + };
 +</code>
 +
 +**config.cpp**:
 +<code cpp>
 + class AnimationSources
 + {
 + class vte_tigercage_door
 + {
 + animPeriod = 1;
 + };
 + };
 +
 + class UserActions
 + {
 + class OpenTigerCage_door
 + {
 + displayName = "Open Door";
 + position = "VTE_tg1_door";
 + radius = 4;
 + OnlyForPlayer = true;
 + condition = "this animationPhase ""vte_tigercage_door"" < 0.5";
 + statement = "this animate [""vte_tigercage_door"", 1];";
 + };
 +
 + class CloseTigerCage_door: OpenTigerCage_door
 + {
 + displayName = "Close Door";
 + condition = "this animationPhase ""vte_tigercage_door"" >= 0.5";
 + statement = "this animate [""vte_tigercage_door"", 0];";
 + };
 + };
 +</code>
 +
 +**Summary**
 +
 +VTE_tg1_door is the selection in Resolution LOD.
 +
 +axis_door is the memory point in Memory LOD.
 +
 +**Note about Geometry LOD**
 +
 +When you animate a door, in Geometry LOD it has to have ComponentXX and also the selection name like in our above example VTE_tg1_door, otherwise when you open the door it wont let you pass as geometry doesn't recognize anything happening.
 +
arma2/modeling/user_animation.1309457452.txt.gz · Last modified: 2011/06/30 18:10 by snakeman