Leopard20/Sandbox – User
mNo edit summary |
Lou Montana (talk | contribs) (Remove WIP) |
||
(2 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
[[Category:Sandbox]] | |||
This page explains how to make an animation for {{arma3}} using Blender. | This page explains how to make an animation for {{arma3}} using Blender. | ||
== Prerequisites == | == Prerequisites == | ||
* Blender | * Blender | ||
* Basic knowledge of Blender or similar modeling tools | * Basic knowledge of Blender or similar modeling tools | ||
* Basic knowledge of configs and how they work | * Basic knowledge of configs and how they work | ||
* A text editor, such as Notepad++ or Visual Studio Code | * A text editor, such as Notepad++ or Visual Studio Code | ||
== Requirements == | == Requirements == | ||
=== Blender === | === Blender === | ||
A version compatible with Arma Toolbox (see below) should be used. As of writing this article, the latest version of Blender ( | |||
A version compatible with Arma Toolbox (see below) should be used. As of writing this article, the latest version of Blender (v3.0) is compatible with the latest version of Arma Toolbox. | |||
=== Arma Toolbox for Blender === | === Arma Toolbox for Blender === | ||
Download the latest version of | |||
Download the latest version of {{Link|https://github.com/AlwarrenSidh/ArmAToolbox|Alwarren's Arma Toolbox for Blender}}. | |||
If the master branch is noticeably newer than the latest release, download the contents of the master branch, and zip the ArmaToolbox folder.<br> | |||
Next, go to Blender -> Preferences -> Add-Ons -> Install, and provide the path to the zip file to install Arma Toolbox. | Next, go to Blender -> Preferences -> Add-Ons -> Install, and provide the path to the zip file to install Arma Toolbox. | ||
=== | === Character rig === | ||
For simplicity, [https://forums.bohemia.net/forums/topic/161228-armarig-for-blender/ Mascer's ArmaRig for Blender] will be used in this tutorial. | For simplicity, [https://forums.bohemia.net/forums/topic/161228-armarig-for-blender/ Mascer's ArmaRig for Blender] will be used in this tutorial. | ||
=== Model.cfg === | === Model.cfg === | ||
A model.cfg file specifies the skeleton properties of the model.<br> | A model.cfg file specifies the skeleton properties of the model.<br> | ||
The following example config can be used for Arma 2/3 characters.<br> | The following example config can be used for Arma 2/3 characters.<br> | ||
Line 32: | Line 42: | ||
skeletonBones[] = {}; | skeletonBones[] = {}; | ||
}; | }; | ||
// The skeleton name. This will later be referenced in config.cpp file for the animation. | |||
class OFP2_ManSkeleton | class OFP2_ManSkeleton | ||
{ | { | ||
Line 39: | Line 50: | ||
skeletonBones[] = | skeletonBones[] = | ||
{ | { | ||
// pairs of boneName, parentBone | |||
"Pelvis","", | "Pelvis", "", | ||
"Spine","Pelvis", | "Spine", "Pelvis", | ||
"Spine1","Spine", | "Spine1", "Spine", | ||
"Spine2","Spine1", | "Spine2", "Spine1", | ||
"Spine3","Spine2", | "Spine3", "Spine2", | ||
"Camera","Pelvis", | "Camera", "Pelvis", | ||
"weapon","Spine1", | "weapon", "Spine1", | ||
"launcher","Spine1", | "launcher", "Spine1", | ||
// Head skeleton in hierarchy | // Head skeleton in hierarchy | ||
"neck","Spine3", | "neck", "Spine3", | ||
"neck1","neck", | "neck1", "neck", | ||
"head","neck1", | "head", "neck1", | ||
// New facial features | // New facial features | ||
"Face_Hub","head", | "Face_Hub", "head", | ||
"Face_Jawbone","Face_Hub", | "Face_Jawbone", "Face_Hub", | ||
"Face_Jowl","Face_Jawbone", | "Face_Jowl", "Face_Jawbone", | ||
"Face_chopRight","Face_Jawbone", | "Face_chopRight", "Face_Jawbone", | ||
"Face_chopLeft","Face_Jawbone", | "Face_chopLeft", "Face_Jawbone", | ||
"Face_LipLowerMiddle","Face_Jawbone", | "Face_LipLowerMiddle", "Face_Jawbone", | ||
"Face_LipLowerLeft","Face_Jawbone", | "Face_LipLowerLeft", "Face_Jawbone", | ||
"Face_LipLowerRight","Face_Jawbone", | "Face_LipLowerRight", "Face_Jawbone", | ||
"Face_Chin","Face_Jawbone", | "Face_Chin", "Face_Jawbone", | ||
"Face_Tongue","Face_Jawbone", | "Face_Tongue", "Face_Jawbone", | ||
"Face_CornerRight","Face_Hub", | "Face_CornerRight", "Face_Hub", | ||
"Face_CheekSideRight","Face_CornerRight", | "Face_CheekSideRight", "Face_CornerRight", | ||
"Face_CornerLeft","Face_Hub", | "Face_CornerLeft", "Face_Hub", | ||
"Face_CheekSideLeft","Face_CornerLeft", | "Face_CheekSideLeft", "Face_CornerLeft", | ||
"Face_CheekFrontRight","Face_Hub", | "Face_CheekFrontRight", "Face_Hub", | ||
"Face_CheekFrontLeft","Face_Hub", | "Face_CheekFrontLeft", "Face_Hub", | ||
"Face_CheekUpperRight","Face_Hub", | "Face_CheekUpperRight", "Face_Hub", | ||
"Face_CheekUpperLeft","Face_Hub", | "Face_CheekUpperLeft", "Face_Hub", | ||
"Face_LipUpperMiddle","Face_Hub", | "Face_LipUpperMiddle", "Face_Hub", | ||
"Face_LipUpperRight","Face_Hub", | "Face_LipUpperRight", "Face_Hub", | ||
"Face_LipUpperLeft","Face_Hub", | "Face_LipUpperLeft", "Face_Hub", | ||
"Face_NostrilRight","Face_Hub", | "Face_NostrilRight", "Face_Hub", | ||
"Face_NostrilLeft","Face_Hub", | "Face_NostrilLeft", "Face_Hub", | ||
"Face_Forehead","Face_Hub", | "Face_Forehead", "Face_Hub", | ||
"Face_BrowFrontRight","Face_Forehead", | "Face_BrowFrontRight", "Face_Forehead", | ||
"Face_BrowFrontLeft","Face_Forehead", | "Face_BrowFrontLeft", "Face_Forehead", | ||
"Face_BrowMiddle","Face_Forehead", | "Face_BrowMiddle", "Face_Forehead", | ||
"Face_BrowSideRight","Face_Forehead", | "Face_BrowSideRight", "Face_Forehead", | ||
"Face_BrowSideLeft","Face_Forehead", | "Face_BrowSideLeft", "Face_Forehead", | ||
"Face_Eyelids","Face_Hub", | "Face_Eyelids", "Face_Hub", | ||
"Face_EyelidUpperRight","Face_Hub", | "Face_EyelidUpperRight", "Face_Hub", | ||
"Face_EyelidUpperLeft","Face_Hub", | "Face_EyelidUpperLeft", "Face_Hub", | ||
"Face_EyelidLowerRight","Face_Hub", | "Face_EyelidLowerRight", "Face_Hub", | ||
"Face_EyelidLowerLeft","Face_Hub", | "Face_EyelidLowerLeft", "Face_Hub", | ||
"EyeLeft","Face_Hub", | "EyeLeft", "Face_Hub", | ||
"EyeRight","Face_Hub", | "EyeRight", "Face_Hub", | ||
// Left upper side | // Left upper side | ||
"LeftShoulder","Spine3", | "LeftShoulder", "Spine3", | ||
"LeftArm","LeftShoulder", | "LeftArm", "LeftShoulder", | ||
"LeftArmRoll","LeftArm", | "LeftArmRoll", "LeftArm", | ||
"LeftForeArm","LeftArmRoll", | "LeftForeArm", "LeftArmRoll", | ||
"LeftForeArmRoll","LeftForeArm", | "LeftForeArmRoll", "LeftForeArm", | ||
"LeftHand","LeftForeArmRoll", | "LeftHand", "LeftForeArmRoll", | ||
"LeftHandRing","LeftHand", | "LeftHandRing", "LeftHand", | ||
"LeftHandRing1","LeftHandRing", | "LeftHandRing1", "LeftHandRing", | ||
"LeftHandRing2","LeftHandRing1", | "LeftHandRing2", "LeftHandRing1", | ||
"LeftHandRing3","LeftHandRing2", | "LeftHandRing3", "LeftHandRing2", | ||
"LeftHandPinky1","LeftHandRing", | "LeftHandPinky1", "LeftHandRing", | ||
"LeftHandPinky2","LeftHandPinky1", | "LeftHandPinky2", "LeftHandPinky1", | ||
"LeftHandPinky3","LeftHandPinky2", | "LeftHandPinky3", "LeftHandPinky2", | ||
"LeftHandMiddle1","LeftHand", | "LeftHandMiddle1", "LeftHand", | ||
"LeftHandMiddle2","LeftHandMiddle1", | "LeftHandMiddle2", "LeftHandMiddle1", | ||
"LeftHandMiddle3","LeftHandMiddle2", | "LeftHandMiddle3", "LeftHandMiddle2", | ||
"LeftHandIndex1","LeftHand", | "LeftHandIndex1", "LeftHand", | ||
"LeftHandIndex2","LeftHandIndex1", | "LeftHandIndex2", "LeftHandIndex1", | ||
"LeftHandIndex3","LeftHandIndex2", | "LeftHandIndex3", "LeftHandIndex2", | ||
"LeftHandThumb1","LeftHand", | "LeftHandThumb1", "LeftHand", | ||
"LeftHandThumb2","LeftHandThumb1", | "LeftHandThumb2", "LeftHandThumb1", | ||
"LeftHandThumb3","LeftHandThumb2", | "LeftHandThumb3", "LeftHandThumb2", | ||
// Right upper side | // Right upper side | ||
"RightShoulder","Spine3", | "RightShoulder", "Spine3", | ||
"RightArm","RightShoulder", | "RightArm", "RightShoulder", | ||
"RightArmRoll","RightArm", | "RightArmRoll", "RightArm", | ||
"RightForeArm","RightArmRoll", | "RightForeArm", "RightArmRoll", | ||
"RightForeArmRoll","RightForeArm", | "RightForeArmRoll", "RightForeArm", | ||
"RightHand","RightForeArmRoll", | "RightHand", "RightForeArmRoll", | ||
"RightHandRing","RightHand", | "RightHandRing", "RightHand", | ||
"RightHandRing1","RightHandRing", | "RightHandRing1", "RightHandRing", | ||
"RightHandRing2","RightHandRing1", | "RightHandRing2", "RightHandRing1", | ||
"RightHandRing3","RightHandRing2", | "RightHandRing3", "RightHandRing2", | ||
"RightHandPinky1","RightHandRing", | "RightHandPinky1", "RightHandRing", | ||
"RightHandPinky2","RightHandPinky1", | "RightHandPinky2", "RightHandPinky1", | ||
"RightHandPinky3","RightHandPinky2", | "RightHandPinky3", "RightHandPinky2", | ||
"RightHandMiddle1","RightHand", | "RightHandMiddle1", "RightHand", | ||
"RightHandMiddle2","RightHandMiddle1", | "RightHandMiddle2", "RightHandMiddle1", | ||
"RightHandMiddle3","RightHandMiddle2", | "RightHandMiddle3", "RightHandMiddle2", | ||
"RightHandIndex1","RightHand", | "RightHandIndex1", "RightHand", | ||
"RightHandIndex2","RightHandIndex1", | "RightHandIndex2", "RightHandIndex1", | ||
"RightHandIndex3","RightHandIndex2", | "RightHandIndex3", "RightHandIndex2", | ||
"RightHandThumb1","RightHand", | "RightHandThumb1", "RightHand", | ||
"RightHandThumb2","RightHandThumb1", | "RightHandThumb2", "RightHandThumb1", | ||
"RightHandThumb3","RightHandThumb2", | "RightHandThumb3", "RightHandThumb2", | ||
// Left lower side | // Left lower side | ||
"LeftUpLeg","Pelvis", | "LeftUpLeg", "Pelvis", | ||
"LeftUpLegRoll","LeftUpLeg", | "LeftUpLegRoll", "LeftUpLeg", | ||
"LeftLeg","LeftUpLegRoll", | "LeftLeg", "LeftUpLegRoll", | ||
"LeftLegRoll","LeftLeg", | "LeftLegRoll", "LeftLeg", | ||
"LeftFoot","LeftLegRoll", | "LeftFoot", "LeftLegRoll", | ||
"LeftToeBase","LeftFoot", | "LeftToeBase", "LeftFoot", | ||
// Right lower side | // Right lower side | ||
"RightUpLeg","Pelvis", | "RightUpLeg", "Pelvis", | ||
"RightUpLegRoll","RightUpLeg", | "RightUpLegRoll", "RightUpLeg", | ||
"RightLeg","RightUpLegRoll", | "RightLeg", "RightUpLegRoll", | ||
"RightLegRoll","RightLeg", | "RightLegRoll", "RightLeg", | ||
"RightFoot","RightLegRoll", | "RightFoot", "RightLegRoll", | ||
"RightToeBase","RightFoot" | "RightToeBase", "RightFoot" | ||
}; | }; | ||
// location of pivot points (local axes) for hierarchical animation | // location of pivot points (local axes) for hierarchical animation | ||
pivotsModel="A3\anims_f\data\skeleton\SkeletonPivots.p3d"; | pivotsModel="A3\anims_f\data\skeleton\SkeletonPivots.p3d"; | ||
Line 165: | Line 177: | ||
class Default | class Default | ||
{ | { | ||
sectionsInherit=""; | sectionsInherit = ""; | ||
sections[] = {}; | sections[] = {}; | ||
skeletonName = ""; | skeletonName = ""; | ||
Line 172: | Line 184: | ||
class ArmaMan: Default | class ArmaMan: Default | ||
{ | { | ||
htMin = 60; | htMin = 60; // Minimum half-cooling time (in seconds) | ||
htMax = 1800; | htMax = 1800; // Maximum half-cooling time (in seconds) | ||
afMax = 30; | afMax = 30; // Maximum temperature in case the model is alive (in celsius) | ||
mfMax = 0; | mfMax = 0; // Maximum temperature when the model is moving (in celsius) | ||
mFact = 1; | mFact = 1; // Metabolism factor - number from interval <0, 1> (0 - metabolism has no influence, 1 - metabolism has full influence (no other temperature source will be considered)). | ||
tBody = 37; | tBody = 37; // Metabolism temperature of the model (in celsius) | ||
sections[] = | sections[] = | ||
{ | { | ||
"osobnost","Head_Injury","Body_Injury","l_leg_injury","l_arm_injury","r_arm_injury","r_leg_injury", "injury_body", "injury_legs", "injury_hands", | "osobnost", "Head_Injury", "Body_Injury", "l_leg_injury", "l_arm_injury", "r_arm_injury", "r_leg_injury", "injury_body", "injury_legs", "injury_hands", | ||
"clan","clan_sign","Camo","CamoB","Camo1","Camo2","personality","hl", "injury_head", "insignia", "ghillie_hide" | "clan", "clan_sign", "Camo", "CamoB", "Camo1", "Camo2", "personality", "hl", "injury_head", "insignia", "ghillie_hide" | ||
}; | }; | ||
skeletonName = "OFP2_ManSkeleton"; | skeletonName = "OFP2_ManSkeleton"; | ||
}; | }; | ||
Line 190: | Line 203: | ||
</spoiler> | </spoiler> | ||
=== | === pboProject === | ||
To properly binarize the .rtm file, Mikero's Tools is recommended. The free version is sufficient for this tutorial. | |||
To properly binarize the .rtm file, pboProject from Mikero's Tools is recommended. The free version is sufficient for this tutorial. |
Latest revision as of 16:34, 15 November 2023
This page explains how to make an animation for Arma 3 using Blender.
Prerequisites
- Blender
- Basic knowledge of Blender or similar modeling tools
- Basic knowledge of configs and how they work
- A text editor, such as Notepad++ or Visual Studio Code
Requirements
Blender
A version compatible with Arma Toolbox (see below) should be used. As of writing this article, the latest version of Blender (v3.0) is compatible with the latest version of Arma Toolbox.
Arma Toolbox for Blender
Download the latest version of Alwarren's Arma Toolbox for Blender.
If the master branch is noticeably newer than the latest release, download the contents of the master branch, and zip the ArmaToolbox folder.
Next, go to Blender -> Preferences -> Add-Ons -> Install, and provide the path to the zip file to install Arma Toolbox.
Character rig
For simplicity, Mascer's ArmaRig for Blender will be used in this tutorial.
Model.cfg
A model.cfg file specifies the skeleton properties of the model.
The following example config can be used for Arma 2/3 characters.
class CfgSkeletons
{
class Default
{
isDiscrete = 1;
skeletonInherit = "";
skeletonBones[] = {};
};
// The skeleton name. This will later be referenced in config.cpp file for the animation.
class OFP2_ManSkeleton
{
isDiscrete = 0;
skeletonInherit = "";
skeletonBones[] =
{
// pairs of boneName, parentBone
"Pelvis", "",
"Spine", "Pelvis",
"Spine1", "Spine",
"Spine2", "Spine1",
"Spine3", "Spine2",
"Camera", "Pelvis",
"weapon", "Spine1",
"launcher", "Spine1",
// Head skeleton in hierarchy
"neck", "Spine3",
"neck1", "neck",
"head", "neck1",
// New facial features
"Face_Hub", "head",
"Face_Jawbone", "Face_Hub",
"Face_Jowl", "Face_Jawbone",
"Face_chopRight", "Face_Jawbone",
"Face_chopLeft", "Face_Jawbone",
"Face_LipLowerMiddle", "Face_Jawbone",
"Face_LipLowerLeft", "Face_Jawbone",
"Face_LipLowerRight", "Face_Jawbone",
"Face_Chin", "Face_Jawbone",
"Face_Tongue", "Face_Jawbone",
"Face_CornerRight", "Face_Hub",
"Face_CheekSideRight", "Face_CornerRight",
"Face_CornerLeft", "Face_Hub",
"Face_CheekSideLeft", "Face_CornerLeft",
"Face_CheekFrontRight", "Face_Hub",
"Face_CheekFrontLeft", "Face_Hub",
"Face_CheekUpperRight", "Face_Hub",
"Face_CheekUpperLeft", "Face_Hub",
"Face_LipUpperMiddle", "Face_Hub",
"Face_LipUpperRight", "Face_Hub",
"Face_LipUpperLeft", "Face_Hub",
"Face_NostrilRight", "Face_Hub",
"Face_NostrilLeft", "Face_Hub",
"Face_Forehead", "Face_Hub",
"Face_BrowFrontRight", "Face_Forehead",
"Face_BrowFrontLeft", "Face_Forehead",
"Face_BrowMiddle", "Face_Forehead",
"Face_BrowSideRight", "Face_Forehead",
"Face_BrowSideLeft", "Face_Forehead",
"Face_Eyelids", "Face_Hub",
"Face_EyelidUpperRight", "Face_Hub",
"Face_EyelidUpperLeft", "Face_Hub",
"Face_EyelidLowerRight", "Face_Hub",
"Face_EyelidLowerLeft", "Face_Hub",
"EyeLeft", "Face_Hub",
"EyeRight", "Face_Hub",
// Left upper side
"LeftShoulder", "Spine3",
"LeftArm", "LeftShoulder",
"LeftArmRoll", "LeftArm",
"LeftForeArm", "LeftArmRoll",
"LeftForeArmRoll", "LeftForeArm",
"LeftHand", "LeftForeArmRoll",
"LeftHandRing", "LeftHand",
"LeftHandRing1", "LeftHandRing",
"LeftHandRing2", "LeftHandRing1",
"LeftHandRing3", "LeftHandRing2",
"LeftHandPinky1", "LeftHandRing",
"LeftHandPinky2", "LeftHandPinky1",
"LeftHandPinky3", "LeftHandPinky2",
"LeftHandMiddle1", "LeftHand",
"LeftHandMiddle2", "LeftHandMiddle1",
"LeftHandMiddle3", "LeftHandMiddle2",
"LeftHandIndex1", "LeftHand",
"LeftHandIndex2", "LeftHandIndex1",
"LeftHandIndex3", "LeftHandIndex2",
"LeftHandThumb1", "LeftHand",
"LeftHandThumb2", "LeftHandThumb1",
"LeftHandThumb3", "LeftHandThumb2",
// Right upper side
"RightShoulder", "Spine3",
"RightArm", "RightShoulder",
"RightArmRoll", "RightArm",
"RightForeArm", "RightArmRoll",
"RightForeArmRoll", "RightForeArm",
"RightHand", "RightForeArmRoll",
"RightHandRing", "RightHand",
"RightHandRing1", "RightHandRing",
"RightHandRing2", "RightHandRing1",
"RightHandRing3", "RightHandRing2",
"RightHandPinky1", "RightHandRing",
"RightHandPinky2", "RightHandPinky1",
"RightHandPinky3", "RightHandPinky2",
"RightHandMiddle1", "RightHand",
"RightHandMiddle2", "RightHandMiddle1",
"RightHandMiddle3", "RightHandMiddle2",
"RightHandIndex1", "RightHand",
"RightHandIndex2", "RightHandIndex1",
"RightHandIndex3", "RightHandIndex2",
"RightHandThumb1", "RightHand",
"RightHandThumb2", "RightHandThumb1",
"RightHandThumb3", "RightHandThumb2",
// Left lower side
"LeftUpLeg", "Pelvis",
"LeftUpLegRoll", "LeftUpLeg",
"LeftLeg", "LeftUpLegRoll",
"LeftLegRoll", "LeftLeg",
"LeftFoot", "LeftLegRoll",
"LeftToeBase", "LeftFoot",
// Right lower side
"RightUpLeg", "Pelvis",
"RightUpLegRoll", "RightUpLeg",
"RightLeg", "RightUpLegRoll",
"RightLegRoll", "RightLeg",
"RightFoot", "RightLegRoll",
"RightToeBase", "RightFoot"
};
// location of pivot points (local axes) for hierarchical animation
pivotsModel="A3\anims_f\data\skeleton\SkeletonPivots.p3d";
};
};
class CfgModels
{
class Default
{
sectionsInherit = "";
sections[] = {};
skeletonName = "";
};
class ArmaMan: Default
{
htMin = 60; // Minimum half-cooling time (in seconds)
htMax = 1800; // Maximum half-cooling time (in seconds)
afMax = 30; // Maximum temperature in case the model is alive (in celsius)
mfMax = 0; // Maximum temperature when the model is moving (in celsius)
mFact = 1; // Metabolism factor - number from interval <0, 1> (0 - metabolism has no influence, 1 - metabolism has full influence (no other temperature source will be considered)).
tBody = 37; // Metabolism temperature of the model (in celsius)
sections[] =
{
"osobnost", "Head_Injury", "Body_Injury", "l_leg_injury", "l_arm_injury", "r_arm_injury", "r_leg_injury", "injury_body", "injury_legs", "injury_hands",
"clan", "clan_sign", "Camo", "CamoB", "Camo1", "Camo2", "personality", "hl", "injury_head", "insignia", "ghillie_hide"
};
skeletonName = "OFP2_ManSkeleton";
};
};
pboProject
To properly binarize the .rtm file, pboProject from Mikero's Tools is recommended. The free version is sufficient for this tutorial.