Creating an Ore

This tutorial will explain how to create a custom ore with Custom Ores.

## Creating an Ore in Game

1. If you want your ore to smelt into or drop an item, get it now. This can be a normal item, a custom item, or an item from a supported plugin. If you want to set custom tools for this ore, grab those as well.

2. Run the command */customores create <name> ore.* Make sure to replace the *<name>* with the name that you want for your custom item. Use \_ rather than spaces

4. Get a texture value using this tutorial.

3. Now a UI opens with two options:

A. **Type texture value in chat** *-* Select "Type texture value in chat" then just paste the texture value into the chat and you're done!
B. **Type texture value in the config** - This option is best if your texture value is too long to fit in the chat. Select "Type texture value in the config" and continue making your ore. When you are done, go to the items.yml, go to your ore, and replace the value that is already there with your texture value. Finally, run the reload command.

5. The Ore Settings menu is now open. The first thing you should do here is decide what dimensions you want this ore to spawn in. You can enable or disable spawning in the Overworld, Nether, and End, by clicking the stone, netherrack, and endstone along the top.

6. Set the maximum height for the ore to spawn with the grass block and the minimum height with the bedrock. Left click will increase it and right click will decrease it. Holding shift will cause it to increase/decrease by 10.

7. Put the item you got earlier in the empty slot in the center.

8. If you want the item to drop when the ore is broken, click the furnace below the empty slot so it changes into a dropper. If you want it to run a command when broken. click the furnace twice so it changes into a command block.

9. Set the amount of ores per chunk with the sign.

9a. If you set your ore to run a command when broken, you will now enter that command into the chat. Type it without a slash. @b can be used to refer to the player who broke the ore.

10. To customize the tools this ore uses and how the ore acts when the broken without a tool, click the pickaxe on the left side of the Ore Settings menu. Click the bars on the top left to unlock the tools and drag the tools you want into the menu. Click the diamond on the top right to cycle through different events for when the ore is broken without a tool.

11. To customize the biomes this ore spawns in, click the bush on the right of the Ore Settings menu. Click biomes to toggle them. Use the red and green blocks to enable or disable all biomes at once. The center arrows can be used to access more pages.

12. On the ore setting page, click the arrow. You will now choose whether or not you want a lore. If you do choose to have a lore, just type the lore into the chat.

13. Your ore is now created! You can get the ore by using */customores give*.

## Creating an Ore in the Config

1. Open the Items.yml file. Notice the Example Ore, which you can use as an Example
2. At the top, put the name of your item, like this:
```
§lEnd §6Gold:
```
**Use § for color codes.** & will cause problems!
3. Make sure that *Enabled* is true so that the item will appear in game, like this:
```
§lEnd §6Gold:
  Enabled: true
```
Indent with 2 spaces
4. If you want a lore, add one like this:
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
```
 **Use § for color codes.** & will cause problems! In this example, the Lore will appear as *Why is there gold in the End?*
5. Next, you will add the texture value. Add *Value:* and paste the texture value, like this:
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
```
6. Now set the number of ores per chunk, like this:
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
```
Type *NumberPerChunk:* and then the number that you want
7. Set the *MaxY* and the *MinY*. These are the maximum and minimum height that your ore can spawn at.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
```
In this example, ores will spawn between 15 and 55
8. After that, set which dimension ores will spawn in. You can do this by setting each dimension (*Overworld*, *Nether*, and *End*) as either true or false, like this:
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
```
In this example, ores will only spawn in the end, as that is the only one enabled
9. If you want to restrict ores to certain biomes, add a *Biomes* list.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
```
10. If you want this ore to use different tools from the default in the config.yml then add a *Tools* list.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
  Tools:
    - Golden Shovel
    - Golden Pickaxe
```
11. If you want your ore to behave differently when broken without a tool, add a *No Tool Event*. Setting *No Tool Event* to 1 will cause the ore to drop itself when broken without a tool. Setting it to 2 will cause it to drop nothing without a tool.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
  Tools:
    - Golden Shovel
    - Golden Pickaxe
  No Tool Event: 1
```
12. If you want your ore to smelt into an item you can add one by setting *Smelt Item* as the items name and *Smelt Amount* as the amount of items for your ore to smelt into. You can use normal item, a custom item, or an item from a supported plugin.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
  Tools:
    - Golden Shovel
    - Golden Pickaxe
  No Tool Event: 1
  Smelt Item: gold ingot
  Smelt Amount: 5
```
In this example, the ore will smelt into 5 golden ingots If you want your ore to drop an item when broken, follow the step above but add *Ore Type: 1* to the end of it:
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
  Tools:
    - Golden Shovel
    - Golden Pickaxe
  No Tool Event: 1
  Smelt Item: gold ingot
  Smelt Amount: 5
  Ore Type: 1
```
 In this example, the ore will drop 5 gold ingots If you want your ore to run a command when broken, don't add a *Smelt Item* or *Smelt Amount*. Instead, add *Ore Type: 2* and set *Command* as the command you want the ore to run. Don't include the slash. @b can be used to refer to the player who broke the ore.
```
§lEnd §6Gold:
  Enabled: true
  Lore: §6Why is there gold in the End?
  Value: eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTQ1ZjQ3ZmViNGQ3NWNiMzMzOTE0YmZkYjk5OWE0ODljOWQwZTMyMGQ1NDhmMzEwNDE5YWQ3MzhkMWUyNGI5In19fQ==
  NumberPerChunk: 2
  MaxY: 55
  MinY: 15
  Overworld: false
  Nether: false
  End: true
  Biomes:
    - Small End Islands
    - End Barrens
  Tools:
    - Golden Shovel
    - Golden Pickaxe
  No Tool Event: 1
  Ore Type: 2
  Command: kill @b
```
13. Save the config and enter */customores reload* on your server. The item will now be accessible with */customores give!*