[INACTIVE][INFO/WEB] Minestats v0.85 - Webstatistics for Stats and Achievements [617]

Discussion in 'Inactive/Unsupported Plugins' started by Abadon84, Mar 14, 2011.

  1. Offline

    Abadon84

    Minestats - Webstatistics for Stats and Achievements
    Version: v0.85

    An easy in use web interface based on the awesome plugins Stats & Achievements,
    see it in action here.

    Features:
    • Easy multi language support
    • Still supported languages are english, german, french, spanish and 1337-Speak
    • Easy installation and configuration
    • List of all players with several stats on the start site
    • Language, search and sort function on the start site
    • Details for each player that shows all stats and achievements
    • Detail sections can be toggled visible and hidden
    • Pictures for almost each item and mob in the details (i'm working on the rest ;) )
    • Offset for times
    • Achievements can be turned off
    Requirements:
    Download Minestats rar
    Download Minestats zip
    Installation (open)

    1. Download Minestats
    2. Unpack and copy it to your webspace
    3. Make configurations (you have to edit the config.php wich is self explanatory)
    4. done ;)
    Todo (open)

    • opacity and background control with the config
    • admin-interface to manually edit the stats and achievemets (i.e. db failures)
    • implement stats from icommerce and dynamic market
    • some other stuff :)
    Changelog (open)
    Version 0.85
    • Time offset
    • Make achievements optional
    • Implement wolfs
    Version 0.82
    • Make it work with s&a 0.9
    • Some Bugfixes
    Version 0.8
    • Code-cleaning (removed a lot of SQL statements, thanks to flames for the hint)
    • Added shortnames for day, hours, minutes and seconds in the language files
    • Opacity control in config
    • Added minecart and boatstats
    • Some bugfixes
    Version 0.7
    • Some changes in the configuration for more options
    • More items supported (for example the new repeater)
    • Release for entire community
    Version 0.6
    • Change in the language system for easier work
    Version 0.5
    • Better Design for the entire interface
    Version 0.4
    • Added sort function for the overview
    • Added more details
    Version 0.3
    • Added search function
    Version 0.2
    • Multi language support
    • Added more details
    • language selector
    Version 0.1
    • Overview of all players and details


    Bug reports, comments, and suggestions are always welcomed and donations appreciated.

    [​IMG]
     
    Chikken likes this.
  2. Offline

    PhotonLance

    can u give this on html ??? have problem with PHP (((
     
  3. Offline

    Abadon84

    this doesn´t work....
     
  4. Offline

    Jiggs

    Hi, this looks really great, however the host that I use is in a different time zone, and I was wondering if I can display the times in GMT somehow?

    At least I think it's because the host uses a different time zone?

    Thanks
     
  5. Offline

    Abadon84

    in the next update wich is coming on the weekend there will be an offset for the times and of course an update for mc 1.4
     
    Jiggs likes this.
  6. Offline

    MathijsNL

    Ok, this plugin is really great.
    I have 1 bug to report
    when your inventory is full, the stats plugin keeps counting all items it tries to pickup again.
    so now i got 4,5 mln item pickups, which are 1,5 mln bones, 1,5 mln feathers and 1,5 mln string :)
    so i have a spawner that works better then i expected, or its a bug :) i guess the 2nd one, because 4,5 mln drops in under 10 hours is impssible

    Greets mathijs
     
  7. Offline

    Iqualfragile

    i have got nearly the same bug as mystixwun, the php-page just stops generating

    sourcecode:
    HTML:
    <html>
    <head>
    <title>Minestats -> Iqualfragile-Reich</title>
    <link rel="stylesheet" type="text/css" href="style.css">
        <script type="text/javascript" language="JavaScript">
            <!--
            //create onDomReady Event
            window.onDomReady = initReady;
            // Initialize event depending on browser
            function initReady(fn)
            {
                //W3C-compliant browser
                if(document.addEventListener) {
                    document.addEventListener("DOMContentLoaded", fn, false);
                }
                //IE
                else {
                    document.onreadystatechange = function(){readyState(fn)}
                }
            }
            //IE execute function
            function readyState(func)
            {
              // DOM is ready
                if(document.readyState == "interactive" || document.readyState == "complete")
                    {
                        func();
                    }
            }
            window.onDomReady(onReady);
    
            //do when DOM is ready
            function onReady()
            {
                var divs = new Array("achievements","block_des","block_cre","item_use","item_dro","item_pic","dam_dea","dam_tak","kills","deaths");
                document.getElementById('details').style.display='block';
                for (var i in divs){
                    document.getElementById(divs[i]).style.display='none';
                }
    
            }
    
            function toggle(item){
                var e=document.getElementById(item);
                var t=document.getElementById("toggle_"+item);
                if(e.style.display=="none"){
                    e.style.display="block";
                    t.src = "img/close.png";
                } else {
                    e.style.display="none";
                    t.src = "img/open.png";
                }
            }
                //-->
        </script>
    </head>
    <body>
    <div id="frame">
    <div id="header" style="opacity: 0.8;">
        <h1><a href=""> Minestats: Iqualfragile-Reich</a></h1>
    
        <div id="form">
        <form name="header" action="" method="GET">
                <select style="width:120px;"  name="lang" onChange="location.href='?lang='+this.options[this.selectedIndex].value">
                    <option value=de >de</option>
                    <option value=1337 selected=selected>1337</option>
                    <option value=es >es</option>
                    <option value=fr >fr</option>
    
                    <option value=en >en</option>
                </select>&nbsp;&nbsp;<input type="image" src="img/lang.png" alt="language" width="15px" height="15px"><br><br>
                <input type="text" name="search" size="15" maxlength="30">&nbsp;&nbsp;<input type="image" src="img/search.png" alt="search" width="15px" height="15px">
        </form>
        </div>
    
     
  8. Offline

    TheShadow777

    hey i become this error:
    Fatal error: Call to a member function fetch_assoc() on a non-object in /var/www/web90/html/stats/minestats.php on line 138
    what can i do ? :(
     
  9. Offline

    jor956

    I'm getting this error:
    Code:
    Errormessage: Errormessage: Errormessage:
    Warning: Invalid argument supplied for foreach() in /home3/teammcne/public_html/minestats/minestats.php on line 120
    Could somebody help?

    The part where it says "foreach" in minestats.php is like this by the way:
    Code:
    foreach($this->players as $name => $player){
                //convert playtime
                $days = floor($player['playedfor'] / 86400);
                $player['playedfor'] -= $days * 86400;
                $hours = floor($player['playedfor'] / 3600);
                $player['playedfor'] -= $hours * 3600;
                $minutes = floor($player['playedfor'] / 60);
                $this->players[$name]['playedfor_form'] = array('days'=>$days,'hours'=>$hours,'minutes'=>$minutes);
                //check for light-saving-time
                if ($this->players[$name]['lastlogin']){
                if (date("I",$this->players[$name]['lastlogin'])){$this->players[$name]['lastlogin'] += 3600;}
                }
    Any help?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 12, 2016
  10. Offline

    sypheac

  11. Offline

    Abadon84

    it seems that it can`t get any players out of the database... have you set it correct in the config?
    same for the other errors, the most seems to be database errors

    ok, the update is near but today our hoster is a little bit down... because of that i will release it tommorow

    this is an issue of the plugin, not of my viewer ;)

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 12, 2016
  12. Offline

    jor956

    I have pointed the stats and acheivments to the same database, it should all work, but it gives me that error :confused:
     
  13. Offline

    Zeroi9

    Hi!
    Nice plugin, well, I haven't gotten mine working yet.
    This is the error:
    PHP:
    Connect Error (2002Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
    According to my host support, it's not because of the config.php, it's the other part(which?) that isn't working.
    Hope you can help me.
     
  14. Offline

    Josh Ice

    I'm getting an error on the screen. When the page loads, it looks like it's fine in the background, but there's a few errors over them. They look like this.
    Code:
    Notice: Undefined index: player in C:\wamp\www\Minecraft\index.php on line 122
    Call Stack
    #TimeMemoryFunctionLocation
    10.0006781368{main}(  )..\index.php:0
    
    Notice: Undefined index: search in C:\wamp\www\Minecraft\minestats.php on line 104
    Call Stack
    #TimeMemoryFunctionLocation
    10.0006781368{main}(  )..\index.php:0
    20.01291008056minestats->get_stats(  )..\index.php:123
    
    Notice: Undefined index: sort in C:\wamp\www\Minecraft\minestats.php on line 161
    Call Stack
    #TimeMemoryFunctionLocation
    10.0006781368{main}(  )..\index.php:0
    20.01291008056minestats->get_stats(  )..\index.php:123
    
     
  15. Offline

    Abadon84

    turn of the php-notices in the php.ini, then it should work

    btw here a german achievements table: http://pastie.org/1782183

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 12, 2016
  16. Offline

    Zeroi9

  17. Offline

    Abadon84

    id dont know wich other part do you mean, it seems like a problem of the server, not of minestats
     
  18. Offline

    Josh Ice

    @Abadon84 Thank you man, it worked, however it wasn't called php-notices but instead it was a switch called error_reporting where you could define what types of errors to be displayed. Thanks again and great plugin!
     
  19. Offline

    Abadon84

    so, update is there... for changes see the changelog ;)

    yeah, but in the error_reporting flag you turn off the notices ;)

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 12, 2016
  20. Offline

    Zeroi9

    It was Minestats, this is what they told me:
    "...... removed a problem with it in the configuration file - at one place the variable for the database was host, and at another place it was server."

    Another problem.
    I went into the /stats/ directory on my website. The template etc worked fine, except it said "Errormessage: Errormessage: Errormessage:" and there was no stats to see.
     
  21. Offline

    Abadon84

    have you set up the database name and the tables correct?
     
  22. Offline

    Zeroi9

    I'll check that later tonight when I wake up. It's 6:21 AM here and I haven't slept for over 24 hours.
    Hope you're right.
     
  23. Offline

    Abadon84

    here too, im going to the uni now ;)
     
  24. Offline

    Iqualfragile

    i found out why it didn't work for me:
    i had just stats and no archivments.
    but now i have got another problem:
    whenever i open the site the
    Code:
    #     Name     Playtime     Created Blocks     Destroyed Blocks     Damage dealt     Damage taken     Achievements     last Login 
    line is over the first player.
     
  25. Offline

    Abadon84

    can you send me a link as pm so that i can have a look at it?
     
  26. Offline

    Zeroi9

    db:

    table: onlinelog

    -- Table structure for table `onlinelog`
    --

    CREATE TABLE `onlinelog` (
    `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
    `timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
    `playercount` smallint(5) unsigned NOT NULL,
    `playernames` varchar(4096) CHARACTER SET ascii NOT NULL,
    PRIMARY KEY (`id`),
    KEY `timestamp` (`timestamp`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
     
  27. Offline

    Abadon84

    that is not a stats and achievements table... its some other statistic tool
     
  28. Offline

    Zeroi9

    Sorry, my fault.
    Uh, could you give me a sql to create the table?
    And also, in the stats plugin config, there's no host, only database, user, password, table.
    How do I configure the host?
     
  29. Offline

    Abadon84

    in the stats. properties:
    sql-db = jdbc:mysql://host:3306/database
    stats table:
    Code:
    CREATE TABLE IF NOT EXISTS `stats` (
      `player` varchar(32) NOT NULL default '-',
      `category` varchar(32) NOT NULL default 'stats',
      `stat` varchar(32) NOT NULL default '-',
      `value` int(11) NOT NULL default '0',
      PRIMARY KEY  (`player`,`category`,`stat`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
    achievements table:
    Code:
    CREATE TABLE IF NOT EXISTS `playerachievements` (
      `player` varchar(32) NOT NULL default '-',
      `achievement` varchar(128) NOT NULL default '-',
      `count` int(11) NOT NULL default '0',
      PRIMARY KEY  (`player`,`achievement`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
     
  30. Offline

    ouyso

    Thanks!
    I am working on a user system for my server atm. and this will really come in handy, I am currently using authdb which lets me link my forums, user system and most importantly the server together, which is great.

    This plugin will most definitely come in handy for profiles etc!
    - Again, thanks!
     
  31. Offline

    Penorzilla

    I get this error when trying to load the webpage that my stats is under.
    Code:
    [B]Warning[/B]:  mysqli::mysqli() [[URL='http://penorzilla.com/stats/mysqli.mysqli']mysqli.mysqli[/URL]]: (HY000/2003): Can't connect to MySQL server on '24.245.59.186' (111) in [B]/homepages/36/d346498371/htdocs/wsb6082047601/stats/minestats.php[/B] on line [B]26[/B]
     Connect Error (2003) Can't connect to MySQL server on '24.245.59.186' (111)
    
    The minecraft server and the web hoster are on two different networks.

    I previously ran this when the MC server and MySQL DB were on a windows 7 machine. Now I upgraded to linux and I opened the port 3306 thru linux firewall but I still get this issue. I'm sure I opened it incorrectly or only opened it for incoming and not outgoing.

    My settings file is like this:
    Code:
    <?php
        $config['server']                 = '24.245.59.186';                       //database-server (the IP of my MC server and MySQL DB)
        $config['user']                 = 'root';                            //database-user
        $config['pass']                 = '********';                            //database-pass
        $config['db']                     = 'netstats';                        //database
        $config['table_stats']            = 'stats';                            //table for stats
        $config['table_achievements']    = 'playerachievements';                //table for achievements (let it empty if you don't use it)
        $config['lang']                    = 'en';                                //standard language (look in the lang folder for avaible languages or write your own there and send me ;) )
        $config['servername']            = 'Penorzilla';            //displayed Servername
        $config['date']                    = 'd.m.Y H:i:s';                    //format of the timestamp (for details see http://php.net/manual/de/function.date.php)
        $config['offset']                = '0';                                //offset for the dates in hours    
        $config['opheadfoot']            = '0.8';                            //opacity header and footer
        $config['optable']                = '0.8';                            //opacity table
    ?>
    
    Any help? I'm sure it has something to do with linux and opening the MySQL port so my domain hoster can receive the data. Please help.
     

Share This Page