Jump to content

SC 2.0 server_functions.sqf issue


Recommended Posts

Hi

 

Have been running in to a couple of issues today after starting a new server with SC 2.0

 

HUD displays correct, traders work fine, but when selling the currency is not updating as it should. I have taken all steps to get this working but seem to be getting no where!

 

My RPT shows this error:

_object>
18:13:09 Error Undefined variable in expression: _vnew
18:13:09 File z\addons\dayz_server\init\server_functions.sqf, line 577
18:13:09 Error in expression <object getVariable[(_variable + "_CHK"),_vNew];
_result = _vNew - _vOld;


_object>

 

here is my server_functions.sqf http://pastebin.com/GJMjC5nC

 

​I have also used Beyond compare to check differences between my 1.1 server functions and 2.0

 

Any help would really be appreciated. 

Link to comment
Share on other sites

If I run this query as suggested in souls 2.0 installation: 

SET FOREIGN_KEY_CHECKS=0;       -- ----------------------------   -- Transfer goldcoins from `HeadShots` to `CashMoney` field   -- ----------------------------       UPDATE character_data   SET CashMoney = HeadshotsZ

  

I get this message:

 

UPDATE character_data
SET CashMoney = HeadshotsZ
 
Affected rows: 0
Time: 0.075s
 
Could this have anything to do with the issue?
Link to comment
Share on other sites

 

 

reupdate your server_playerSync.sqf its got parts from SC1.1 and SC2.0

 

I have updated it with this one https://github.com/UK431-Soul/DayZ-Epoch_SCHiveExt/blob/master/dayz_server/compile/server_playerSync.sqf

 

and the RPT shows this error: Noticed the first line states error in expression urrency, instead of currency, but not sure as to where this is referring to.

 

13:18:52 Error in expression <urrency = _this select 5;

_qty = _this select 6;

_clientID = owner _player;

_p>

13:18:52 Error position: <select 6;

_clientID = owner _player;

_p>

13:18:52 Error Zero divisor

13:18:52 File z\addons\dayz_server\compile\server_tradeObject.sqf, line 9

13:18:54 Error in expression <object getVariable[(_variable + "_CHK"),_vNew];

_result = _vNew - _vOld;

_object>

13:18:54 Error position: <_vNew];

_result = _vNew - _vOld;

_object>

13:18:54 Error Undefined variable in expression: _vnew

13:18:54 File z\addons\dayz_server\init\server_functions.sqf, line 577

13:18:54 Error in expression <_killsH,_killsB,_currentModel,_humanity,_cashMoney];

_key call server_hiveWrite>

13:18:54 Error position: <_cashMoney];

_key call server_hiveWrite>

13:18:54 Error Undefined variable in expression: _cashmoney

13:18:54 File z\addons\dayz_server\compile\server_playerSync.sqf, line 193

13:18:54 Error in expression <object getVariable[(_variable + "_CHK"),_vNew];

_result = _vNew - _vOld;

_object>

13:18:54 Error position: <_vNew];

_result = _vNew - _vOld;

_object>

13:18:54 Error Undefined variable in expression: _vnew

13:18:54 File z\addons\dayz_server\init\server_functions.sqf, line 577

13:18:54 Error in expression <_killsH,_killsB,_currentModel,_humanity,_cashMoney];

_key call server_hiveWrite>

13:18:54 Error position: <_cashMoney];

_key call server_hiveWrite>

13:18:54 Error Undefined variable in expression: _cashmoney

13:18:54 File z\addons\dayz_server\compile\server_playerSync.sqf, line 193

13:19:52 "TIME SYNC: Local Time set to [2013,8,3,8,19]"

Link to comment
Share on other sites

  • 4 weeks later...

I'm getting the same error, along with a few others that may be unrelated, after merging the files on my server.

_v setvel>
5:10:47 Error position: <_shards;
deleteVehicle _dirt;

_v setvel>
5:10:47 Error Undefined variable in expression: _shards
5:10:47 File ca\Data\ParticleEffects\SCRIPTS\destruction\AirDestructionStage2.sqf, line 71
5:11:19 "infiSTAR.de fnc_AdminFirstReq: [1,B 1-1-B:1 ([FITM]Chaingun427) REMOTE,[17275,7492.06,0]]"
5:11:19 "infiSTAR.de fnc_AdminReqProceed: [1,B 1-1-B:1 ([FITM]Chaingun427) REMOTE,[17275,7492.06,0]]"
5:11:19 "infiSTAR.de PVAH_WriteLog: B 1-1-B:1 ([FITM]Chaingun427) REMOTE [FITM]Chaingun427 Teleport to [17275,7492.06,0](@172175)"
5:11:26 Error in expression <object getVariable[(_variable + "_CHK"),_vNew];
_result = _vNew - _vOld;
_object>
5:11:26 Error position: <_vNew];
_result = _vNew - _vOld;
_object>
5:11:26 Error Undefined variable in expression: _vnew
5:11:26 File z\addons\dayz_server\init\server_functions.sqf, line 577
5:11:26 Error in expression <_killsH,_killsB,_currentModel,_humanity,_cashMoney];

_key call server_hiveWrite>
5:11:26 Error position: <_cashMoney];

_key call server_hiveWrite>
5:11:26 Error Undefined variable in expression: _cashmoney
5:11:26 File z\addons\dayz_server\compile\server_playerSync.sqf, line 191

EDIT I'm looking at the following line in server_playersync.sqf and i'm wondering if it's trying to reference the wrong column? i've attached an image of my character_data table

_key = format["CHILD:201:%1:%2:%3:%4:%5:%6:%7:%8: %9:%10:%11:%12:%13:%14:%15:%16:%17:",_characterID,_playerPos,_playerGear,_playerBackp,_medical,false,false,_kills,_headShots,_distanceFoot,_timeSince,_currentState,_killsH,_killsB,_currentModel,_humanity,_cashMoney];

post-2064-0-19305900-1413174971_thumb.pn

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...