[ADMIN/MECH] SummaCodes v1.10 - Simple, easy and flexible redeemable codes [1.2]

Discussion in 'Inactive/Unsupported Plugins' started by Hidendra, May 22, 2011.

  1. Offline


    SummaCodes v1.10



    SummaCodes is a plugin that handles "redeem codes." It uses Bukkit's built in persistence database, so it can be configured to use SQLite (default) or MySQL via bukkit.yml

    Codes can be configured to give items and iConomy money. Codes can also be configured to expire at a set time (e.g in 5 hours, or 10 minutes, or 5 seconds, or 1 month, and so on.)




    Regular usage:
    Admin usage:

    • 1.2 support
    • Vault support
    • Initial release

    Juze, bconnerly and Taranis01 like this.
  2. Offline


    Nice rework on code redeem, thanks for this! :)
  3. in plugins/SummaCodes
  4. Offline


    No, in the root directory of your server
  5. Also is there any howto for setting this up using MySQL? as stated in the description?

    I tried the following in bukkit.yml
            type: SQL
            dbms: MYSQL
            uri: jdbc:mysql://localhost:3306/summacodes
            username: user
            password: pass

    Fixed the ebean error. still getting the below.
    20:08:39 [INFO] DataSourcePool [SummaCodes] autoCommit[false] transIsolation[SERIALIZABLE] min[2] max[20]
    20:08:39 [INFO] SubClassFactory parent ClassLoader [org.bukkit.plugin.java.PluginClassLoader]
    20:08:40 [INFO] Entities enhanced[0] subclassed[1]
    20:08:40 [INFO] -> PLAYER_CHAT
    20:08:40 [INFO] -> PLAYER_QUIT
    20:08:40 [INFO] RedeemCodes enabled: 1.00-rc1
    Note This is the only plugin currently running. I have disabled all others to trouble shoot this error in my logs.

    I'm running b860.

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


    Yeh... and? I get that as well but the plugin works fine.
  7. True. I guess I could just ingore it. Just thought it looked like a bad error. Will still use it but will keep an eye on it. Any luck getting it set up with mysql?
  8. Offline


    No I don't see any reason to.
  9. Was thinking of a more automated way to insert new codes into it. On a donation level type thing...
  10. Offline


    It uses Bukkit's persistence, so it can be configured to use MySQL.

    First, you need to modify your startup arguments. Two easy ways to do it:
    If you use LWC with MySQL
        -cp plugins/LWC/lib/mysql.jar;.
        java -Xmx1024m -cp plugins/LWC/lib/mysql.jar;. -jar CraftBukkit.jar
    Without LWC+MySQL
    Download the following to the lib folder in your root minecraft dir: (mysql.jar)
    Now add this to your startup args for minecraft
        -cp lib/mysql.jar;.
        java -Xmx1024m -cp lib/mysql.jar;. -jar CraftBukkit.jar

    Now open up bukkit.yml in your root MC dir. Modify it to something like this:
        username: YourUsername
        isolation: SERIALIZABLE
        driver: org.gjt.mm.mysql.Driver
        password: YourPassword
        url: jdbc:mysql://
        update-folder: update
    This assumes you run the MySQL server on the local server. All you need to change is YourUsername, YourPassword, and if you wish to use a different database than bukkit, change /bukkit to /DBNAME

    SummaCodes uses the table name sx_codes

    That should be it. Just run the server again and it should be OK. Warning: does not convert old codes!
  11. Perfect!! thanks for the how to... I think it will help more people then me also.. Thanks again..
  12. Offline



    Started getting this since today:

    2011-06-23 13:20:37 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'redeem' in plugin SummaCodes v1.0
    Caused by: javax.persistence.PersistenceException: ERROR executing DML bindLog[] error[Data truncation: Data too long for column 'code_players' at row 1]
    Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'code_players' at row 1
    Is that to worry?
  13. Offline


    I constantly get this error
    01:52:08 [SEVERE] FATAL: DataSourcePool [SummaCodes] is down!!!
    com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure

    The last packet successfully received from the server was 30,001 milliseconds ago. The last packet sent successfully to the server was 0 milliseconds ago.
    at sun.reflect.GeneratedConstructorAccessor53.newInstance(Unknown Source)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
    at com.mysql.jdbc.Util.handleNewInstance(Util.java:407)
    at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1116)
    at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3082)
    at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2968)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3516)
    at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1986)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2140)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2620)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2570)
    at com.mysql.jdbc.StatementImpl.executeQuery(StatementImpl.java:1474)
    at com.avaje.ebeaninternal.server.lib.sql.DataSourcePool.testConnection(DataSourcePool.java:497)
    at com.avaje.ebeaninternal.server.lib.sql.DataSourcePool.checkDataSource(DataSourcePool.java:356)
    at com.avaje.ebeaninternal.server.lib.sql.DataSourceManager.checkDataSource(DataSourceManager.java:228)
    at com.avaje.ebeaninternal.server.lib.sql.DataSourceManager.access$100(DataSourceManager.java:37)
    at com.avaje.ebeaninternal.server.lib.sql.DataSourceManager$Checker.run(DataSourceManager.java:240)
    at com.avaje.ebeaninternal.server.lib.BackgroundThread$Runner.runJobs(BackgroundThread.java:208)
    at com.avaje.ebeaninternal.server.lib.BackgroundThread$Runner.run(BackgroundThread.java:172)
    at java.lang.Thread.run(Thread.java:680)
    Caused by: java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes before connection was unexpectedly lost.
    at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:2529)
    at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2979)
    ... 15 more
    01:52:08 [INFO] Reseting DataSourcePool [SummaCodes] min:2 max:20 free:0 busy:1 waiting:0 highWaterMark:1 waitCount:0 hitCount:188
    01:52:08 [INFO] Busy Connections:
    name[SummaCodes.39] startTime[1309157528146] stmt[null] createdBy[null]

    01:52:08 [INFO] Closing Connection[SummaCodes.39] psReuse[0] psCreate[0] psSize[0]
    01:52:08 [SEVERE] Closing Connection[SummaCodes.39] that is already closed?
  14. Is it possible to you to make it connect to a DB?
    so i can use php whith it.
  15. Offline


    Read 4-5 posts up ;)
  16. Offline


    i cant seem to get this plugin to work. i have it installed but when i type in codes none of the commands show up. can anyone help
  17. Offline


    How do I setup for mysql?
  18. Offline


    Simply amazing! We had some world corruption so we had to edit all out stuff to a new world & this worked great for giving people some money & tools to help with moving. Thanks a bunch!
  19. Offline


    Wow this plugin is THE BEAST. Will definitely use this when it works with 953 or equivalent
  20. Offline


    Are you going to update the plugin to the latest RB soon?
  21. Offline


    Is it possible with this plugin to maybe have it execute a command on redeeming? Like if a user has a code, they can redeem it and it would change the group they belong in and such like that? With my server, new people joining cannot build and are very limited until we can place them in a different group. With this, it would be nice to be able to give out a code to people we know so when they join, they can just redeem it and be moved to the group automatically.
  22. Offline


    I will use this plugin after it has been updated to build 953, Thanks.
  23. Offline


    Good idea!
  24. Offline

    Charlie Gordon

    How can I have it so that the item's attached to the redeem code are put in the players storage slots, rather than in the hotkey slots? If this isn't an option please add it asap! :D
  25. Offline


    Is this compatible with SuperPerms?
  26. Offline


    Will this be updated?
  27. Offline


    fantastic plugin, but when i makes a code with iconomy (i became money for redeem) then i become the "An internal error occurred while attempting to perform this command" Error in-game... What have i done wrong or what can i do that it works??

    Thanks for help and sry for my bad english :D

  28. Offline


    Will this Plugin be updated or can someone help me with my problem???
  29. Offline


    could you please add more currency plugins,such as essentials and BOSEeconomy?
    please reply
  30. Hey, hidendra.

    when I make a code with Iconomy 6 I always get huge errors and when a player used the code nothing happens.

    Can you help me or is it a problem with this pluggin?
  31. WAY, WAY, i use this plugin!

    :(, need to fix it myself

Share This Page