Jump to content

Statistics Based on Server Log File


Recommended Posts

In this site you can see the plot poles that have itens about to be deleted.

Everything with 2 remaining days before deletion is showed on the site. This is to help players not loose their bases.

http://177.54.147.235/my_objects.asp

The original site had all plot poles and all construction itens with time remaining before deletion, but this is not a good thing since anyone using the site can see other base position, so now we show only the plot poles with itens about to delete.

Link to comment
Share on other sites

Cadence, we do not use the server log anymore. We are using Arma2NET MYSQL to trow the info in the DB when it happens.

For that we changed the server files:

dayz_server\compile\server_tradeObject.sqf - to log each buys and sells.

dayz_server\compile\fnc_plyrHit.sqf - to log each player hit by a weapon or run over by a car (shot distance will be 0).

dayz_server\compile\server_playerDied.sqf - to log each kill.

Here are the modified files:

http://s000.tinyupload.com/index.php?file_id=08695246643606373849

Here a example, the code that have been added in server_tradeObjects.sqf file:

//DONN ARMA2NET MYSQL BEGIN
_buyorsell_txt = "";
if (_buyorsell == 0) then {_buyorsell_txt = "BUY";} else {_buyorsell_txt = "SELL";}; 
_a2n_sql_run = Format [
	"Arma2NETMySQLCommand ['dayz_epoch_stats', 'INSERT INTO BUYS_SELLS VALUES ('%1','%8', NULL,'%2','%3','%4','%5',%6,'%7','NA',0)']",
	don_date_time,
	name _player,
	getPlayerUID _player,
	_classname,
	_traderID,
	_qty,
	_currency,
	_buyorsell_txt
];
diag_log format["TRADERSTATS A2N: %1", _a2n_sql_run];
"Arma2Net.Unmanaged" callExtension _a2n_sql_run;
//DONN ARMA2NET MYSQL END
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...