Giter Site home page Giter Site logo

stevommmm / shopkeepers Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nisovin/shopkeepers

0.0 2.0 0.0 18.9 MB

A Bukkit plugin to create custom villager shopkeepers.

Home Page: http://dev.bukkit.org/bukkit-plugins/shopkeepers/

License: GNU General Public License v3.0

Java 100.00%

shopkeepers's Introduction

Shopkeepers

Shopkeepers is a Bukkit plugin which allows you to set up custom villager shopkeepers that sell exactly what you want them to sell and for what price. You can set up admin shops, which have infinite supply, and you can also set up player shops, which pull supply from a chest.

BukkitDev Page: http://dev.bukkit.org/bukkit-plugins/shopkeepers/
Forums: http://nisovin.com/forums/index.php?forums/shopkeepers/
Dev builds: http://ci.cube-nation.de/job/Shopkeepers/

Guidelines

All "volatile" code (any code that relies on CraftBukkit and will break with version updates) should be in the volatilecode package. Please keep this code to a minimum wherever possible, as adding more volatile code makes the updating process more difficult. If it is possible to create a non-volatile fallback method, please do so and put it in the FailedHandler class.

For any major feature changes, please make a forum thread about it and/or create an extra branch so it can be discussed before you commit the code to the main repository.

Build with Maven

This is the recommended and easy way to compile the plugin yourself and/or help to contribute to it. Just check out the project to your machine and import it in Eclipse with Import > Maven > Existing Maven Project. Then just right click the imported project and select Run As > Maven install.

Build without Maven

If you really want to do it the old school way, you're free to import the project in Eclipse with Import > General > Existing Project into Workspace. You'll find that the project will instantly show some errors because it's missing its' dependencies. You also need to make sure that you'll include the provided modules (NMSHandlers).

Here's how you do that:

  • after importing the project right click on it and select Properties
  • under Java Build Path > Source click on Add Folder... and add all provided modules:
    • modules/v1_6_R3/src/main/java
    • modules/v1_7_R1/src/main/java
    • ...
  • under Java Build Path > Library click on Add External JARs... and add the needed CraftBukkit.jar files for the modules above
    (you can download them from http://dl.bukkit.org/downloads/craftbukkit)
  • after that you can create the plugin for example by using Rightclick and selecting Export > Java > JAR file or another recommened way

Todo

  • Don't overwrite previously stored Attribute data of items in the save file, if we run on an not yet supported server version (and can't read that attribute data). Instead simple keep this data, to not break all items until an update is available which can interpret it again.
  • Consider replacing the trade interface with a custom one made from a regular inventory. It wouldn't look as nice, but it would potentially allow better functionality. It would be a config option.
  • Improve chest protection (the anti-hopper code is inefficient).
  • Possibly change the way the different "shop object" types are handled to make adding new ones easier.
  • Add MySQL support (maybe someday, certainly not urgent).
  • Move schema.txt into resources folder (?).
  • Fix (Admin) sign shopkeepers not checking during creation, if there actually is a sign targeted.

Ideas (comments please)

  • Per-Trade/Shopkeeper settings, maybe via written books:
    -> by adding another row to the shopkeeper-editor inventory window each trade option and shopkeeper could have a slot for a written-book
    -> which could contain additional meta-data, per-trade/shopkeeper settings, like for example:
    -> "ignore damage/durability" (useful for repair-shops)
    -> "ignore name/lore/etc" (useful when players want to buy a certain item with their shop without being interested in concrete name or other metadata
    -> There should maybe be improved feedback messages then (this should be there probably anyways), to inform players why their trade failed, instead of only cancle it
  • Maybe ignore cancellation of the PlayerInteractEntityEvent when clicking shopkeeper entities to open the shops?
    -> So that shops can also be traded with, even if they are located in some sort of "protected" region of another plugin.
    -> Maybe optional via a setting, so that server owners can activate this, if they have a land protection plugin which gives them no option to allow entity/villager interaction for everyone, not only "region members/owners"
  • Maybe move shop options (like currently name, profession, etc.) into a seperate inventory view to have additional space there

shopkeepers's People

Contributors

blablubbabc avatar derflash avatar lhenni avatar nisovin avatar nathanwolf avatar intangir avatar xephi avatar meiskam avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.