BeardStat

BeardStat is statistics tracking plugin for bukkit. It tracks a wide variety of user statistics and makes them available to your playerbase and plugins.
Recorded stats
- last Login and logout time
- Total playtime
- block placement and breaking (including sub/metadata blocks like wool, logs etc)
- Items picked up/dropped
- Damage dealt and recieved
- Kills and deaths
- Food consumed
- Sheep sheared and dyed
- TNT detonated
- Distance travelled on foot/boat/cart/horse/pig
- Items crafted
- Animals tamed
- Teleports
- Fishing
Web interface (under development)
BeardStat also comes with a web interface for stats, this allows players to view their own and friends stats on your servers website. the Web interface also includes a scoreboard system to rank players based on various statistics (playtime, creepers killed)
Commands
Stats are recorded per world, and you can blacklist worlds/gamemodes from tracking. BeardStat also has a number of commands: * /stats - access to all stats information * /played - shows a players playyime. * /laston - Returns the last time the player was on * /statpage - Allows showing a selection of player stats, useful with Bukkit's command aliasing
Dev builds
Development builds of this project can be acquired at the provided continuous integration server.
These builds have not been approved by the BukkitDev staff. Use them at your own risk.
(Please note, zips in dev builds currently contain a broken implementation of the web interface, please instead download the .jar file instead. The web interface available on the right of this page) Development builds fresh from Jenkins
Issues
BeardStat has an issue tracker on github, https://github.com/tehbeard/beardstat/issues.
For error reports please include the following: * full stacktrace of the error * plugin version (inc. build number if using one from CI) * Bukkit version * Database type used (SQLite / MySQL)
Plugin integration
BeardStat provides a rich API for plugin developers to hook into BeardStat and read / record statistics.
For Developers
BeardStat stats are identifiable by a unique Id generated from 4 sub components: * Domain * World * Category * Statistic
Domain is the primary namespace for a collection of stats, the "default" domain is used by BeardStat, I ask that you use your own unique domain for your plugin (i.e. if you make a PvP arena plugin, you could use the domain "pvparena").
World represents the world in which this stat was recorded, these are for the most part the name of the world.
Two special cases exist however. "__global__" is a reserved world name, meant for stats that do not pertain to a world. The second case is "__imported__", this is a reserved world for stats that have been imported from an older version of BeardStat before per world storage was implemented.
While not intended, you can use the world id for a unique area that is not a whole world (Going back to our pvp arena example, you could use the arena names instead, such as old_forge, broken_bow instead of a world name)
Current plugins that are known to integrate BeardStat: * BeardAch - Achievements plugin * SimpleSpleef Evolution
Metrics
BeardStat includes the plugin metrics code developed by Hidendra (author of LWC), which collects anonymous information about the plugins deployment (minecraft, server, plugin version, assumed server location at country level and database type used by BeardStat, aggregated into graph form.) More information on this system, including how to disable it can be found here
-
View User Profile
-
Send Message
Posted Jul 28, 2012@TerraVale
None of that needs to be worked out by the plugin, the plugin just stores data, it is up to you, as the user of the plugin, to pull the information out from the database how you need it.
In saying that, SQL has a lot of functions and queries at its disposal to do exactly what you want it to do.
Depending on what web language you are using (eg. PHP) you also have all the functions it supports to help you in your endeavour.
In saying that, yes, to do what you want is very easy, but it isn't up to the plugin to do it, it is up to you to pull the information out that way.
-
View User Profile
-
Send Message
Posted Jul 28, 2012Hi! I was wondering if it would be possible, using your plugin, to display a leaderboard on my website. Before you tell me I should read the description of your plugin, I'm asking about the specifics, not the fact that it runs an online leaderboard :)
This is what I'd like to do: Display how many hostile mob kills a person has gotten, over one lifetime. The leaderboard (in my mind) would essentially go as follows...
Player | Overworld Hostile Mob Kills | Underworld Hostile Mob Kills | Total Kills | Alive (Y/N) | Lifetime
I wish to have it calculate a leaderboard that totals up all hostile-only mob kills over one lifetime, and I wish to have it say if the person is still alive or not in that lifetime. The person being alive part is optional, but it seems like a liable idea. And when the person dies, their hostile mob kill count is reset and they start over again, trying to get to the top however their record on the leaderboard would still stay. I very much hope your plugin can accommodate to my needs? :D
-
View User Profile
-
Send Message
Posted Jul 27, 2012@Tehbeard
I wouldn't have thought so, it is possible though i guess.
Server time is (at time of this reply) Sat Jul 28 02:32:30 CEST 2012, the server is hosted in germany, which puts it about 6hrs behind me (i'm +8GMT Perth).
-
View User Profile
-
Send Message
Posted Jul 27, 2012@ray73864
Dev Bukkit is being a tard and not showing your latest comment to me (I can see the first part in the email notification). I've re-examined the code and cannot see anything that would obviously cause this. As well this is the first time I've heard this type of bug.
since played time is dependent on the system timestamp, is it possible the server's (physical, not bukkit process) time/date might have changed while bukkit was running?
-
View User Profile
-
Send Message
Posted Jul 27, 2012Not that i know of, it was basically, he logs on, he griefs the crap out of stuff, we /ban, he's gone.
That one isn't the only person with a messed up 'played for' either. He's the first one we noticed though because we knew he was a new player.
-
View User Profile
-
Send Message
Posted Jul 27, 2012@ray73864
Hmm, have you per chance ran /reload at some time when he might have been on? It could be another latent issue with /reload in my code.
-
View User Profile
-
Send Message
Posted Jul 26, 2012@Tehbeard
Yes, it is indeed. We had no player files or essentials userdata files for him prior to the 'First Login' time.
-
View User Profile
-
Send Message
Posted Jul 26, 2012@ray73864
Is this a player who had just joined the server?
-
View User Profile
-
Send Message
Posted Jul 26, 2012Couldn't find where to post tickets, so here will do.
Beardstat is giving us strange playtimes for players, one player, that we had to ban yesterday due to him massively griefing, shows up in beardstats as:
Dartime(Banned) playtime 13h 37m 45s, joined 26-Jul-2012 03:24 last login 26-Jul-2012 04:02.
I've checked the firstlogin, lastlogin and lastlogout times and they are perfectly accurate.
However, the 'playedfor' field in the database for that player has '49065' in it, which converts to 13h 37m and 45s.
If you subtract the time from the first login to the last logout, it doesn't even come close to that.
First Login according to the database: Thu, 26 Jul 2012 01:24:00 GMT
Last Login according to the database: Thu, 26 Jul 2012 02:02:25 GMT
Last Logout according to the database: Thu, 26 Jul 2012 02:03:52 GMT
As you can see, that does not add up to 13.5hrs.
-
View User Profile
-
Send Message
Posted Jul 20, 2012@Chemical_Datas
That's another plugin you're running doing something incredibly funky (damaging someone by a negative amount, in effect healing them).
-
View User Profile
-
Send Message
Posted Jul 19, 2012Didnt think that youd get this error?
2012-07-19 21:20:44 [SEVERE] Could not pass event EntityDamageByEntityEvent to BeardStat org.bukkit.event.EventException at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:304) at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) at org.bukkit.plugin.TimedRegisteredListener.callEvent(TimedRegisteredListener.java:30) at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:460) at org.bukkit.craftbukkit.event.CraftEventFactory.callEntityDamageEvent(CraftEventFactory.java:363) at org.bukkit.craftbukkit.event.CraftEventFactory.handleEntityDamageEvent(CraftEventFactory.java:381) at net.minecraft.server.EntityLiving.damageEntity(EntityLiving.java:608) at net.minecraft.server.EntityMonster.damageEntity(EntityMonster.java:38) at net.minecraft.server.EntityHuman.attack(EntityHuman.java:750) at net.minecraft.server.EntityPlayer.attack(EntityPlayer.java:129) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:998) at net.minecraft.server.Packet7UseEntity.handle(SourceFile:33) at net.minecraft.server.NetworkManager.b(NetworkManager.java:229) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:113) at org.getspout.spout.SpoutNetServerHandler.a(SpoutNetServerHandler.java:172) at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:78) at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:567) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:459) at net.minecraft.server.ThreadServerApplication.run(SourceFile:492) Caused by: java.lang.IllegalArgumentException: Cannot increment by negative number! at me.tehbeard.BeardStat.containers.StaticPlayerStat.incrementStat(StaticPlayerStat.java:59) at me.tehbeard.BeardStat.listeners.StatEntityListener.onEntityDamage(StatEntityListener.java:91) at sun.reflect.GeneratedMethodAccessor379.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ... 18 more
-
View User Profile
-
Send Message
Posted Jul 13, 2012Amazing plugin! Can't wait for MCMMO support.
If anyone wanted to see it in usage, have a looksy here:
http://stats.restormelpvp.net/
-
View User Profile
-
Send Message
Posted Jul 12, 2012@GeneralShep
1) McMMO support will be along within the next few weeks.
2) The copyright is in the headers of the files, not displayed to the end user. the tl;dr is that you can mold how the web page looks without restriction, and even give that look to others to use, but you cannot claim the underlying php code that does the magic of database->web browser as your own.
3) the <<>> stuff does insert the reply link with the little arrow icon as well :)
-
View User Profile
-
Send Message
Posted Jul 12, 2012@Tehbeard
Okay thanks! Also this is a really epic plug-in. I saw down there like 5 comments below saying you might be able to add McMMO stats to this, just saying that would be awesome. Really great plug-in you have here, makes people more active and competitive to be the top on the lists.
Oh also, I didn't find a single copyright actually displayed on the webpage, was that intended because in the whatever I read before it said not to remove and copyright from the files.
Lastly how do you reply properly lol, when I click on reply it adds like <
<<Reply 126525124>>>, does this transfer to be Username (Link to post)-
View User Profile
-
Send Message
Posted Jul 12, 2012@GeneralShep
hmm, furd missed out the header section. find the line with <style>, before it, place this
-
View User Profile
-
Send Message
Posted Jul 12, 2012Loving this in Beardstat.php
You may not eat Cheese whilst working on Layout scripts for the BeardStat Web API. This is strictly enforced. loljk.
Erhm, I'm kinda new to php and whatever else this magnificant plug-in has to offer, but where can I change the title of the webpage? I put <title=5Diamonds | Stats</title> In the index.php yet it still doesn't show, anyone feel like helping a newbie :3
-
View User Profile
-
Send Message
Posted Jul 11, 2012@moose517
Yeah, remove them and restart the server, it'll start recording all the stats :)
-
View User Profile
-
Send Message
Posted Jul 11, 2012@Tehbeard
i thought that was to make them work LOL. so i should remove the world names from the configs?
-
View User Profile
-
Send Message
Posted Jul 11, 2012@moose517
Did you put your worlds into the blacklist? (worlds: in config.yml), that'd cause it.
-
View User Profile
-
Send Message
Posted Jul 11, 2012I've used the old stats and achievements plugins and seeing as you made your database work with that i switched to it. but looking at the stats things like arm swings and playtime are being recorded but the blocks aren't. Any ideas? (I'm running grapefruit)