xmoondockx Posted August 9, 2015 Report Share Posted August 9, 2015 I have the same issues right now. What DLL's are you talking about? HiveExt.dll? If so where did you put that? EDIT: After hours of working with it, I got it to work. :) Yea how did you fix it? Link to comment Share on other sites More sharing options...
Nekuan Posted September 1, 2015 Report Share Posted September 1, 2015 (edited) For some reason the coins are only saved on players and not on banks. The only major change I did was implementing P4L. Can anyone point me in the right direction?Just tried it with only the files delivered by this mod but the outcome is still the same Edited September 2, 2015 by Nekuan Link to comment Share on other sites More sharing options...
creativv Posted October 1, 2015 Report Share Posted October 1, 2015 For people who have problems with the check wallet that your players go into minus just dont let them pick it up then .You can change this in check_wallet.sqf .private ["_body", "_hisMoney", "_myMoney", "_killsH", "_test2", "_headShots", "_test","_playeridke","_humanity"]; _body = _this select 3; // Add This to not let players pick up over 999999 _hisMoney = _body getVariable ["cashMoney",0]; if(_hisMoney > 999999) exitWith { cutText ["This player has to many coins you cant pick it up it will bug your cash", "PLAIN DOWN"]; }; // Add This to not let players pick up over 999999 _PlayerNear = _body call dze_isnearest_player; if (_PlayerNear) exitWith {cutText [localize "str_pickup_limit_4", "PLAIN DOWN"]}; _name = _body getVariable ["bodyName","unknown"]; _hisMoney = _body getVariable ["cashMoney",0]; _myMoney = player getVariable ["cashMoney",0]; _myMoney = _myMoney + _hisMoney; _body setVariable ["cashMoney", 0 , true]; player setVariable ["cashMoney", _myMoney , true]; systemChat format ['You took %1 coins, ID says %2 !',_hisMoney,_name]; sleep 2; _cid = player getVariable ["CharacterID","0"]; _cashMoney = player getVariable ["cashMoney",0]; if(_cashMoney > 0) then{ } else { _cashMoney = 0; }; Link to comment Share on other sites More sharing options...
creativv Posted October 1, 2015 Report Share Posted October 1, 2015 (edited) Also you can change the coin and bankinit.sqf and the givedialog so players can only be walking around with a certain amount of cash . Edited October 1, 2015 by creativv Link to comment Share on other sites More sharing options...
SadBoy1981 Posted October 3, 2015 Report Share Posted October 3, 2015 Looks like infistar dont allow players to see on hud how much they have coins on hands and bank.Is there some fix for this? Link to comment Share on other sites More sharing options...
creativv Posted October 3, 2015 Report Share Posted October 3, 2015 If you run latest infistar its shouldnt be blocked Link to comment Share on other sites More sharing options...
Pavillin Posted October 13, 2015 Report Share Posted October 13, 2015 Installed this, whenever a player relogs/server restarts the coins on their character + back don't save. Other than that everything works the coins just won't save. Link to comment Share on other sites More sharing options...
bFe Posted October 13, 2015 Report Share Posted October 13, 2015 Installed this, whenever a player relogs/server restarts the coins on their character + back don't save. Other than that everything works the coins just won't save.Have you replaced the DLL files and unblocked them if necessary? Link to comment Share on other sites More sharing options...
Pavillin Posted October 13, 2015 Report Share Posted October 13, 2015 Have you replaced the DLL files and unblocked them if necessary?I have replaced the DLL files, what is it you mean by 'unblock them is necessary'? Link to comment Share on other sites More sharing options...
bFe Posted October 13, 2015 Report Share Posted October 13, 2015 Right click on one of the DLL files and you'll see at the bottom it says "This file came from another computer and might be blocked to help protect this computer". You then need to check off the Unblock and hit Apply. Link to comment Share on other sites More sharing options...
Pavillin Posted October 13, 2015 Report Share Posted October 13, 2015 (edited) Right click on one of the DLL files and you'll see at the bottom it says "This file came from another computer and might be blocked to help protect this computer". You then need to check off the Unblock and hit Apply. EDIT: Would I do this on my computer before I upload them to my server or would I do it after they have been uploaded? Also if it's the second, how would I do that with filezilla? Edited October 13, 2015 by Pavillin bFe 1 Link to comment Share on other sites More sharing options...
Pavillin Posted October 18, 2015 Report Share Posted October 18, 2015 I managed to get this working, turns out the DLL files were fine. It was an error on my part when I diff merged. Link to comment Share on other sites More sharing options...
bFe Posted November 2, 2015 Report Share Posted November 2, 2015 I managed to get this working, turns out the DLL files were fine. It was an error on my part when I diff merged.What was the error? I'm having the same problem now after I moved from no bank to bank. Link to comment Share on other sites More sharing options...
Pavillin Posted November 2, 2015 Report Share Posted November 2, 2015 (edited) What was the error? I'm having the same problem now after I moved from no bank to bank.I forgot to merge a few files in the dayz_server.pbo in the compile folder, I did every other file but forgot a couple in that folder. Also I had to add the banks not saving for new players fix. After that everything was working properly.http://epochmod.com/forum/index.php?/topic/15924-issue-banking_data-not-saving-for-new-players-fixed/ Edited November 2, 2015 by Pavillin bFe 1 Link to comment Share on other sites More sharing options...
bFe Posted November 2, 2015 Report Share Posted November 2, 2015 CashMoney is being saved in Character_DATA but the banking_data remains empty when I deposit cash. What am I missing? Link to comment Share on other sites More sharing options...
Pavillin Posted November 3, 2015 Report Share Posted November 3, 2015 (edited) CashMoney is being saved in Character_DATA but the banking_data remains empty when I deposit cash. What am I missing?I assume that you're merging this with an existing server... As silly as it may sound, I believe that you're missing something from one of the files in the compile folder. I had the SC working fine but only had bank issues, and it was because I missed files in the dayz_server.pbo Once I compared files specifically in the compile folder I noticed I was missing some code. Made the changes and everything started working. So I would say your problem hides in the server pbo. Edited November 3, 2015 by Pavillin Link to comment Share on other sites More sharing options...
bFe Posted November 3, 2015 Report Share Posted November 3, 2015 (edited) I assume that you're merging this with an existing server... As silly as it may sound, I believe that you're missing something from one of the files in the compile folder. I had the SC working fine but only had bank issues, and it was because I missed files in the dayz_server.pbo Once I compared files specifically in the compile folder I noticed I was missing some code. Made the changes and everything started working. So I would say your problem hides in the server pbo.I replaced all the files in the compiles folder with the one included in the SC 3.0 package. The only thing I've changed in the dayz_server.pbo is the #include bit that goes in the server_functions.Edit: Tried using the premade pbo files but the same error occured. Any special visual c++ version required? Edited November 3, 2015 by bFe Link to comment Share on other sites More sharing options...
Pavillin Posted November 3, 2015 Report Share Posted November 3, 2015 I replaced all the files in the compiles folder with the one included in the SC 3.0 package. The only thing I've changed in the dayz_server.pbo is the #include bit that goes in the server_functions.Edit: Tried using the premade pbo files but the same error occured. Any special visual c++ version required?Not that I'm aware of Link to comment Share on other sites More sharing options...
bFe Posted November 3, 2015 Report Share Posted November 3, 2015 Alright. Well the DLL files are unblocked so I have no idea what it could be. Link to comment Share on other sites More sharing options...
Phone_Guy Posted November 4, 2015 Report Share Posted November 4, 2015 I am currently using Soul 2.0 SC. Everything is working fine currently. However on rare occasions players will slip into negative currency. Does anyone know how to prevent this from happening? Link to comment Share on other sites More sharing options...
kelso000 Posted November 4, 2015 Report Share Posted November 4, 2015 This is due to currencies over a million liking to save to the database in scientific notation, ie 1.2E+06. Read this thread: http://epochmod.com/forum/index.php?/topic/15975-issue-players-get-negative-sums-in-cashmoney-across-restarts/This will still cause errors when converted it to a decimal. Ideally you want it to save to the DB without the decimal.If you get the CBA pack for Arma2 and find the formatNumbers function, change a few things to get it so it will work client side, you can format the number without decimals. I can post the function I use when I get home if you're unsure what I am saying. Link to comment Share on other sites More sharing options...
Zupa Posted November 4, 2015 Report Share Posted November 4, 2015 Global message:Formatting numbers is only for displaying the value in the way you want it.Negative money is a known bug. Never really pinpointed the issue myself. I blame lag in the saving process with the dll or a wrong parse in the dll/sql connection. Link to comment Share on other sites More sharing options...
kelso000 Posted November 4, 2015 Report Share Posted November 4, 2015 Global message:Formatting numbers is only for displaying the value in the way you want it.Negative money is a known bug. Never really pinpointed the issue myself. I blame lag in the saving process with the dll or a wrong parse in the dll/sql connection.After I started saving numbers into the database as a string, the problem went away. Link to comment Share on other sites More sharing options...
rss_adm Posted November 15, 2015 Report Share Posted November 15, 2015 After I started saving numbers into the database as a string, the problem went away.Can you show how you did it? Link to comment Share on other sites More sharing options...
kelso000 Posted November 16, 2015 Report Share Posted November 16, 2015 Sure,I removed the Community Base Addons format number function from the PBO and modified so it would work for this purpose:Save this as "cba_number.sqf" somewhere in your mission fileprivate ["_integerPart", "_string", "_numIntegerDigits", "_decimalPoint","_thousandsSeparator", "_basePlaces"]; _number = _this select 0; _integerWidth = _this select 1; _decimalPlaces = _this select 2; _separateThousands = _this select 3; _decimalPoint = "."; _thousandsSeparator = ","; if (_decimalPlaces > 0) then { _basePlaces = 10 ^ _decimalPlaces; _number = round(_number * _basePlaces) / _basePlaces; _integerPart = floor (abs _number); } else { _integerPart = round (abs _number); }; _string = ""; _numIntegerDigits = 0; while {_integerPart > 0} do { if ((_numIntegerDigits > 0) and ((_numIntegerDigits mod 3) == 0) and _separateThousands) then { _string = _thousandsSeparator + _string; }; _string = (str (_integerPart mod 10)) + _string; _numIntegerDigits = _numIntegerDigits + 1; _integerPart = floor (_integerPart / 10); }; while {_numIntegerDigits < _integerWidth} do { if ((_numIntegerDigits > 0) and ((_numIntegerDigits mod 3) == 0) and _separateThousands) then { _string = _thousandsSeparator + _string; }; _string = "0" + _string; _numIntegerDigits = _numIntegerDigits + 1; }; if (_number < 0) then { _string = "-" + _string; }; if (_decimalPlaces > 0) then { private ["_digit", "_multiplier", "_i"]; _string = _string + _decimalPoint; _multiplier = 10; for "_i" from 1 to _decimalPlaces do { _digit = floor ((_number * _multiplier) mod 10); if (not (finite _digit)) exitWith { private "_j"; for "_j" from _i to _decimalPlaces do { _string = _string + "0"; }; }; _string = _string + (str _digit); _multiplier = _multiplier * 10; }; }; _string;Put this in your compiles.sqf (change path)CBA_fnc_formatNumber = compile preprocessFileLineNumbers "path\to\file\cba_number.sqf"; Finally, in your server_playerSync.sqf add (and also _cashMoneyCBA at the end declaring private variables):_cashMoneyCBA = [_cashMoney,0,0,false] call CBA_fnc_formatNumber; under_cashMoney = ["cashMoney",_character] call server_getDiff2;and change the _cashMoney to _cashMoneyCBA here (line 192 for me)_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]; What this does is converts _cashMoney to a string before writing it to the hive. I take back what I said though: coins will still very rarely go negative, but you won't have the write to hive errors. What I do is run this every restart:-- Non negative cashMoney UPDATE `character_data` SET `cashMoney` = 0 WHERE `cashMoney` < 0; Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now