Stats by Lolmewn
Stats - made by Lolmewn
Plugin description
Stats is an advanced statistics gathering plugin, currently focused on player statistics. Information such as PVP kills, blocks broken, playtime and much more. You can store this data as simple files, or store them in a MySQL database. The benefit of using the database is that you can also use any web-end out there to display your players' statistics on your website.
Installation instructions
To install the plugin, simply drag-and-drop the Stats.jar into your 'plugins' folder.
When you start the server, a "Stats" folder will be created, containing a config file.
For a detailed description on the config file, click here.
The most important option is "storage", which can be set to either "flatfile" or "mysql" by default.
If you choose MySQL, there is another file (mysql.yml). Fill in your MySQL details there. That's all!
If you're installing a web-end as well, please read the instructions for said web-end on how to install it.
A list of web-ends compatible with Stats 3:
Made one, too? Let me know!
List of available Stats
This is a list of all available stats. Please note that there might be more stats in your environment, as other plugins can add their own stats to the plugin. For those stats, please see the documentation of the plugin providing them.
Stat name | Description | Available Metadata |
Arrows | Amount of arrows shot (not hit!) | world |
Beds entered | Self-explanatory | world |
Blocks broken | Self-explanatory | world, name, data (see here for more info) |
Blocks placed | Self-explanatory | world, name, data (see here for more info) |
Buckets emptied | Self-explanatory | world |
Buckets filled | Self-explanatory | world |
Commands done | Amount of commands done | world |
Damage taken | Self-explanatory | world, cause |
Death | Amount of times died | world, cause |
Eggs thrown | Self-explanatory | world |
Fish caught | Self-explanatory | world |
Items crafted | Self-explanatory | world, name |
Items dropped | Self-explanatory | world, name |
Items picked up | Self-explanatory | world, name |
Joins | Amount of times joined the server | None |
Kill | Amount of kills gotten | world, (name of) weapon, entityType |
Last join | Last time (in milliseconds epoch time) joined the server | world |
Last seen | Last time (in milliseconds epoch time) left the server | world |
Money | Not yet functional | world |
Move | Amount of blocks moved | world, type (0 = walking, 1 = boat, 2 = minecart, 3 = pig, 4 = on a pig in a minecart, 5 = horse, 6 = flying) |
Omnomnom | Amount of food eaten | world |
PVP | PVP kills gotten | world, victim (UUID of the other player), time (in milliseconds epoch time), (name of) weapon |
PVP streak | Current kill-chain, gets reset when killed | world |
PVP top streak | Highest PVP streak ever achieved - may be moved to Highscores in the future | world |
Playtime | Time in seconds played on the server | world |
Shears | Amount of sheeps sheared | world |
Teleports | Amount of times teleported | world |
Times kicked | Self-explanatory | world |
Tools broken | Self-explanatory | world, name |
Trades | Amount of times traded with a villager | world |
Votes | Removed since 3.1.1-RC due to incompatibility. If the player name is not found, the vote is ignored | None |
Words said | Amount of words said | world |
Times changed world | Self-explanatory | None |
Xp gained | Amount of XP gained in total | world |
Permissions
Some commands require special permissions to be executed. Here is a list with all permission nodes:
Node | Default value | Description |
stats.view | true | Access to /stats |
stats.view.others | true | Access to /stats <player> |
stats.custom | op | Gives access to nodes stats.add and stats.create |
stats.add | op | Access to /stats add |
stats.create | op | Access to /stats create |
stats.admin | op | Access to /stats admin |
stats.reset | op | Gives access to nodes stats.reset.self and stats.reset.others |
stats.reset.all | op | Access to /stats reset all |
stats.set | op | Access to /stats set |
stats.sign.place | op | Can create [Stats] signs |
More info soon
Donations
If you feel like giving something back to me, you can donate to me. All income from donations will be spent on coffee or similar.
I'm accepting donations through:
- Bitcoins on address 1QC19kut8nuMJNAsMZ3QneKuW2a8f5QgQG
- Dogecoins on address DKN8Lrm4KfC7Jh9M2KopjPkwcRfA7Ak3zj
- Paypal, either via email lolmewn(at)gmail.com or via this link
@bjornleijdstrom
Something went wrong during conversion, if you could find that error it would be mega helpful! I would suggest you go back to Stats 2 for now though ;)
Hey@Lolmewn, getting this error using latest dev (like all the time, kinda spams): http://pastebin.com/4UDA9WZQ
@WhosHenry
I'm not sure what's causing it - so probably not.
@vipersonickenneth94
That's from Achievements, that's something completely different :P
@EnderSandman
You can change the prefix for each server, or change the database for each server.
I am still using Stats 2. I have several Minecraft servers connect with bungeecord and I now want to have separate stats for each server. How should I keep the Stats data separate for each server? Do I need to use flatfile storage or separate MySQL databases for each Minecraft server? I dont see a way to keep the data separate using the same database for all servers.
BTW, awesome plugins! The graphical interface for achievments is great with the hover overs so players can see achievement goals and rewards. Can't wait to see the updated version of that one.
@Lolmewn
@Lolmewn Thanks. However, I still receive an error when players log in: Pastebin
@Lolmewn
Is there still nothing I can do to stop the playtime counting twice in the meantime until Stats 3 is ready?
@vipersonickenneth94
Read all the way at the top - you are currently using Stats 3. Should probably go back to Stats 2.
Hi,
There's a problem with Stats whenever a player joins:
Pastebin
I've seen from your video on the page here that those empty data tables are for Stats 3. Makes sense now but I still need to know why the playtime is being counted twice :S
@Lolmewn
This is my current version - [Stats] Loading Stats v2.0.1-272
Also, I'm not particularly proficient in MySQL, I'm learning about it recently, but I've had it up and running ever since the start of my Server.
I am looking at the MySQL Tables now and it seems that there are a load of ones for Stats but the only ones with data in are Stats_player and Stats_players. As you can see from this print screen the arrows database doesn't have anything in - http://prntscr.com/6sfg9h
I'm just wondering how exactly it's stored and what I need to do in order to make a backup.
@WhosHenry
Version in config isn't very reliable (yet), better to see what it says on startup. Does 1.35 also do the double playtime? If it's not actually Stats 2, that is.
@Lolmewn
The config on my Survival server says it's using v 1.35. I had update to false for this one, so this didn't actually auto-update to Stats 3, but 3 other servers under the network did.
I never use /reload, always start/stop the server.
Edit: The Stats version in the config shouldn't actually say 1.35. Because I am using v2.
@WhosHenry
What build are you using? Also, you didn't happen to reload? ;o
Well the auto-update messed up 3 of my servers, I managed to just stop them and just put in the old configs and jar I had stored. But on my main Survival server now, it seems to be counting the playtime twice... So every 5 seconds, the playtime has gone up by 10 seconds.
What can I do to stop this?
What did I learn from this?
Never, never, again, auto-update anything. Always, if needed, send a message instead notifying users an update is available. Much safer.
@GodsDead
Yep, I definitely messed up this one. :c
@Lolmewn
Ok, Im doing server repairs now, What I have noticed so far: My stats_move was corrupted: #144 - Table './piratecr_stats/Stats_move' is marked as crashed and last (automatic?) repair failed from phpmyadmin I noticed this after rebooting with stats2 jar it threw the error: [11:35:20] [Server thread/WARN]: [Stats] The above warning was probably thrown by this statement: CREATE TABLE IF NOT EXISTS Stats_move(counter INT AUTO_INCREMENT NOT NULL PRIMARY KEY , player_id INT NOT NULL , world VARCHAR(255) NOT NULL DEFAULT 'PirateCraft_1' , type INT NOT NULL , distance DOUBLE NOT NULL DEFAULT 0 )
Also in your video you state that stats.jar gets renamed to stats3.jar this did not happen, mine was stats.jar.
Another thing that ive never seen and can only assume this was stats, was in my plugins directory a 0kb plugin called plugins/download?version=19852.jar was in there that created an error at startup.
What a mess...
Edit: Just downloaded a backup of my SQL database from the 6th to pull the stats tables, its 189MB, this is going to be fun to upload/extract the tables I need :(
@GodsDead
April 7, 14:14 UTC. Might be couple of hours later due to approval delay. It will not download again since it now has the -DEV tag in the title, I was being silly and forgot to add it when I uploaded it since I thought I remembered setting it to alpha would also ignore it for updates.
@Lolmewn
It happened while I was away for 5 days, If you can give me an exact time and date it was released I might be able to search the logs easier :)
Also, Since I need to revert back to the older version, Will it just continue to auto update to the development version? I have update: false set in my old config.yml