Skip to content

Easy to use Paper plugin for creating custom items

Notifications You must be signed in to change notification settings

olillin/RainbowQuartz

Repository files navigation

RainbowQuartz

build coverage

RainbowQuartz is an easy to use plugin for creating custom items.

Features

  • Creating custom items
  • Editing basic properties of those items (name, lore, item type)
  • Creating and editing recipes for those items
  • Registering event handlers for custom items with API

Planned features

  • Live updates of pre-existing items on modification
  • Registering event handlers in GUI
  • Custom enchantments
  • API support for registering custom recipe types

Creating items

RainbowQuartz enables two ways of creating items: by using the API in another plugin or with the in-game GUI.

Creating items with the API

Kotlin example

MyPlugin.kt

val builder = ItemBuilder(NamespacedKey(this, "emerald_pickaxe"))
    .setName(Component.text("Emerald pickaxe")
        .color(NamedTextColor.GREEN))
    .addLore("Lorem ipsum")
    .addRecipe(
        ShapedRecipe("RRR", " S ", " S ")
            .setIngredient('R', Material.EMERALD)
            .setIngredient('S', Material.STICK))
RainbowQuartz.itemManager.registerDefault(builder.build())
Java example

MyPlugin.java

ItemBuilder builder = new ItemBuilder(new NamespacedKey(this, "emerald_pickaxe"), Material.DIAMOND_PICKAXE, new ArrayList<>())
    .setName(Component.text("Emerald pickaxe")
         .color(NamedTextColor.GREEN))
    .addLore("Lorem ipsum")
    .addRecipe(
        new ShapedRecipe("RRR", " S ", " S ")
            .setIngredient('R', new Ingredient(Material.EMERALD, null))
            .setIngredient('S', new Ingredient(Material.STICK, null)));
RainbowQuartz.Companion.getItemManager().registerDefault(builder.build());

For more examples using the API have a look at the RainbowQuartzExample plugin.

Creating items with the in-game GUI

The GUI is the selling feature of RainbowQuartz, allowing for the creation and modfication of custom items all without restarting the server.

  1. Open the GUI with the /rainbowquartz command

  2. Open the Item Editor
    Click on Item Editor in main menu

  3. Click the New item button in the top left

  4. Set your item id
    Click on Set item id
    Enter your item id and click Submit

  5. Set your material by placing an item with the material from your inventory in the first slot.
    Click on Set material
    Place your material in the first slot and click Submit

  6. Click the Submit button
    Click on Submit

  7. Modify any additional properties

  8. Click the Back button to save the item

  9. You've created your first item! 🎉

About

Easy to use Paper plugin for creating custom items

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Languages