Inactive [ADMN] CouponCodes v2.0.5 - Add redeemable codes for items, money, and groups [1.0.1R1]

Discussion in 'Inactive/Unsupported Plugins' started by LaLa, Jul 6, 2011.

  1. Offline

    LaLa

    Support will only be on BukkitDev.​
    OldPost

    Coupon Codes by LaLa
    Version 1.5.3
    Requires: Bukkit's default permissions plugin (1.5.1+) or Permissions 3.x (1.5-)
    Downloads: 955 (updated daily)

    Coupon codes lets you create redeemable codes that can give players items, such as diamond or a pickaxe. You can also renew codes, so you don't have to enter them multiple times! iConomy has also been added, so your coupons can now give people money through iConomy!

    Features:
    • Add redeemable codes that can give items
    • Customize what the codes give the redeemer
    • Permissions!
    • iConomy support!
    • Lots of customizing!
    Download Version 1.5.3 | Dev. Builds | Older Versions
    Source on GitHub

    Config Example

    Code:
    #Learn more about how this config can be edited and changed to your preference on the forum page.
    author: LaLa
    config:
        iconomy:
            enabled: true
            couponcost:
                enabled: false
                price: 10
            has: true
        coupons:
            onetimeuseperplayer: true
        debug: false
    
    The only this you cannot edit is the value 'has'. This tells me, or the plugin, if you have iConomy or not. Changing it manually might cause...interesting things to happen.

    Obviously, if the default value is 'true' you can change it between that and 'false' but not 'yes' and 'no' or '1' or some other number without getting lots of errors.


    Commands
    • /coupon or /c can be used
    • /c redeem [coupon-code]
    • /c add [coupon-code] [id] [amount] [number of times can be used] - Leave blank for 1
    • /c add ic [coupon-code] [money] [#canbeuse] - New, used for creating an iConomy code
    • /c remove [coupon-code]
    • /c removeall
    • /c renew [coupon-code] [new # of times can be used] - Leave blank for default of 1
    • /c reload - Reload config
    Permissions
    • coupon.help - See the command list
    • coupon.redeem - Redeem an item (/c redeem)
    • coupon.add - Add a coupon code (/c add)
    • coupon.remove - Remove a code (/c remove)
    • coupon.remove.all - Remove all codes (/c removeall)
    • coupon.renew - Renew a coupon code (/c renew)
    • coupon.reload - Ability to reload config (/c reload)
    • coupon.* - Get all the coupon permissions
    Permissions in YML form

    Code:
    permissions:
        coupon.*:
            description: Gives access to all coupon commands
            children:
                coupon.add: true
                coupon.redeem: true
                coupon.remove: true
                coupon.remove.all: true
                coupon.renew: true
                coupon.reload: true
                coupon.help: true
        coupon.remove.*:
            description: Gives you permission to remove and remove all coupons
            children:
                coupon.remove: true
                coupon.remove.all: true
        coupon.add:
            description: Allows you to add a coupon
            default: false
        coupon.redeem:
            description: Allows you to redeem a coupon
            default: false
        coupon.help:
            description: Allows you to redeem a coupon
            default: true
        coupon.remove:
            description: Allows you to remove a coupon
            default: false
        coupon.remove.all:
            description: Allows you to remove all coupons
            default: false
        coupon.reload:
            description: Allows you to reload CouponCode's configuration files
            default: false
        coupon.renew:
            description: Allows you to renew a coupon
            default: false
    


    Planned Features
    • MySQL Support - ?
    • Multiple items from one coupon - planned for 1.5.4
    • Random coupon generator - planned for 1.5.4
    • Even more customizing - planned for 1.4 - DONE
    • Set how many times a coupon can be used - planned for 1.4
    • Make creating coupons cost iConomy money (optional) - planned for 1.3
    Bugs
    • Removing all coupons just displays the syntax
    • No confirmation when removing a single coupon
    Reveiws


    [​IMG]

    Changelog
    Version 1.5.3 - August 20 2011
    Version 1.5.2 - July 25 2011
    • Fixed remove all not working (configured to coupon.removeall by accident)
    • Added confirmation for removing a coupon
    Version 1.5.1 - July 17 2011
    • CouponCodes now supports the official permissions plugin (and only that! sorry permissions 3.x users! :confused: )
    Version 1.5 - July 17 2011
    • Similar to my other plugin WordRank, you can now give coupon specific permissions
    • Plugin epically re-done
    • Reloading the config works properly
    • Potential bugs in previous builds are no more
    • Customizing dropped, felt if it wasn't 100% complete might as well not have it
    • Source is open, and there are now comments explaining the different aspects of the code
    Version 1.4 - Friday July 8 2011
    • Customize almost every message
    • Set how many times a coupon can be used
    • Set if a player can only use a coupon once
    • Fixed where sometimes a coupon would not generate
    Older Versions
    Version 1.3 - Thursday July 7 2011
    • You can now charge people to make coupons
    • Color codes are now universal between coupons and various means of making them
    • More customizing (even more next update)
    • Added /c reload
    • Lots of little bug fixes
    Version 1.2 - Thursday July 7 2011
    • Added iConomy support
    • Fixed a handful of bugs with creatings/redeeming codes
    • Config added. Enable iConomy in there
    Version 1.1 - Wednesday July 6 2011
    • Fixed where if your inventory is full you will not get your item
    • Fixed where if you renewed a coupon that didn't exist it would not generate properly
    Version 1.0 - Wednesday July 6 2011
    • Initial release


    If you like my plugin, please like this post and/or like it on this plugin website
     
    lastern, odielag, gameswereus and 3 others like this.
  2. Offline

    tcvs

    Will u be adding iconomy support
     
  3. Offline

    LaLa

    @tcvs
    Hmm, good idea. Maybe next release
     
  4. Offline

    LiamFrazer

    I like this idea, it could possibly used for a small donation system. Do you know if the player would loose the items if they attempted to active it while they have a full inventory?
     
  5. Offline

    LaLa

    @LiamFrazer
    It will not give them the item. Fixed in 1.1
     
  6. Offline

    tcvs

  7. Offline

    gameguy27

    MySql support?
     
  8. Offline

    LaLa

    Version 1.2 added. iConomy support :D

    @gameguy27
    Added to the planned feature list

    Version 1.3 is live.
    Cool new stuff

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

    Vision

    Extremely useful for my server. Thank you for creating this.
     
  10. Offline

    LaLa

  11. Offline

    majorcyto

    Can you set a limit for instance.

    How many times a player can use 1 coupon
    How many times the coupon can be used period.
     
  12. Offline

    LaLa

  13. Offline

    majorcyto

    Thanks i appreciate it loads, then i will happily use it. :D
     
  14. Offline

    LaLa

    1.4 is out.
    Lots of new stuff added both to the plugin and first post
     
  15. Offline

    MrConfig

    Good idea and great work!
     
  16. Offline

    LiamFrazer

    You've done quite a lot of work since I last checked up on this plugin, it's looking extremely useful, can't wait for the MySQL support. Thanks.
     
  17. Offline

    wouter0100

    maybe a idea that you can make 'Coupon's' that you get a Group in permissions? ore some permissions?
     
  18. Offline

    LaLa

    @MrConfig
    Thank you!

    @LiamFrazer
    You're welcome, trying to get MySQL support for 2.0

    @wouter0100
    Not sure what you mean exactly, but this is how I think it is. You have a coupon named "test" and you want to give a group the permission to only use that coupon such as coupon.test?
     
  19. Offline

    wouter0100

    No, if i activate a Coupen, that i get in a group by permissions.
     
  20. Offline

    LaLa

    Version 1.5 is out.
    I may release another update for the new built in permissions, how exactly its working I'm not sure
     
  21. Offline

    JoelDaMole789

    Not entirely sure about the changelog, but I am not going to get this plugin due to lack of Permissions 3.x compatibility. :(
     
  22. Offline

    LaLa

    Version 1.5 still has 3.x compatibility, however, version 1.5.1 which I'm testing right now will not.
    If you give the new (and default) permission system a try, you won't be disappointed.
     
  23. Offline

    JoelDaMole789

    Tried it out, works like a dream (i hope) thanks!
     
  24. Offline

    wassilij

    wit 1.5.0 and bukkit 1000

    Code:
    2011-07-19 21:20:07 [INFO] 117
    2011-07-19 21:20:07 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'c' in plugin Coupon Codes v1.5
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:37)
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:129)
        at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:320)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:713)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:677)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:670)
        at net.minecraft.server.Packet3Chat.a(Packet3Chat.java:33)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:85)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    Caused by: java.lang.ArrayIndexOutOfBoundsException: 1
        at com.lala.CouponCodes.Commands.C.onCommand(C.java:100)
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
        ... 12 more
     
  25. Offline

    LaLa

    What Permissions plugin are you using?
    What command did you use when this happened?
     
  26. Offline

    wassilij

    I think the c redeem, but i dont know.

    Permissions 3.1.5
     
  27. Offline

    tommygoesha

    is there a way to change the command? to like idk.. just /redeem or /get or /recieve
     
  28. Offline

    LaLa

    You can use bukkit's built-in command alias system.
    Located in your main folder for your server is the bukkit.yml which should by default have this:
    Code:
    aliases:
        icanhasbukkit:
        - version
    
    This means the the command /icanhasbukkit can be used as /version instead.
     
  29. Offline

    Firehunter23

    Does the new permission system also support multiworld support ?^^
     
  30. Offline

    LaLa

    Yes
     

Share This Page