Jump to content
  • 0

How do I allow gender selection when logging in?


Bob_the_K

Question

Hi,  I installed the vanilla Dayz Epoch server with no mods, changes, or additions.  It does not allow players to select their gender when spawning in.  I've searched high and low for how to enable this but no answers.   Seems many servers defaulted to being able to select the gender and people are asking how to turn it off. But no luck there either.  Rather than actually answering the question, most responses are asking why anyone would want to do that.

 

So where do I go to allow gender selection when spawning in?

 

Thanks,

Bob

Link to comment
Share on other sites

20 answers to this question

Recommended Posts

  • 0

As far as I know gender selection is on by default. I do not think its a simple switch on/off situation.

 

You say you have vanilla epoch with no mods or addons then you should have the gender selection. Can I ask who your hoster is or is this on your own server? Have you tried reinstalling the vanilla epoch files to see if it was a curropt instalation the first time?

 

The not being able to select gender is usually caused by bugs in specific player related parts of the code base. I know this as I've broken it over a dozen times playing around with the code. To be honest, its still is broken. :D

 

All I can suggest is first try this, in your server_playerLogin.sqf add this before the dayzPlayerLogin = [_charID......

diag_log (format["IsNew: %1",_isNew]);
diag_log (format["IsInfected: %1",_isInfected]);

Then check your player logs when you log in. Those are the two variables that get checked for the gender selection screen to show.

 

Secondly, I suggest a reinstall.

Thirdly, if that doesn't work request information from the hoster if they have added anything in the code (e.g. Dayz.ST have added custom code to some of the files).

And finally, if they all fail to provide any help, compare your server's server_playerLogin.sqf and server_playerSetup.sqf files with the files from the Epoch's Github or somewhere you know they are untouched to see what the differences are - use Diffmerge or related programs that would make this easier. I recommend diffmerge as I use it for normal app development too and it can save you a lot of time.

Link to comment
Share on other sites

  • 0

I figured it was on by default just by the number of people asking how to turn it off.. Oddly enough, no one really answered the question.  Anyway, I'm running my own server in my house (on my LAN) for my family to play on so as to not be bothered by PVPers.  they just have fun building and killing zombies (and eventually missions once I add them).  It isn't open to the outside world. 

 

It's on a Win7 system and all it's doing is running Arma2/Dayz/Epoch.  I downloaded all the files from EpochMod's Github link (v1.0.3.1 - haven't attempted 1.0.4.x given all the problems I've been reading about).  I ended up doing the install three different times for various reasons and followed the details in "Calling the Tech Wolf""s Youtube videos - both the 1.0.3 and 1.0.3.1 versions.  I also am using XAMPP for mySQL, NaviCat, BEC, and BattleWarden (and of course Rcon).  All seem to be working properly.  I even recently installed TSW's tool, more for the admin functions over anti-hack. 

 

I've extracted the SQF files for initialization and server startup and although I see many parameters regarding player data, I see nothing that remotely indicates anything about gender selection.

 

I'll add the lines you suggest and also re-download the files to compare to what I've actually got installed.  I can't imagine there's a problem yet since I haven't changed anything or added anything yet, this being first on my list of things to do.

 

Thanks,

Bob

Link to comment
Share on other sites

  • 0

I too have this problem but it was my fault as I messed about with the file that manages it. What I did find was that the gender selection screen does show up but it does so for miliseconds. Thus although we might think it isn't working the truth is it is working but is bugged such that it closes itself or something triggers it to close. This is what I haven't figured out and wish I could but I have no idea how to do that.

So, this is a possibility too and should be kept in mind.

The only fix I can think of is way too much work and I personally can't be asked to do it. Since it works fine on vanilla for everybody (well beside you) I don't think anyone would really look into changing it.

Link to comment
Share on other sites

  • 0

So I added those lines of code into server_playerLogin.sqf.  I now get:

Waiting server to start authentication... and then it dumps me back in the lobby.

 

All the logs now show is "Bad special value" and "Remote object x.xx not found".

 

In examining server_playerLogin.sqf more closely, I see the following code:

 

} else {
 _isInfected = _primary select 3;
 _model =  _primary select 4;
 _hiveVer =  _primary select 5;
 
 if (isNil "_model") then {
  _model = "Survivor2_DZ";
 } else {
  if (_model == "") then {
   _model = "Survivor2_DZ";
  };
 };

 

This is after it cannot match a character and seems to default to a Survivor2_DZ model if there's no match.  Seems that forces it to whatever that model is with no gender selection possible.

 

Someone must know how to do this since some servers don't provide gender selection.  They must have disabled something somewhere.

Link to comment
Share on other sites

  • 0

So I added those lines of code into server_playerLogin.sqf.  I now get:

Waiting server to start authentication... and then it dumps me back in the lobby.

 

All the logs now show is "Bad special value" and "Remote object x.xx not found".

 

In examining server_playerLogin.sqf more closely, I see the following code:

 

} else {

 _isInfected = _primary select 3;

 _model =  _primary select 4;

 _hiveVer =  _primary select 5;

 

 if (isNil "_model") then {

  _model = "Survivor2_DZ";

 } else {

  if (_model == "") then {

   _model = "Survivor2_DZ";

  };

 };

 

This is after it cannot match a character and seems to default to a Survivor2_DZ model if there's no match.  Seems that forces it to whatever that model is with no gender selection possible.

 

Someone must know how to do this since some servers don't provide gender selection.  They must have disabled something somewhere.

 

There is no way those two diagnosis lines broke your file. You might have added an extra { or ; or something as I have those lines working just fine in my file.

 

And as per your statements regarding the model. That just states the skin the player will get and that code basically sets it to the default value "Survivor2_DZ".

Link to comment
Share on other sites

  • 0

Well I guess I'm making progress.  The reason my editing those two lines in failed was due to my lack of experience with .pbo files.  I was unpacking, editing, and repacking.  I'm now using PBO Manager and copy out, edit, and paste back in and my files work.

 

Anyway, when adding the lines of code in ,they return

 

18:22:17 "IsNew: true"
18:22:17 "IsInfected: 0"

 

So I'm not sure what that tells me other than it's probably a new spawn and wasn't infected when I died.

 

Rick, as to the player_monitor.fsm file, there were some differences between mine and yours.  There were a few lines that had to do with gender selection that were different.  So I took the plunge and replaced mine with yours in its entirety.   No difference with a fresh spawn.  No gender selection.

 

So my quest continues....

Link to comment
Share on other sites

  • 0

Right now I'm running 1.0.3.1.  Haven't wanted to upgrade to 1.0.4 yet given the struggles I hear others are having.  Besides which, not too many servers have upgraded to 1,.0.4 yet which means I'd have to upgrade/downgrade and downgrade/upgrade depending on the server I want to play.

 

I had thought the same thing regarding upgrading and probably will live without it and see what happens when I upgrade to the latest.  If that doesn't work, I'll dig in further.  In the meantime, I'll be moving on to other scripts.

 

Thanks for everyone's help.  Being my first foray into scripting for DAYZ and how .PBOs work, it definitely helped me understand how some of this works together.

Link to comment
Share on other sites

  • 0

On my server I found what looks like a gender selection screen display conditional (dayz_DisplayGenderSelect).  It's in Dayz_server.pbo>init>compiles.sqf.  Around line 414 in the 1.0.4.2a code, the following appears:

 

  if (!isNil "dayz_DisplayGenderSelect") then {
   waitUntil {!dayz_DisplayGenderSelect};

 

Problem is that I haven't yet found where that value is set or changed based on spawn-in conditions.  Not being too familiar with the Arma scripting tools, I don't know if there are global search tools that allow one to search across the PBOs into the .sqf files to find all instances of the variable.  Does anyone know of any debug tools that work with these scripts to set breakpoints and tracepoints?  At least I then may be able to figure out where the call is being made (and if it is even being reached) to display the gender selection screen.

Link to comment
Share on other sites

  • 0

Neversober: it is in the client files (dayz_code.pbo). You need to extract it from there and copy it to your mission somewhere. And also make the player_monitor.sqf custom which calls the .fsm.

You then need a custom compile (also from the client dayz_code.pbo) where you reference to the new custom player_monitor.sqf.

The path to your custom compiles file needs to be adapted in your init.sqf in the mission.

In the custom player_monitor.sqf reference to the new custom player_monitor.fsm.

Sounds complicated but if you will have a look into these files you will see what I mean.

 

I hope that this is correct from my mind.

Link to comment
Share on other sites

  • 0

Neversober: it is in the client files (dayz_code.pbo). You need to extract it from there and copy it to your mission somewhere. And also make the player_monitor.sqf custom which calls the .fsm.

You then need a custom compile (also from the client dayz_code.pbo) where you reference to the new custom player_monitor.sqf.

The path to your custom compiles file needs to be adapted in your init.sqf in the mission.

In the custom player_monitor.sqf reference to the new custom player_monitor.fsm.

Sounds complicated but if you will have a look into these files you will see what I mean.

 

I hope that this is correct from my mind.

 

Tried this but didnt work, just kicks me back to lobby.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...