Jump to content
NapalmTheCommies

Headgear floating inbetween legs

Recommended Posts

Hello, 

I am new to all of this.

 

(Here is a link to a Schreenshot of the problem)

https://i.imgur.com/iUzyX3S.jpeg

 

I tried to make a mod that adds kilgores hat from Apocalypse now.

Every time I try it the hat is in between the legs of the player. 

I did try it with the sample headgear example from Arma 3 Samples instead of my 3d model, but it still was floating in between the legs.

Could it be a problem with the config file?

 

And also the golden parts change to blue for no appearant reason.

(Don't know what's up with that)

 

Thank you for reading.

 

 

Share this post


Link to post
Share on other sites

The problem could be caused by two things:

1) You have not implemented a model.cfg correctly. If you use the ArmA3 Samples character's model.cfg as a base (pasted below for convenience), you'll just need to add your model to it, save it as a file called model.cfg and place it in your PBO in the same place as your model.

class CfgSkeletons
{
	class Default
	{
		isDiscrete = 1;
		skeletonInherit = "";
		skeletonBones[] = {};
	};
	class OFP2_ManSkeleton
	{
		isDiscrete = 0;
		skeletonInherit = "";
		skeletonBones[] =
		{
			"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";
	};

	class A3_headgear_example: ArmaMan{};
	class A3_headgear_NVGslot: ArmaMan{};
	class A3_character_example: ArmaMan{};
	class A3_vest_example: ArmaMan{};
  	class YOUR_MODEL_NAME_WITHOUT_P3D_EXTENSION: ArmaMan{};
};

or,

2) You haven't properly assigned named selections to your model. With it just being a hat model the only selection you should need to assign to the entire hat is 'head'

Share this post


Link to post
Share on other sites
3 hours ago, Jackal326 said:

The problem could be caused by two things:

1) You have not implemented a model.cfg correctly. If you use the ArmA3 Samples character's model.cfg as a base (pasted below for convenience), you'll just need to add your model to it, save it as a file called model.cfg and place it in your PBO in the same place as your model.

or,

2) You haven't properly assigned named selections to your model. With it just being a hat model the only selection you should need to assign to the entire hat is 'head'

 

 

Hello and thank you, you have helped me a lot.

Can you help me with one last thing?

 

The bits that are supposed to be golden for some reason are blue and I don't know why.

If you have any guess what went wrong here, please enlighten me.

(I have not yet added any materials)

THSWdAv.jpeg

Share this post


Link to post
Share on other sites
2 hours ago, NapalmTheCommies said:

 

 

Hello and thank you, you have helped me a lot.

[...]

(I have not yet added any materials)

You're welcome, and the gold becoming blue is probably due to a lack of rvmat (materials) so when you assign rvmats, it might fix the issue.

Share this post


Link to post
Share on other sites
21 hours ago, Jackal326 said:

You're welcome, and the gold becoming blue is probably due to a lack of rvmat (materials) so when you assign rvmats, it might fix the issue.

 

 

Rvmat didn't change anything

I managed to go around it by just making the golden parts blue in the texture file so that it becomes golden ingame....

Everything works as it should, but for some reason there is a signifficant amount of lag whenever I equip it from the arsenal.

It's not even that conplex of a model...I think

Is there anything I missed that could make it lag like that?

(There are no error messages)

Share this post


Link to post
Share on other sites
On 6/27/2021 at 4:55 PM, Jackal326 said:

You're welcome, and the gold becoming blue is probably due to a lack of rvmat (materials) so when you assign rvmats, it might fix the issue.

 

Hello, I have fixed the issue.

It appears the format of the texture itself has to be exactly a 2^n format (256x256 512x512, 2048x2048, 2048x1024 etc).

(Yes I copied this from another thead)

It now all works perfectly apart from the 2 seconds of lag upon equipping it. (I'll play around with it a little more).

Thank you, you have helped me a lot. I wish you a fabolous day.

untk9Mu.jpeg

  • Like 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×