[INACTIVE][FUN/MECH] Philosopher's Box v1.7 - Item conversion based on defined values. [740]

Discussion in 'Inactive/Unsupported Plugins' started by Nohup, Feb 27, 2011.

  1. Offline

    Nohup

    Philosopher's Box
    v1.7

    Tags - Trade, Convert, Permissions

    A re-envisioning of hM0d's MineTrade, by request.

    Historically the philosopher's stone was known as an alchemical tool that would convert one metal into another (primarily lead into gold). In this spirit, this plugin will allow you to convert a group of items into another based on overall value.

    Features (currently on, but relies on block configuration):
    • Server admins can configure values for individual items, based on material constant
    • Block configuration consists of:
      • Sign with line 1 of "Philosopher's" and line 2 of "Box"
      • Chest
      • Redstone torch directly under chest (for identification purposes)
      • Button
      • All above blocks within the same surrounding cube of the chest itself.
    • Multiple item types can be converted at the same time
    • When conversion value results in a remainder, source objects will be returned to cover the remainder based on a) what was provided for the conversion and b) the highest value possible.
    • Items provided that have no value specified will not be destroyed or converted
    • Conversion type determined by value displayed on sign
    • Conversion triggered by pressing the button
    • Added Permissions support as of v 1.2 and Op-only option in v 1.3
    Usage: Plugin always enabled, but block configuration required. Configurable access via Permissions. Commands coming soon for value listings.


    Permissions Configuration:
    Permissions configuration will be handled in the Permissions plug-in's configuration file. If permissions are enabled then you will want to configure at LEAST a philosophers.* for everyone to allow wide-open access. To specify further you can add specific material conversions to specific users/groups. Examples below:

    Allow everyone access to all conversions:

    Code:
    groups:
        Default:
            default: true
            info:
                prefix: ''
                suffix: ''
                build: false
            inheritance:
            permissions:
                - 'foo.bar'
                - 'philosophers.*'
    
    Specifically allow user xyz to use the gold ore conversion:

    Code:
    users:
        xyz:
            group: Default
            permissions:
                - 'philosophers.material.gold_ore'
    
    Download: Philosopher's Box v1.7
    Source: GitHub
    Wiki: Wiki





    Latest version tested against: 733

    Change Log:

    v 1.7
    • updated to Bukkit 733


    v 1.6
    • updated to work with latest Bukkit
    v1.4
    • Minor bug fixes
    • Tested against new Recommended Build
    v 1.3
    • Added ops-only flag
    • Removed message about not being able to find philosopher box when any button is pressed
    v 1.2

    • Added Permissions support
    v 1.1

    • Added configuration to provide values for materials without requiring them to be available conversions.
    v1.0

    • Initial release
     
  2. Offline

    Carnage104

    Thankyou very much for answering my request!!
    Java Prgrammer XP: +30
    Response time XP: +50
    Awsome guy XP: +100
     
  3. Offline

    Nohup

    Hope it meets your needs :) You mentioned RP in your request so I tried to take that into account for my implementation as well. Let me know how it works. I am thinking I want to add support for two more signs: Input value and number of blocks of the conversion type that would be created.
     
  4. Offline

    Daveyo

    so is this working well? I have some good ideas to use this for. Testing
     
  5. Offline

    Nohup

    well, it works well for me, but you know developers never catch their own bugs... I have built out an extensive configuration and tried several permutations though so it seems solid. The one thing I haven't really played with is the box configuration. It should works as long as all the pieces are within the same cube. The only direct requirements I put in was that the redstone torch was under the box itself. Other than that the sign and button can be anywhere around it.
     
  6. Offline

    Daveyo

    not working for me im very sad to say. cb456 Was going to make this a snowball machine haha.

    Anyway, I typed the sign up. Dug the hole, put the redstone torch, put the stone, put the chest ontop of the torch area and placed the button.

    The device is reacting by deleting everything if i put stone in it. And if i put just snowballs in it then it does nothing except rearrange them to the top left. Does this have a max bukkit version?

    material:
    stone:
    value: 16
    snow_ball:
    value: 1
    --- merged: Mar 2, 2011 12:35 AM ---
    also can i request that you have multiple config files for different stones, and an only op can create option.

    would make this basically a fully working traders chest, only better. I hope there is a remedy for my error :(
    --- merged: Mar 2, 2011 12:59 AM ---
    Code:
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 0
     >
     19:58:24 [INFO] Item: 1
     >
     19:58:24 [INFO] Overall value is 160
     >
     19:58:24 [SEVERE] Exception in thread "Thread-72"
     >
     19:58:24 [SEVERE] java.lang.NullPointerException
     >
     19:58:24 [SEVERE]     at com.nohupgaming.minecraft.util.PhilosophersUtil.createItems(PhilosophersUtil.java:52)
     >
     19:58:24 [SEVERE]     at com.nohupgaming.minecraft.ContentConverter.run(ContentConverter.java:56)
     >
     19:58:24 [SEVERE]     at java.lang.Thread.run(Unknown Source)
     
  7. Offline

    Nohup

    @Daveyo - First, the config file (as with all .yml files you will find in these plugins) has a heavy dependency on its spacing. You can't just write it flat as in your example, you have to indent properly (with spaces, no tabs).

    I have put out a new version to remove alot of the spam you see in your log there (I left some debug statements in at first), and I added a null check where the NPE came from, but I think if your config had been right then the null would not have happened. so for you config if should be:

    Code:
    material:
        stone:
            value: 16
        snow_ball:
            value: 1
    
    Not sure what you mean by "multiple config files for different stones" though. Can you explain?
     
  8. Offline

    Daveyo

    Sorry i know pasting it in like that looks like i changed it, but i used notepad+ and have the exact same format as you.

    Code:
    material:
        stone:
            value: 16
        snow_ball:
            value: 1
    

    is what i had
     
  9. Offline

    Nohup

    have you gotten the latest and are you still having an issue? If so can you paste the console in for me again?
     
  10. Offline

    Arisilde

    This is pretty awesome :D any possibility of getting permissions support?
     
  11. Offline

    Carnage104

    Permissions support would be fantastic!
     
  12. Offline

    solid

    Options fulled file would be fine to :)
    I mean file, that conversion value contains
     
  13. Offline

    Daveyo

    works like a charm. Also I noticed I need to have it completely level around it to make sure it worked in case anyone is having issues.
     
  14. Offline

    MacVaultDweller

    Is it posible for you place in the config file
    #Philosopher's Box creation
    op only =true/false

     
  15. Offline

    Nohup

    Permissions support has been added as of v 1.2, the new jar is out there and available.

    @MacVaultDweller - I think this takes care of your need as well, but not sure if when you say op you are talking about op in Essentials or not...
     
  16. Offline

    mightyb

    This is exactly what we've been looking for! Thank you!
     
  17. Offline

    MacVaultDweller

    Thanks for the hard work on such an awesome mod but what I was looking for was an option that would not require
    permissions plugin. permissions plugins of all types break great mods when they fail to update. What I am
    suggesting is that if your mod loads and sees that there is no permissions plugin then it would default to the setting
    op only =true/false
    Sorry that I did not clarify my request.
    Keep up the great work because it's outstanding.
     
  18. Offline

    Nohup

    I should be able to accomodate that, you just wouldn't get the robust nature that Permissions allows (i.e. I can convert to gold, but you can convert to diamond)
     
  19. Offline

    MacVaultDweller

    Thats perfectly fine and will do nicely thank you so very much
     
  20. Offline

    LucidCraft

    Fantastic plugin! Only issue I'm experiencing is that it says "Unable to locate Philosopher's Box, please check your configuration.", whenever any button not connected to a Philosopher's Box is pressed.

    Anyone else experiencing this? The boxes work great and I've ensured proper YAML spacing and syntax. Any feedback welcome. : )

    Thank you in advance.
     
  21. Offline

    Carnage104

    Can we get a list of all the correct spellings for the items this plugin uses, i must have named or spelt the items wrong 50 times now..
    Also, @LucidCraft, i am experiencing the same issue on my server
     
  22. Offline

    Devlah

    This is excellent! I am having a little trouble with the config.yml file generated by the plugin however.
    When opened with notepad, it seems to lack the clean formatting that you've displayed here in the thread. Would you be able to supply a template of some kind? I'm also unsure where I could find the proper naming convention and syntax to use for assigning block values. I see that stone is quite clearly "stone:" and snowball would be "snow_ball:", but how or where would I learn the correct names of other blocks to specify?
    Thanks in advance.
     
  23. Offline

    LucidCraft

  24. Offline

    Nohup

    I am building a wiki for my plugins, and it has a link for the block types appendix here.

    As for the config when the system outputs it uses a different CRLF setting. If you open it in WordPad you should see the clean format, and then once you say it (you may be warned that you are saving in a text only format) then it should be clean in notepad as well.
    --- merged: Mar 6, 2011 7:26 AM ---
    Version 1.3 is now available for download.

    @MacVaultDweller - Added a top-level opsonly entry to the config that would be:

    Code:
    opsonly: true
    material:
        ...
    
    @LucidCraft, @Carnage104 - Removed the message you were seeing so you should no longer be spammed :)
     
  25. Offline

    Jorrdan

    What texture pack are you using? Also this is a nice idea for a plugin :)
     
  26. Offline

    Nohup

    I think that one was called HD Photographic Reality or something like that, and thanks
     
  27. Offline

    MacVaultDweller

    Thank you!
     
  28. Offline

    LucidCraft

    Thank you for the follow up and all your hard work on this plugin, Nohup!

    Sincerely appreciated! :D
     
  29. Offline

    flea1777

    right i need help with this my permissions looks nothing like urs with the what ever u put in and i cant get this to work could you post underneath this a working one for this group please

    Admins:
    default: false
    info: {prefix: '', suffix: '', build: true}
    inheritance: [Moderator]
    permissions: ['*']
     
  30. Offline

    Carnage104

    Thanks again nohup, this is really great!
     

Share This Page