Jump to content
  • 0

Assigning Gender to Skins


JasonTM

Question

I'm building a Namalsk server and I need to assign gender to the three skins Skin_Sniper1W_DZN, Skin_CamoWinterW_DZN, Skin_CamoWinter_DZN but I cannot see how to do it.

I added the skins to the arrays AllPlayers and DayZ_Male in custom variables but there is an extra step to assign gender to the skins.

I see in player_wearClothes.sqf there are these lines.

	 // Current sex of player skin        
        _currentSex = getText (configFile >> "CfgSurvival" >> "Skins" >> _itemNew >> "sex");
        // Sex of new skin
        _newSex = getText (configFile >> "CfgSurvival" >> "Skins" >> _item >> "sex");

Is there a file called CfgSurvival.hpp that I have to edit. I can't find one.

There is a file in the CfgVehicles folder called Skins.hpp but I don't see any reference to gender.

Do I just add them in Skins.hpp?

 

Link to comment
Share on other sites

12 answers to this question

Recommended Posts

  • 0
  On 5/16/2017 at 3:30 PM, JasonTM said:

I'm building a Namalsk server and I need to assign gender to the three skins Skin_Sniper1W_DZN, Skin_CamoWinterW_DZN, Skin_CamoWinter_DZN but I cannot see how to do it.

I added the skins to the arrays AllPlayers and DayZ_Male in custom variables but there is an extra step to assign gender to the skins.

I see in player_wearClothes.sqf there are these lines.

	 // Current sex of player skin        
        _currentSex = getText (configFile >> "CfgSurvival" >> "Skins" >> _itemNew >> "sex");
        // Sex of new skin
        _newSex = getText (configFile >> "CfgSurvival" >> "Skins" >> _item >> "sex");

Is there a file called CfgSurvival.hpp that I have to edit. I can't find one.

There is a file in the CfgVehicles folder called Skins.hpp but I don't see any reference to gender.

Do I just add them in Skins.hpp?

 

Expand  

Are you still looking for this? i have the files buried somewhere

Link to comment
Share on other sites

  • 0

add

#include "PATH\TO\YOUR\CfgArma.hpp"

to your description.ext

CfgArma.hpp

  Reveal hidden contents

 

In your custom compiles find

player_wearClothes = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_wearClothes.sqf";

replace with

player_wearClothes = compile preprocessFileLineNumbers "PATH\TO\YOUR\player_wearClothes.sqf";

 

player_wearClothes.sqf

  Reveal hidden contents

 

If you need any other namalsk stuff let me know I've got most of it working except blowouts registering players in buildings. its abit too strong xD

Link to comment
Share on other sites

  • 0

Well I'll be damned. The file is called CfgArma.hpp. Thanks so much for that. I had no idea that was the file that contained CfgSurvival and thanks for the modded player_wearClothes.sqf as well.

I have the blowouts working and when I am in a building without an APSI I get knocked out but I don't lose any blood. Is that your case as well? I'll run it right now and see if the RPT reports me as being in a building.

Link to comment
Share on other sites

  • 0

@JasonTM i cant understand so well what you need (its not your fault, is about my bad english) in anycase i guess oldma´ already help you.. but maybe you can use it to something..i was using it to pregnant womans.. so the code recognize when a skins is woman and when not.

_recognize_as_woman = [
//cherno
//"BanditW1_DZ",
//"SurvivorW2_DZ",
//"BanditW2_DZ"

//namlk
Skin_Sniper1W_DZN,
Skin_CamoWinterW_DZN, 
Skin_CamoWinter_DZN
];

if (typeOf player in _recognize_as_woman) then {
//
}else{
//
};

 

Link to comment
Share on other sites

  • 0

@juandayzThe file that @oldmatechoc posted is the one that is used to determine the gender of clothes. The warm clothes classnames included with Namalsk have to be added to the file so male players can wear them.

		class Skin_CamoWinter_DZN: Default {
			sex = "male";
			playerModel = "CamoWinter_DZN";
		};
		class Skin_CamoWinterW_DZN: Default {
			sex = "male";
			playerModel = "CamoWinterW_DZN";
		};
		class Skin_Sniper1W_DZN: Default {
			sex = "male";
			playerModel = "Sniper1W_DZN";
		};		

 

Link to comment
Share on other sites

  • 0
  On 5/20/2017 at 2:18 PM, JasonTM said:

The file that @oldmatechoc posted is the one that is used to determine the gender of clothes. The warm clothes classnames included with Namalsk have to be added to the file so male players can wear them.

		class Skin_CamoWinter_DZN: Default {
			sex = "male";
			playerModel = "CamoWinter_DZN";
		};
		class Skin_CamoWinterW_DZN: Default {
			sex = "male";
			playerModel = "CamoWinterW_DZN";
		};
		class Skin_Sniper1W_DZN: Default {
			sex = "male";
			playerModel = "Sniper1W_DZN";
		};		

 

Expand  

and added to all clothes in variables so they save over restarts

Link to comment
Share on other sites

  • 0
  On 5/20/2017 at 2:18 PM, oldmatechoc said:

@JasonTM yeah, the blowouts arent suppose to affect you when in buildings. the new fn_isInsideBuilding has to be merged with the blowout one

Expand  

I think I still have an old 1.0.5.1 Namalsk server on my LAN server. I'll test that sometime this week and see if the same thing happens.

BTW, I also noticed that there is an error in the client RPT.

Error in expression <{
_jednotka = AllUnits select _c;
if (!(_jednotka hasWeapon "APSI") && (Alive _j>
  Error position: <_jednotka hasWeapon "APSI") && (Alive _j>
  Error Undefined variable in expression: _jednotka
File nst\ns_modules\blowout\module\blowout_client.sqf, line 77

I think that variable should have been declared as private. It doesn't appear to break anything but having RPT errors is annoying.

Link to comment
Share on other sites

  • 0
  On 5/20/2017 at 2:29 PM, JasonTM said:

I think I still have an old 1.0.5.1 Namalsk server on my LAN server. I'll test that sometime this week and see if the same thing happens.

BTW, I also noticed that there is an error in the client RPT.

Error in expression <{
_jednotka = AllUnits select _c;
if (!(_jednotka hasWeapon "APSI") && (Alive _j>
  Error position: <_jednotka hasWeapon "APSI") && (Alive _j>
  Error Undefined variable in expression: _jednotka
File nst\ns_modules\blowout\module\blowout_client.sqf, line 77

I think that variable should have been declared as private. It doesn't appear to break anything but having RPT errors is annoying.

Expand  

Did you ever figure that one out. I'm doing my best to get a clean client log but this one is getting to me even when its just a passive error it bugs me so much. Iv already pulled the files over to my mission to play about with it.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...