• 0
C][G GhostTown™

headgear keeps changing

Question

24 answers to this question

Advertisement
  • 1

Ignore. After a death the Fedora party continues. :(

Think I figured it out guys. I have done 4 server restarts and my helmet/headgear seems to stay with my PC now.

Thanks to @norbert79 for the idea in their last post I decided to look for our Santa Hat!In @ExileServer\addons\exile_server\code\  - I found "ExileServer_object_player_network_createPlayerRequest.sqf.

Spoiler



/**
 * ExileServer_object_player_network_createPlayerRequest
 *
 * Exile Mod
 * exile.majormittens.co.uk
 * © 2015 Exile Mod Team
 *
 * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. 
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
 */
 
private["_sessionID","_parameters","_requestingPlayer","_spawnLocationMarkerName","_playerUID","_accountData","_bambiPlayer","_cargoType"];
_sessionID = _this select 0;
_parameters = _this select 1;
_requestingPlayer = _sessionID call ExileServer_system_session_getPlayerObject;
try
{
	if (isNull _requestingPlayer) then 
	{
		throw format ["Session %1 requested a bambi character, but doesn't have a player object. Hacker or Monday?", _sessionID];
	};
	_spawnLocationMarkerName = _parameters select 0;
	_playerUID = getPlayerUID _requestingPlayer;
	if(_playerUID isEqualTo "")then
	{
		throw format ["Player: '%1' has no player UID. Arma/Steam Sucks!.",name _requestingPlayer];
	};
	_accountData = format["getAccountStats:%1", _playerUID] call ExileServer_system_database_query_selectSingle;
	_group = createGroup independent;
	_bambiPlayer = _group createUnit ["Exile_Unit_Player", [0,0,0], [], 0, "CAN_COLLIDE"];
	//removeHeadgear _bambiPlayer;
	{
		_cargoType = _x call ExileClient_util_cargo_getType;
		switch (_cargoType) do
		{
			case 1: 	{ _bambiPlayer addItem _x; };
			case 2: 	{ _bambiPlayer addWeaponGlobal _x; };
			case 3: 	{ _bambiPlayer addBackpackGlobal _x; };
			case 4:		{ _bambiPlayer linkItem _x; };
			default 					{ _bambiPlayer addItem _x; };
		};
	}
	forEach getArray(configFile >> "CfgSettings" >> "BambiSettings" >> "loadOut");
	[_sessionID, _requestingPlayer, _spawnLocationMarkerName, _bambiPlayer, _accountData] call ExileServer_object_player_createBambi;
}
catch
{
	_exception call ExileServer_util_log;
};

 

As you can see, on Line # 31 I found: removeHeadgear _bambiPlayer.

I commented this line out, saved the file, and loaded it customly through the mission file to give it a test.

 

So far so good! :)

I will update if anything changes, and please give feedback and discoveries in case I'm wrong!

Edited by CRAZYGAMER04
  • Like 1

Share this post


Link to post
Share on other sites
  • 0

I can confirm this issue, after each restart the used headgear is replaced with a random one. As a pre-caution I always place my helmet into my backpack before leaving the server. I assume, or am 80% sure, that this has to do with a removal of the code for the "Santa hat" and it wasn't  cleaned up properly.

Share this post


Link to post
Share on other sites
  • 0
5 hours ago, norbert79 said:

I can confirm this issue, after each restart the used headgear is replaced with a random one. As a pre-caution I always place my helmet into my backpack before leaving the server. I assume, or am 80% sure, that this has to do with a removal of the code for the "Santa hat" and it wasn't  cleaned up properly.

If you figure anything out let me know.

It's weird it's only happening on certain servers.

Share this post


Link to post
Share on other sites
  • 0
9 hours ago, CRAZYGAMER04 said:

Ignore. After a death the Fedora party continues. :(

Think I figured it out guys. I have done 4 server restarts and my helmet/headgear seems to stay with my PC now.

Thanks to @norbert79 for the idea in their last post I decided to look for our Santa Hat!In @ExileServer\addons\exile_server\code\  - I found "ExileServer_object_player_network_createPlayerRequest.sqf.

  Reveal hidden contents

 



/**
 * ExileServer_object_player_network_createPlayerRequest
 *
 * Exile Mod
 * exile.majormittens.co.uk
 * © 2015 Exile Mod Team
 *
 * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. 
 * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
 */
 
private["_sessionID","_parameters","_requestingPlayer","_spawnLocationMarkerName","_playerUID","_accountData","_bambiPlayer","_cargoType"];
_sessionID = _this select 0;
_parameters = _this select 1;
_requestingPlayer = _sessionID call ExileServer_system_session_getPlayerObject;
try
{
	if (isNull _requestingPlayer) then 
	{
		throw format ["Session %1 requested a bambi character, but doesn't have a player object. Hacker or Monday?", _sessionID];
	};
	_spawnLocationMarkerName = _parameters select 0;
	_playerUID = getPlayerUID _requestingPlayer;
	if(_playerUID isEqualTo "")then
	{
		throw format ["Player: '%1' has no player UID. Arma/Steam Sucks!.",name _requestingPlayer];
	};
	_accountData = format["getAccountStats:%1", _playerUID] call ExileServer_system_database_query_selectSingle;
	_group = createGroup independent;
	_bambiPlayer = _group createUnit ["Exile_Unit_Player", [0,0,0], [], 0, "CAN_COLLIDE"];
	//removeHeadgear _bambiPlayer;
	{
		_cargoType = _x call ExileClient_util_cargo_getType;
		switch (_cargoType) do
		{
			case 1: 	{ _bambiPlayer addItem _x; };
			case 2: 	{ _bambiPlayer addWeaponGlobal _x; };
			case 3: 	{ _bambiPlayer addBackpackGlobal _x; };
			case 4:		{ _bambiPlayer linkItem _x; };
			default 					{ _bambiPlayer addItem _x; };
		};
	}
	forEach getArray(configFile >> "CfgSettings" >> "BambiSettings" >> "loadOut");
	[_sessionID, _requestingPlayer, _spawnLocationMarkerName, _bambiPlayer, _accountData] call ExileServer_object_player_createBambi;
}
catch
{
	_exception call ExileServer_util_log;
};

 

As you can see, on Line # 31 I found: removeHeadgear _bambiPlayer.

I commented this line out, saved the file, and loaded it customly through the mission file to give it a test.

 

So far so good! :)

I will update if anything changes, and please give feedback and discoveries in case I'm wrong!

Not working.

People are still having there headgear changed

Share this post


Link to post
Share on other sites
Advertisement

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

  • Recently Browsing   0 members

    No registered users viewing this page.