Raised This Month: $12 Target: $400
 3% 

[L4D & L4D2] Custom Player Stats v1.4B121


Post New Thread Reply   
 
Thread Tools Display Modes
muukis
Veteran Member
Join Date: Apr 2009
Old 02-25-2010 , 06:36   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #411

Quote:
Originally Posted by mustafata View Post
where can i find this "nickname id" version.
I think it's THIS.
__________________
Monster Hunter

Though certainly not superhuman, the man's prowess inspires an excess of whispered rumors. But those rumors remain in the realm of speculation.
muukis is offline
DmanWCG
Member
Join Date: Aug 2008
Old 02-25-2010 , 07:25   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #412

Quote:
Originally Posted by DmanWCG View Post
Limit the total amount of plays that are ranked. My total players right now are 1,100. Can I limit the list to 100 or 200 on the stats site?
**BUMP**
__________________
DmanWCG is offline
muukis
Veteran Member
Join Date: Apr 2009
Old 02-25-2010 , 10:18   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #413

Quote:
Originally Posted by DmanWCG View Post
**BUMP**
Not sure if it's possible, but what do you wish to accomplish with this?

To make sure I understood you correctly... You want to delete player stats that do not fit in the top 200 (for example)?

You would need to add this to the bottom of common.php: NOT TESTED AND VERIFIED TO WORK
PHP Code:
$limitedplayers 200;

if (
$header_extra['Players Served'] > $limitedplayers)
{
    
$result mysql_query("SELECT " $TOTALPOINTS " AS totalpoints FROM players ORDER BY " $TOTALPOINTS " DESC LIMIT " $limitedplayers ",1");
    if (
$result && mysql_num_rows($result) > && ($row mysql_fetch_array($result)))
    {
        
mysql_query("DELETE FROM players WHERE " $TOTALPOINTS " < " $row['totalpoints']);
    }

But in addition to that, you should probably not delete scores of the players currently online and/or with last online time less than some time you'd like it to be.
__________________
Monster Hunter

Though certainly not superhuman, the man's prowess inspires an excess of whispered rumors. But those rumors remain in the realm of speculation.
muukis is offline
DmanWCG
Member
Join Date: Aug 2008
Old 02-25-2010 , 13:42   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #414

Yes, is that possible?

My database is 213 mb and it has only been up for a week and a half.
__________________
DmanWCG is offline
sirka.j
Junior Member
Join Date: Feb 2010
Old 02-25-2010 , 16:56   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #415

First, thank you for stats. It is very nice and we (our group) appreciate that.
We have installed it successfully on our linux server and it works without problems. Now i try to do some special stats for us, so i install it on my notebook Windows7 WAMP server. And now i have a problem:

- in config.php is variable $game_version and it is in global scope
- config.php is included in common.php where is $game_version in global scope too
- in config.php there is function:
function gettotalpoints($row)
{
$totalpoints = 0;

if ($game_version != 1)
...
}

problem is, that $game_version is not accessible in function and i got Notice: Undefined variable ...
Everithing works but should not ... i do not understand how is it possible. And it is not only $game_version, but many others.

for example: In function gettotalpoints is decided what stats will be displayed and it is displayed correctly ... but it should not ...

Can you help me to uderstand it, please?
Thank you.
sirka.j is offline
kwski43
Senior Member
Join Date: Mar 2009
Old 02-25-2010 , 16:58   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #416

Quote:
Originally Posted by sirka.j View Post
First, thank you for stats. It is very nice and we (our group) appreciate that.
We have installed it successfully on our linux server and it works without problems. Now i try to do some special stats for us, so i install it on my notebook Windows7 WAMP server. And now i have a problem:

- in config.php is variable $game_version and it is in global scope
- config.php is included in common.php where is $game_version in global scope too
- in config.php there is function:
function gettotalpoints($row)
{
$totalpoints = 0;

if ($game_version != 1)
...
}

problem is, that $game_version is not accessible in function and i got Notice: Undefined variable ...
Everithing works but should not ... i do not understand how is it possible. And it is not only $game_version, but many others.

for example: In function gettotalpoints is decided what stats will be displayed and it is displayed correctly ... but it should not ...

Can you help me to uderstand it, please?
Thank you.
Does your php register_globals is 'on' ?
__________________
kwski43 is offline
sirka.j
Junior Member
Join Date: Feb 2010
Old 02-25-2010 , 17:04   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #417

Quote:
Originally Posted by kwski43 View Post
Does your php register_globals is 'on' ?
it has nothing to do with register_globals, i think. And yes, i have tested it.
Thx for answer
sirka.j is offline
sirka.j
Junior Member
Join Date: Feb 2010
Old 02-25-2010 , 17:34   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #418

I have made some tests and i find, that problems with $game_version from config.php has impacts to web stats. Web stats results does not equal in-game stats (if i type rank, rankmenu, ...) In our case we have always higher PPM in-game (we play only L4D2 on our servers) than shown by web. I think that variable $game_version should be declared global in functions to be accessible in functions scope and to have some effect.
For example: function gettotalplaytimecalc (common.php) always return total play time calculated from versus, coop, ... (all L4D1 game types), but scavenge, realism are never added, because $game_version is undefined in this function and statement
if ($game_version != 1) is always true (nice from php) (tested for $game_version = 1, 2).
Is it possible, that it is a bug or am i wrong?

PS: We use server only for L4D2, so there is no L4D1 data in DB

image with stats before and after editing (added global $game_version;) function gettotalplaytimecalc (common.php)
http://kedlubna.prodejce.cz/stats.png

Last edited by sirka.j; 02-25-2010 at 20:19.
sirka.j is offline
sirka.j
Junior Member
Join Date: Feb 2010
Old 02-25-2010 , 17:55   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #419

And image ... we play L4D2 only so there is no parasitic data from L4D1
sirka.j is offline
eargosedown
Member
Join Date: Jan 2010
Old 02-25-2010 , 18:02   Re: [L4D & L4D2] Custom Player Stats v1.4B66
Reply With Quote #420

Any progress on getting a SM command to turn off a players messages on the server?
eargosedown is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 07:29.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode