Inactive [ECON] CashFlow v1.0 - Taxes and Salaries [Register] [1317]

Discussion in 'Inactive/Unsupported Plugins' started by Perichor, Sep 10, 2011.

  1. Offline

    Perichor

    [​IMG]

    CashFlow is an economy plugin that lets you create taxes and salaries that pay out at an interval you set. Permissions plugin optional (supports PEX, bPerms and PermsBukkit). Compatible with iConomy 4, 5, & 6+, BOSEconomy 6 & 7, Essentials Economy 2.2.17+, and MultiCurrency.

    Features:
    • Uses the Register API, so it is compatible with multiple economy plugins.
    • Now permissions optional.
    • Supports PEX, bPermissions and PermissionsBukkit.
    • Create multiple taxes with different amounts, intervals, and players receiving the tax (or no player receives the collected tax). Apply taxes to one group or many. Gives you the ability to add players to an "excepted players" list so if someone isn't going to play for a while you can freeze their tax without having to remove them from a group.
    • Create multiple salaries with different amounts, intervals, and players paying out the salaries (or no employer). Apply salaries to one group or many. Add players to an "Excepted Players" list so you can freeze their payment if they're going to be away, without having to remove them from a group.
    • Hits offline players unless onlineonly is set to true.
    • More features coming soon! (see the to-do list)
    Stuff you need:
    • Register
    • An economy plugin - BOSEconomy, MultiCurrency, Essentials Eco, iCo4/5/6
    • A permissions plugin (optional) - PEX, bPermissions, PermissionsBukkit
    Install:

    Download: http://dl.dropbox.com/u/10839588/CashFlow.1.0.jar

    See the BukkitDev page for more information.

    To Do:
    • Add World Guard support.
    • Add option to jail players who don't have enough money to pay their taxes.
    • Thresholds
    • Commands to edit taxes (maybe).
    • A little code cleanup.
    • What else? I've sort of lost track. Leave a comment if you think something should be added.
    Source:

    https://github.com/mveritym/CashFlow

    Pull requests welcome!

    Changelog:
    Version 1.0
    • PermissionsBukkit support! Yaaay.
    • Updated Register -you need to download this *here* and drop it in your plugins folder.
    • Added automatic tax/salary enabling on plugin enable.
    • Made onlineonly mode separate for each tax/salary.
    • Added economy plugins as a softdepend.
    Version 0.4.2
    • Updated Register
    • Bug fixes.
    Version 0.4.1
    • Edited plugin.yml to fix "Bukkit is sad" error being thrown in 1.8.1.
    Previous Versions (open)

    Version 0.4
    • Added support for bPermissions.
    • Added onlineonly option.
    • Made permissions plugin optional.
    Version 0.3
    • Added the option to create a tax as a percent or a flat amount.
    • Added the option to set taxes/salaries on individual players (or a list of players) or a group (or list of groups).
    Version 0.2
    • Rounded taxes to two decimal places.
    • Fixed removeException method always returning "Player not found".
    • Fixed not being able to check for offline players.
    • Added /cashflow setworld <world name> (to fix above).
    • Refactored commands
    • Cleaned up message sending.
    Version 0.1
    • Initial beta release.


    If you decide to use this plugin on your server, please let me know what you think so I can improve it! And if you like this plugin, please consider donating. It's a big incentive and it helps me buy things I need for school.

    [​IMG]
     
    tombik and mctrue like this.
  2. Offline

    saiek

    im having an issue. sometimes when my server restarts, cashflow doesnt automatically start up again. This isnt a big problem, but when i do cashflow restart ro cashflow enable, it does it 10+ times, so people wither get 10X the salary or 10X the tax
     
  3. Offline

    TobyZ28

    Loving the plugin!
    One regular bug:
    • One tax or salary being applied to multiple groups will tax or pay a person multiple times if they belong to more than one group listed in that specific tax or salary. Not sure if this is by design - if you could somehow get inheritance to work this would probably be a non-issue.
    • Users who are not explicitly in any groups, but are still implicitly part of the default group are not taxed each cycle even though the tax is set to include users who belong to "default".
    Few minor cosmetic bugs. :
    • For Salary removeexception and addexcepetion help text shows <taxname> instead of <salaryname>
    • setonlineonly help text is a bit unclear on [interval]. Also seems to follow old wording suggesting all salries or taxes are affected.
    • Instructions state the following:
      /tax create <taxname> <percentincome> <interval> [payee] - Creates a tax.
      /tax create Something 1 1 (Inteval being 1 hour, percent income being 1)
      This will only tax the users 1$ not 1% of their balance.
    Suggestions:
    • A modify option for existing salaries/taxes
    • Listing when the next "tick" will occur when using salary/tax info command
    • A setoffline only flag per tax would be neat as well :)
    • Show the Tax/Salary name when users are prompted they just paid or received money from a tax/salary.
    • <percentincome> would be more accuratly named <percentbalance>.
    Feel free to contact me for any question!


    P.S. The local server residents will supply me with a screenshot of their shrine to the tax god soon...!
     
  4. Offline

    Perichor

    How long are your intervals? If you could send me your config that would be awesome.

    @TobyZ28 Thank you for the feedback! I've fixed a couple of the bugs you pointed out and I'll update it today or tomorrow. I'm looking forward to the pics of the shrine lol.
     
  5. Offline

    saiek


    it was any decimal that was below 1, i have .25 and .1 as intervals and both caused the same problem
     
  6. Offline

    Perichor

    @saiek Can you post your config.yml file and the server log that shows when this happens?
     
  7. Offline

    IniTW8X

    Thanks for the plugin, love it - but I would really like to see an update for 1317!
    Some severe errors appears...;)
     
  8. Offline

    Perichor

    This is updated for 1317 - do you have the latest version (1.0.0)? If you do, can you post the stack trace you're getting with the error? Thanks for the feedback. :)
     
  9. Offline

    IniTW8X

    Yea, sorry, it's working now - there were some problems at first launch, but when I updated to 1317 it seems to be ok! :)
    THX
     
  10. Offline

    saiek

    Code:
    im running on 1317 and the latest version of cashflow tahts on devbukkit and im getting this error.
    
    org.bukkit.command.CommandException: Unhandled exception executing command 'salary' in plugin CashFlow v1.0.0
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:42)
    at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:163)
    at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:355)
    at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:757)
    at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:722)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:715)
    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:92)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:471)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    Caused by: java.lang.NullPointerException
    at mveritym.cashflow.CashFlow.onCommand(CashFlow.java:91)
    at org.bukkit.command.PluginCommand.execute(PluginCommand.java:40)
    ... 12 more
     
  11. Offline

    Perichor

    What commands cause this error? And can you paste your config.yml for me? I can't replicate this error which probably means the plugin is out of date. Try downloading the one from the dropbox link in this thread and see what happens. If that's not the case, then back to the drawing board. Whatever information you can give me about the way you use this plugin and other things on your server is useful!
     
  12. Offline

    saiek

    my mistake, i downloaded the one off of devbukkit, and i didnt have the 1.5 file downloaded either, thanks for the help
     
  13. Offline

    Perichor

    Good to hear this was resolved. :)
     
  14. Offline

    zazaramo

    Code:
    20:50:33 [SEVERE] Error occurred while enabling CashFlow v1.0.0 (Is it up to dat
    e?): com/nijikokun/register/payment/Methods
    java.lang.NoClassDefFoundError: com/nijikokun/register/payment/Methods
            at mveritym.cashflow.server.<init>(server.java:20)
            at mveritym.cashflow.CashFlow.onEnable(CashFlow.java:41)
            at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:126)
            at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader
    .java:920)
            at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManage
    r.java:278)
            at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:173)
            at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:156
    )
            at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:297)
            at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:284)
            at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:152)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:348)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
    Caused by: java.lang.ClassNotFoundException: com.nijikokun.register.payment.Meth
    ods
            at java.net.URLClassLoader$1.run(Unknown Source)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(Unknown Source)
            at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.
    java:36)
            at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.
    java:24)
            at java.lang.ClassLoader.loadClass(Unknown Source)
            at java.lang.ClassLoader.loadClass(Unknown Source)
            ... 12 more

    i get this error
     
  15. Offline

    Perichor

    What version of CashFlow, Craftbukkit and Register are you running?
     
  16. Offline

    zazaramo

    nvm i had forgotten to download register :p
    but now i got a new problem the players dont get salary :S
    i did in game /salary create Server 30 60 Ramboow
    and after that i did /salary apply group Server default
    but nobody get paid out
     
  17. Offline

    Perichor

    Your players will get paid 60 hours from when you created the salary. Also remember to run /cashflow enable or /cashflow restart to start the timers!
     
  18. Offline

    zazaramo

    WOW 60 hours?
    so the interval is in hours?
    so how can i change it into 1min/60sec?
     
  19. Offline

    Perichor

    You're going to pay your players every minute? ._. Don't let your server go down for a long time because CashFlow will freak out if you enable it after a long time - it will try to pay every salary that it couldn't while the server was down, so just be careful!

    One minute = 1/60 hours = 0.0166667 hours
     
  20. Offline

    zazaramo

    But can't i do it so that they get only paid when they are on and when the server is only on.
     
  21. Offline

    Perichor

    Yep, just do /salary setonlineonly <salaryname> true
     
  22. Offline

    zazaramo

    I get 2 times paid :S
     

    Attached Files:

  23. Offline

    Perichor

    What permissions plugin are you using?
     
  24. Offline

    zazaramo

    permissionsbukkit
     
  25. Offline

    Perichor

    Can you post your config.yml for me?
     
  26. Offline

    zazaramo

    from permission or cashflow?
     
  27. Offline

    Perichor

    Both would be awesome.
     
  28. Offline

    zazaramo

     

    Attached Files:

  29. Offline

    Perichor

    @zazaramo
    Ok, try running /cashflow restart and see if that fixes it. If not, try renaming your default group to something other than default. If that still doesn't work, something is wrong and I need to find out what. D:
     
  30. Offline

    zazaramo

    haha ok xD
    i will try it tomorrow.
    Now its time to sleep.
    already trying to fix this for 2.30 hours.
     
  31. Offline

    Perichor

    Let me know if you get it to work tomorrow.
     

Share This Page