[INACTIVE][INFO] Stats [v0.99] and Achievements [v0.99][1000]

Discussion in 'Inactive/Unsupported Plugins' started by nidefawl, Jan 20, 2011.

  1. Offline

    nidefawl

    Stats and Achievements

    This plugin will be found at dev-bukkit soon
    sockenklaus will manage this project in the future (thank you!)

    Features:
    • Stats
      • Logs many actions that players do!
      • Block Destoys(for each block), Item Uses, Damage Dealt, Deaths per type, Kills per type, Played-Time (with AFK flags!)...
      • '/stats' shows basic stats and more
      • '/played' shows your play-time on the server
      • Keeps all stats within a SQLite or MySQL Database
      • Your plugin can support Stats!
    • Achievements
      • Give users achievements when they have completed something!
      • e.g. MintyAnt mined 500 obsidian. Message "You have no life!" Appears, and they recieve the "No Life" achievment and 10 Diamond as a prize
      • Achievement-Conditions:
        • <achievement-name>
        • New in 0.9:
          • group <group-name>
          • permission <permissionstring>
        • can be multiple seperated by ;
        • each of them can have a inverting '!' (!group jailed;!badachievement)
        • can be none of course :)
      • Reward-Commands:
        • /item <name or id>
        • /money <negative or postive amount>
        • /group <group-name>, /warp <warp-name>
        • New in 0.9: Native console commands:
          • /op *;/time 13500;/god *;/kick *
          • use any console command that works on your console
        • New in 0.9 (GroupManager):
          • addsubgroup <groupname>
          • removesubgroup <groupname>
          • addpermission <permissionstring>
          • removepermission <permissionstring>
    Source:
    Download:
    Newest (Fix for updated plugins (iConomy, BOSEconomy, Essentials, Permissions 3)
    Old (Tested with #617 (works up to 1000!))
    If you still have problems with CraftIRC or iConomy + Achievements try one of the following version:
    Outdated versions:
    Configuration:
    Permissions for v0.9+:
    Show Spoiler

    Achievements:
    achievements.check - only players that have that permissions will be checked + awarded
    achievements.view.own - grants access to /achievements (/ach)
    achievements.view.list - grants access to /listachievements (/listach)
    achievements.admin.check - grants access to /checkachievements (/chekcach)
    achievements.admin.reload - grants access to /reloadachievements (/reloadach)

    Stats:
    stats.log - only actions of players that have that permissions will logged
    stats.view.own - allows a player to watch his own stats with the /stats command
    stats.view.others - allows a player to watch other players stats with the /stats <player> command
    stats.view.playtime - allows a player to watch his play-time with the /played command
    stats.admin - grants access to /stats debug + /stats set + /stats list

    Latest Changes:
    Show Spoiler

    Stats v0.99
    • Fix for Permissions 3.0
    Stats v0.985
    • Permissions fixed
    • Code cleanup
    • More settings, to disable logging of some events
    Stats v0.98
    • Attempt to fix plugin dependencies
    Stats v0.972
    • Attempt to fix Classpath and Updater... again
    Stats v0.96 (03-04-11)
    • Forgot to update internal version
    • Forgot wolf
    Stats v0.95 (03-04-11)
    • Updated to latest RB (617)
    • Better Permissions/GroupManager plugin handling
    • removed the usage of os-specific sqlite libraries. (lets see what happens)
    Achievements v0.99
    • Fix for newest Economy plugins
    Achievements v0.981
    • Attempt to fix plugin dependencies
    • fixed a typo with the 'achievements-definitions-sql'. Check your config!
    Achievements v0.972
    • Attempt to fix Classpath and Updater... again
    Achievements v0.96 (03-04-11)
    • Forgot internal version
    • Forgot wolf
    Achievements v0.95 (03-04-11)
    • Updated to latest RB (617)
    • Better warp-command handling for Essentials


    full Stats changelog
    full Achievements changelog

    Supported plugins:
    Tools:
    Please donate --> [​IMG]


    Please read the Wiki before posting:

     
  2. Offline

    nidefawl

    What is broken?
     
  3. Offline

    scar413

    for me, essentials and achievements are running just fine.
     
  4. Offline

    prom3th3an

    17/02/2011 11:28:22 AM org.bukkit.craftbukkit.CraftServer loadPlugins
    SEVERE: PLAYER_PICKUP_ITEM (Is it up to date?)
    java.lang.NoSuchFieldError: PLAYER_PICKUP_ITEM
    at com.nidefawl.Stats.Stats.initialize(Stats.java:623)
    at com.nidefawl.Stats.Stats.onEnable(Stats.java:573)
    at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:135)
    at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader
    .java:410)
    at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManage
    r.java:175)
    at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:74)
    at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:55)
    at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:169)
    at net.minecraft.server.MinecraftServer.c(MinecraftServer.java:156)
    at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:108)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:207)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:512)

    On startup.
     
  5. Offline

    kipz0r

    Which version of bukkit/craftbukkit are you running?
    --- merged: Feb 17, 2011 4:23 PM ---
    I've got problems with achievements, somehow my server stops when I type /reloadachievements and I don't need another stop command...

    this is where it happens:

    Code:
    [SIZE=12px][FONT=Helvetica]2011-02-17 17:14:29 [INFO] [Achievements-0.51] Found required plugin: Stats[/FONT][/SIZE]
    
    2011-02-17 17:14:29 [SEVERE] [Achievements-0.51] SQL exception
    java.sql.SQLException: The url cannot be null
    2011-02-17 17:14:29 [INFO] [Achievements-0.51] Loaded Player 'kipz0r'
    2011-02-17 17:14:29 [INFO] [Achievements-0.51] Achievements 0.51 Plugin Disabled
    2011-02-17 17:14:29 [INFO] Stopping server
    what is the "the url cannot be null" part?


    I'm running minecraft on a debian server, achievements and stats work with mysql.


    My problems was as well that the config files created by stats and achievements were different than the ones in your documentation, stats.properties is as follows:
    Code:
    stats-autoUpdate = true
    stats-datasource = mysql   #dropped flatfile support
    stats-deathnotify = true
    stats-debug = false
    stats-login-delay = 3600   #limit between login-count increases
    stats-message-prefix = &e[Stats]&f
    stats-save-delay = 30   #delay between automatic saving (seconds)
    
    (I changed sqlite to mysql)

    and achievements.properties was empty.

    can you post a working achievements.properties or can I take the one posted in your documentation?


    Thanks in advance,



    Kip
     
  6. Offline

    brafenschlug

    It would be awesome to see stats on how much fish(cooked/raw)/bread/cake/meat/apples/etc a player has eaten! Is this possible?
     
  7. Offline

    nidefawl

    what says you mysql.properties in the craftbukkit root?

    the wiki is not updated yet, sorry

    Will check it
     
  8. Offline

    kipz0r




    Code:
    sql-db = jdbc:mysql://localhost:3306/minecraft
    sql-pass = <somepass>
    sql-table-stats = stats
    sql-user = <someuser>
    
    With this, the stats are working and filling etc.
    I've been able to use the stats from the old stats plugin and that works flawlessly. Achievements just don't want to accept "/reloadach"



    No worries :)

     
  9. Offline

    uyuyuy99

    No commands related to essentials will do anything (there will also be no motd on login). Do you have any idea why this is happening?
     
  10. Offline

    nidefawl

    Well there seems to be a problem with /modgrp command of Essentials.
    Other than that it works fine with the latest set of Essentials plugins
    --- merged: Feb 18, 2011 6:31 AM ---
    are you using achievements 0.51, stats 0.52 and craftbukkit build > #328?
    i dont see the following entry in your mysql.properties:
    Code:
    sql-table-achievements = playerachievements
     
  11. Offline

    uyuyuy99

    When I tried to add some addons to essentials (/warp, /spawn, etc.) I had this same problem. Maybe there's some kind of conflict with another plugin?...
     
  12. Offline

    nidefawl

    could you please try out version 0.52 of Achievements and report back? I uploaded it right now.
     
  13. Offline

    wilsonc91

    Would I typically see better performance using SQLite or MYSql for this?
     
  14. Offline

    nidefawl

    I think there is no big difference as stats are cached and only pushed to database every save interval
     
  15. Offline

    kipz0r

    Yes,
    I've downloaded the latest versions from here, and I'm using it on build, ahhh, 326. /me slaps himself with an RTFM paddle. I guess that went wrong somewhere in my head. I'll update my craftbukkit as well :)

    Ah, I'll put that in right now and check if it works.


    Cheers, a slightly embarrassed, kip...

    edit:

    Right, I've updated craftbukkit, removed the configfiles etc. and restarted the server. Still the same issue, when I type /reloadach minecraft server crashes.
    Have you got a complete set of configfiles?

    edit2:
    I've updated CraftIRC from 1.68c to 1.70b and when I try anything with achievements now it kicks me from the server with a "Disconnected by server, internal server error" error on the client, and a
    Code:
    2011-02-18 14:21:32 [WARNING] Failed to handle packet: java.lang.NullPointerException 
    on the server

    edit3: When trying to do /reloadach or anything else with an empty achievements.txt file, it will crash for me with that nullpointerexception.
    I've now filled my achievements.txt with 1 achievement, reloaded the minecraftsettings (so /reload not /reloadach) achievements installed the 1 achievement, and now everything works.
    Let's see if I can break some other stuff now :D

    Cheers,


    Kip

    Recap:
    Stats 0.52
    Achievements 0.51
    Craftbukkit #337
    CraftIRC 1.70b
    Still had to make some manual changes and additions to the config files.
     
  16. Offline

    uyuyuy99

    I figured out that it was because of my craftbukkit version, which is weird, because I had 331 before, so it should've worked. Thanks anyway :)
     
  17. Offline

    nsmyrnos

    I was trying to use the Webstats PHP page linked in the OP, and went ahead and tried to install and prep a MySQL DB on my MC server. However, it looks like the Stats plugin went ahead and set up a SQL-Lite database on it's first run. Is the Webstats page still compatible with this plugin? I looked at the plugin wiki, but the config file settings for Stats don't seem to match those in my config file.
     
  18. Offline

    nidefawl

    wiki is not up to date
    just go to you stats.properties and set it to mysql instead of sqlite. the edit the mysql.properties in you bukkit root directory
     
  19. Offline

    nsmyrnos

    Thanks, that got me a bit further now. I was able to get the stats plugin to load using MySQL. However, after updating the DB settings on the settings.php file, I am still getting a messed up page. I added a screenshot with all of the error text if it's helpful.

    Settings.php snippet:

    //DATABASE SETTINGS/////////////////////////////////////////////////////////////////////////////////////////////////////////////
    $host = localhost:3306/mc_stats; //Host exp: localhost
    $user = <redacted>; //Username
    $pass = <redacted>; //Password
    $table = stats; //Databasename
     

    Attached Files:

  20. Offline

    Profanwolf

    I keep getting this error, it freezes the server temporarily on join/leave
    [​IMG]
    Scratch that , the error doesn't always happen, but the server does freeze up for half a second or so when someone joins or leaves, perfectly fine until someone leaves.
     
  21. Offline

    Maluzis

    Using /ach:
    Code:
    2011-02-19 14:11:41 [INFO]        test [/5.89.63.238:51242] logged in with entity id 4
            Player count: 1   
           2011-02-19 14:11:47 [INFO]        test tried command: login ****** 
                   java.net.SocketException: Connection reset   
            	at        java.net.SocketInputStream.read(Unknown Source)   
            	at        java.net.SocketInputStream.read(Unknown Source)   
            	at        java.io.FilterInputStream.read(Unknown Source)   
            	at        net.minecraft.server.Packet.b(SourceFile:102)   
            	at        net.minecraft.server.NetworkManager.f(SourceFile:157)   
            	at        net.minecraft.server.NetworkManager.c(SourceFile:15)   
            	at        net.minecraft.server.NetworkReaderThread.run(SourceFile:68)   
           2011-02-19 14:12:24 [INFO]        test lost connection: disconnect.genericReason
     
  22. Offline

    Joe_Young

    I have a problem in that some stats are regularly updated but some remain at zero at all times.
    I deliberately attacked creepers to damage myself but the damage to me by creepers is still zero. Did I do something wrong to install it?
     
  23. Offline

    uyuyuy99

    The stats do not update instantly.
     

  24. Short tags are only available when they are enabled via the short_open_tag php.ini configuration file directive, or if PHP was configured with the --enable-short-tags option.

    i will replace short tags on next update .....
    enable short tags on php ini or replace <? to <?php
     
  25. Offline

    ShoTro

    Bukkitcraft is now being updated to support PMD or something, it basically calls out everyone's mistakes when coding for Bukkit. It has you pegged for having long contructors, along with just about every other developer out there.

    Also. Stats is broke in these snapshot versions that seem to be rolling out every couple hours...
    Code:
    SEVERE: ENTITY_DAMAGEDBY_BLOCK (Is it up to date?)
    java.lang.NoSuchFieldError: ENTITY_DAMAGEDBY_BLOCK
            at com.nidefawl.Stats.Stats.initialize(Stats.java:631)
            at com.nidefawl.Stats.Stats.onEnable(Stats.java:573)
            at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:140)
    Love this plugin so much I refuse to let it go right now. Achievements are the backbone to the gameplay I am trying to support and therefore my server is just not functional. Keep up the amazing work. When will their be a stats API? or did I miss that?
     
  26. Offline

    poopiepants

    I am not 100% positive but when someone randomly disconnects all clients connected to my server crash.
    It first pauses for a few secs, then all the clients crash.
    No errors reported on server, but clients receive out of bounds error.
    This is the last plugin to run when someone disconnects.
    I removed the plugin for a couple of days and so far no crashes.

    Just wondering if anyone else has come across this?

    Thanks
     
  27. Offline

    ShoTro

    No, but this sounds more like a bukkit thing rather then a question for this thread.
     
  28. Offline

    earthiverse

    Stats still works... you can still go /stats and the mysql database I'm using still updates.
     
  29. Offline

    ShoTro

    Noticed it works, but a few stats are not updating properly specifically damage based ones.
     
  30. Offline

    yammosk

    I have the same problem on my server, except the Played Time is the one that doesn't update.
     
  31. Offline

    Maluzis

    I watched a few mistakes.

    1) Achievements 'itemuse' does not work.
    2) Achievements 'itempickup' does not work.
    3) If we add the restriction achievment group, it crashes players game after use commands from this plugin.
     

Share This Page