Inactive [MECH/ECON] Money2XP v1.1.4 - train your mcMMO-skills using money - now with zones! [1000]

Discussion in 'Inactive/Unsupported Plugins' started by TZer0, Apr 7, 2011.

  1. Offline

    TZer0

    Support for this plugin has been discontinued. If you wish to take over, please contact me.

    Money2XP - train your mcMMO-skills using iConomy/BOSEconomy-money

    Downloads
    Old version(1.0, iConomy 5, mcmmo ~1.0, pre 1.0.43)

    Old version(0.2.2, iConomy 4):


    Dependencies:
    Features:

    • Allows players to train their skills using iConomy-money, BOSEconomy-money or EssenaitalsEco-Money.
    • Easy to set up
    • Will allow rich players to spend some cash :)
    • Training-zones!
    Permission-nodes:

    Commands (you may use /m2xt and /m2xs instead of /m2xtrain and /m2xset):
    Show Spoiler

    • /m2x and /m2xset - general help
    • /m2x (l)ist - shows skills and prices
    • /m2x [skillname] [amount] - Purchases [amount] xp for [skillname]
      • Usage:
        • /m2x archery 100 - gives you 100 archery xp.
    • /m2x [skillname] i[amount] - Purchases [amount]*[xpPerItem] xp for [skillname]
      • Usage:
        • /m2x archery i100 - purchases 100*xpPerItem archery xp for 100 of [item]
    • /m2x (c)heck [skillname] [amount] - Shows how much a purchase will cost you
      • Usage:
        • /m2x check archery 100 - Shows you how much 100 archery xp will cost you.
    • /m2xset [skillname/default] [price-per-xp] - sets the price per xp for [skillname] to [price-per-xp], 0 = default, -1 = unavailable
      • Usage:
        • /m2xs archery 150 - sets the price per xp for archery to 150
        • /m2xset default 75 - sets the default price per xp to 75.
    • /m2xset [skillname] i[itemId]:[xpPerItem] - Allows players to purchase xp for [skillname] using item with [itemId] at a rate of [xpPerItem]
      • Usage:
        • /m2xs archery i3:10 - allows purchases of archery xp for 10 xp per dirt-block.
    • /m2xtrain (z)ones {t/true/f/false} - turn training zones on/off
      • Usage:
        • /m2xt z t - enables zones
        • /m2xtrain zones f - disables zones
    • /m2xtrain (n)ode [1/2] - sets nodes for area-creation (to your current location, which two corners you define is irrelevant)
      • Usage:
        • /m2xt n 1
        • /m2xt node 2
    • /m2xtrain (c)reate [name] - creates a zone using nodes.
      • Usage:
        • /m2xt c myzone
    • /m2xtrain (l)ist {#} - shows training zones
    • /m2xtrain (s)elect [name] - select an area
      • Usage:
        • /m2xt s myzone
    • /m2xtrain (a)rea - shows information about the selected area
    • /m2xtrain (r)e(s)ize - resize selected area
    • /m2xtrain (ad)d [skillname] - adds a skill to selected area
      • Usage:
        • /m2xt ad archery
        • /m2xtrain add swords
    • /m2xtrain (d)el [skillname] - removes a skill from selelected area
      • Usage:
        • /m2xt d archery
        • /m2xtrain delete swords
    • /m2xtrain (d)elete(a)rea [name] - deletes an area
    • /m2xtrain (r)eload - reload config, reports errors
    Available skills: mining, woodcutting, excavation, repair, herbalism, acrobatics, swords, archery, unarmed, axes, taming






    Setting up a training-zone
    Show Spoiler


    Remember: before doing this, run: "/m2xt z t"
    1. First set up two nodes, these should span the zone you want to be able to train in. "/m2xt n 1" and then "/m2xt n 2" somewhere else
    2. Then create the area: "/m2xt c myareaname"
    3. Select the area: "/m2xt s myareaname"
    4. Add skills which are trianable in the area: "/m2xt ad skillname", for instance: "/m2xt ad archery"



    Setting up a sign-shop
    Show Spoiler

    First line: [m2x]
    Second line: skillname
    Third line: xp-amount
    Fourth line: will be automatically replaced by "Cost: %.2f", price

    If the price changes later (say, archery-xp goes from 10 to 20), then the fourth line will be automatically replaced with the new price and the purchase aborted so that the purchaser may re-review the deal.


    Tricks:
    • -1 disables skill-purchases for a skill, 0 sets it to the default value
    • You can set the default-price to -1 to prevent skill-purchases for all skills except for those with a price set.
    Changelog:

    • v1.1.4
      • Fixed sign-shop issue.
    • v1.1.3
      • Fixed issue when right-clicking without having access to money2xp.user.
    • v1.1.2
      • Fixed NPE when running without permissions.
      • Made it possible to set prices through console (will add some other functions currently under m2xt soon to console)
      • Fixed some other minor issues.
    Previous changes (open)


    • v1.1.1
      • Fix for using zones and signs simultaneously.
    • v1.1
      • Sign-shop
    • v1.0.1
      • Updated to latest mcmmo-version thanks to @NuclearW
      • Fixed exception when running m2x in console
    • v1.0
      • EssentialsEco-support
      • Allow purchases using items
      • Allows xp-costs below 1. (double instead of int)
    • v0.2.3
      • iConomy 5
    • v0.2.2
      • Added taming to list of skills.
    • v0.2.1
      • Fixed null pointer exception on start if no areas are present.
    • v0.2
      • Training-zones
      • Aliases
      • use float/double to store xp-costs so that one can get more than one xp per unit of money.
    • v0.1.5
      • Fixed the balance-message after purchase.
    • v0.1.4
      • Fixed broken iConomy-support from v0.1.2
    • v0.1.3
      • Fixed a minor bug
    • v0.1.2
      • Added BOSEconomy-support on MCbyWay's request.
    • v0.1.1
      • Fixed some small bugs
    • v0.1
      • Initial release



    Todo:
    • [high] Use Spout and make a video-tutorial obsolete.
    • [medium] Make a video-tutorial.
    • [medium] Options for limiting how much a zone allows you to train (levelcap).
    • [medium] Purchasing X levels instead of xp. Will be added as soon as mcMMO is fixed!
    • [medium/low] xp-cost increase per level or related to amount of xp already purchased for that skill.
    • [low] Let players become trainers when reaching high enough levels.
    • Anything you can come up with!
    Feedback, as always - is welcome.
     
    kahlilnc likes this.
  2. Offline

    1cec0ld

    I love this idea, and now I know where to go when people get bored with all the cash!

    As I read, the thought occurred to me that I'd make certain (combat :-P ) abilities un-buyable, but I suppose making the levelcap '0' should take care of that. So kudos for current progress, and good luck with further updates!
     
  3. Offline

    TZer0

    You can't sell xp, I made sure of that. If someone tries to do so.. well.. go see for yourself! :D
     
  4. Offline

    PurpleCamel

    When do you plan on updating your plugin? No hurry, I'm just wondering.
     
  5. Offline

    TZer0

    What specific part? If it is about the fact that it still says [928], then you shouldn't really worry. The plugin works just fine on the latest CB-version.
     
  6. Offline

    PurpleCamel

    Oh, thank you for clearing that up. :)
     
  7. Offline

    woodzy

    video or on how to make the traning area
     
  8. Offline

    TZer0

    Noted. May make one :D
     
  9. Offline

    NazzyDragon

    Even after reading, I'm confused. Can you explain to me how Training Zones work exactly? It's not quite clicking with me.


    Love this plugin btw, it's great. I just want to know how zones work. :]
     
  10. Offline

    TZer0

    Updated topic. Read how to Setting up a training-zone.
     
  11. Offline

    NazzyDragon

    WOOHOO. Thanks! ^_^ I always wondered how that worked, but I didn't want to mess with it due to a fear of borking the server a little, or giving players unintended mcMMO XP.. Thanks a lot.
     
  12. Offline

    TZer0

    Mh, no worries - training zones don't affect the actual physical world and they do not affect the money/xp-ratio.

    Also, next: sign-shop.
     
  13. Offline

    wassilij

    Command: /m2x mining 150
    Info:
    Bukkit 1000
    Bukkit Contrib 0.17
    Money2XP 1.0

    Error:
    Code:
    2011-07-22 13:40:35 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'm2x' in plugin Money2XP v1.0
        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.NoSuchMethodError: com.gmail.nossr50.mcMMO.addXp(Lorg/bukkit/entity/Player;Ljava/lang/String;Ljava/lang/Integer;)V
        at tzer0.Money2XP.Money2XP.xpMod(Money2XP.java:457)
        at tzer0.Money2XP.Money2XP.onCommand(Money2XP.java:158)
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
        ... 12 more
    2011-07-22 13:40:39 [INFO]  AtomkraftND: -.- 
    2011-07-22 13:40:40 [INFO] s1t0n1c [/77.13.21.33:1407] logged in with entity id 577717 at ([world5] 271.68649932413723, 11.0, 444.17591737129504)
    2011-07-22 13:40:41 [INFO]  jeahaha: und mit 1 dia 
    2011-07-22 13:40:42 [INFO] [BukkitContrib] Successfully authenticated s1t0n1c's BukkitContrib client. Running client version: 17
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Attempting to compensate.
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Failed to compensate!
    2011-07-22 13:40:45 [SEVERE] Could not pass event BLOCK_FROMTO to mcMMO
    java.lang.ClassCastException: org.bukkitcontrib.block.ContribCraftChunk cannot be cast to org.bukkitcontrib.block.ContribCraftChunk
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:105)
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:1)
        at org.bukkit.event.block.BlockFromToEvent.getToBlock(BlockFromToEvent.java:39)
        at com.gmail.nossr50.listeners.mcBlockListener.onBlockFromTo(mcBlockListener.java:426)
        at org.bukkit.plugin.java.JavaPluginLoader$30.execute(JavaPluginLoader.java:448)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:332)
        at net.minecraft.server.BlockFlowing.a(BlockFlowing.java:134)
        at net.minecraft.server.World.a(World.java:1982)
        at net.minecraft.server.World.doTick(World.java:1722)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:441)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Attempting to compensate.
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Failed to compensate!
    2011-07-22 13:40:45 [SEVERE] Could not pass event BLOCK_FROMTO to SpongeRestore
    java.lang.ClassCastException: org.bukkitcontrib.block.ContribCraftChunk cannot be cast to org.bukkitcontrib.block.ContribCraftChunk
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:105)
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:1)
        at org.bukkit.event.block.BlockFromToEvent.getToBlock(BlockFromToEvent.java:39)
        at DevilBoy.SpongeRestore.SpongeRestoreBlockListener.onBlockFromTo(SpongeRestoreBlockListener.java:97)
        at org.bukkit.plugin.java.JavaPluginLoader$30.execute(JavaPluginLoader.java:448)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:332)
        at net.minecraft.server.BlockFlowing.a(BlockFlowing.java:134)
        at net.minecraft.server.World.a(World.java:1982)
        at net.minecraft.server.World.doTick(World.java:1722)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:441)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Attempting to compensate.
    2011-07-22 13:40:45 [INFO] [BukkitContrib] Unexpected Behavior in ContribCraftBlock.getRelative(...)! Failed to compensate!
    2011-07-22 13:40:45 [SEVERE] Could not pass event BLOCK_FROMTO to WorldGuard
    java.lang.ClassCastException: org.bukkitcontrib.block.ContribCraftChunk cannot be cast to org.bukkitcontrib.block.ContribCraftChunk
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:105)
        at org.bukkitcontrib.block.ContribCraftBlock.getRelative(ContribCraftBlock.java:1)
        at org.bukkit.event.block.BlockFromToEvent.getToBlock(BlockFromToEvent.java:39)
        at com.sk89q.worldguard.bukkit.WorldGuardBlockListener.onBlockFromTo(WorldGuardBlockListener.java:212)
        at org.bukkit.plugin.java.JavaPluginLoader$30.execute(JavaPluginLoader.java:448)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:332)
        at net.minecraft.server.BlockFlowing.a(BlockFlowing.java:134)
        at net.minecraft.server.World.a(World.java:1982)
        at net.minecraft.server.World.doTick(World.java:1722)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:441)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    Problem: The money is away, but i didn't get any skillpoints.
     
  14. Offline

    MrConfig

    Is it possible that latest mcMMO 1.0.47 broke Money2XP? I also get an error when buying XP and it takes the money. Thanks.
     
  15. Offline

    TZer0

    It seems so. I'll send @nossr50 a message about it/find a way to file a bug report.
     
  16. Offline

    NuclearW

  17. Offline

    Darcion

  18. Offline

    wassilij

    It don't work, if I use /m2x, it say's that there is no such command.
    No errors in the server.log

    But it's okay, i wait :)
     
  19. Offline

    TZer0

    Thanks for the pull request. However, you forgot to include the plugin.yml in your jar-file. :p

    I'll be putting up a new version in a few minutes.

    Update is out.

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

    NuclearW

    doh! Sorry, I tried!
     
  21. Offline

    TZer0

    Not a problem :p
     
  22. Offline

    wassilij

    I tried to level my repair skill mit /m2x repair 100
    Bukkit 1000
    mcMMO 1.0.48
    Money2XP 1.0.1

    Code:
    2011-07-25 09:34:46 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'm2x' in plugin Money2XP v1.0.1
        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.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
        at java.lang.Integer.parseInt(Integer.java:493)
        at java.lang.Integer.parseInt(Integer.java:514)
        at tzer0.Money2XP.Money2XP.xpMod(Money2XP.java:409)
        at tzer0.Money2XP.Money2XP.onCommand(Money2XP.java:162)
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
        ... 12 more
     
  23. Offline

    TZer0

    That one was truly unexpected. I'll look into it.
     
  24. Offline

    wassilij

    This error reported a user .. i looked into the log and this error was there, but then i try it myself and all worked oO
     
  25. Offline

    TZer0

    Oh, uhm, I believe he might've mixed in a character in the number. Uhm, I'll fix it nonetheless :p
     
  26. Offline

    Lynxdragon

    Can you make MCMMO able to give exp for killing Slime, Giants and Monsters?
     
  27. Offline

    TZer0

    Like direct additional credit for killing things? Hmm, I'm not sure that's within the scope of this plugin. I'll think about it.
     
  28. Offline

    Lynxdragon

    Well at the moment, You get 0 exp for killing Slime, Giant and Monster. Its very frustrating. If this is possible it would make a great addition.
     
  29. Offline

    TZer0

    As in: combat xp? Then you should perhaps post in the mcmmo-topic, not here ;)
     
  30. Offline

    Lynxdragon

    I figured the author of MCMMO would have put in the feature if he wanted it, however I will try it. Will let you know, Thanks for your time.
     
  31. Offline

    Nick Hooper

    It would help so much if the commands were simplified. Like just /xp train or somthing. Thought: Click on a sign to buy xp?
     

Share This Page