FastCraft

FastCraft

138k Downloads

Unable To Use LORE For Ingredient Items

Drag0nz69 opened this issue · 4 comments

commented

Remove these top lines, and replace all {brace-enclosed text}.

Description

I am not sure if this is an error, a feature request, or I am just doing something wrong....

Several of the custom recipes we use on our server use custom drops as part of their ingredients. I am doing some more testing of your plugin and recent updates. Unfortunately, I can not get any recipe to work which uses an item that has a custom LORE. The items we are using have a custom Name, Lore, and a standard Enchantment. I can set it to use the custom name with the enchantment. As long as I leave the lore off it works. As soon as I add the lore to the item it will not recognize it.

Here is an example Recipe:

 Draconian_Helm:
   type: shaped
   ingredients:
     a: ['minecraft:emerald', ANY, '{display:{Name:"§cDraconian §aEmerald",Lore:"Dragon Gem"},ench:[{id:20,lvl:1}]}']
     b: ['minecraft:leather_helmet']
   shape:
   - 'aaa'
   - 'aba'
   - 'aaa'
   result: [1, 'minecraft:leather_helmet', 0, '{display:{Color:1606152,Name:"§cDraconian §aEmerald Helm",Lore:"§cDraconian §aRelic"},ench:[{id:0,lvl:6},{id:34,lvl:3}]}']
commented

This is fixed for v0.15. The § character was causing problems, so the config files are now being read with the UTF-8 charset.

commented

This is not fixed for me. I still am unable to use custom items with a LORE value as an ingredient for a custom recipe. Example:

Draconian_Helm:
type: shaped
ingredients:
a: ['minecraft:emerald', ANY, '{display:{Name:"§cDraconian §aEmerald",Lore:"Dragon Gem"},ench:[{id:20,lvl:1}]}']
b: ['minecraft:leather_helmet']
shape:

  • 'aaa'
  • 'aba'
  • 'aaa'
    result: [1, 'minecraft:leather_helmet', 0, '{display:{Color:1606152,Name:"§cDraconian §aEmerald Helm",Lore:"§cDraconian §aRelic"},ench:[{id:0,lvl:6},{id:34,lvl:3}]}']

With this recipe if I have in my inventory Emeralds that match the above Name and Lore - it does not recognize them for the crafting. However, if I give myself the emeralds with the custom name only, and no Lore, then it shows the crafting available. The problem is I already have a lot of items on the server which have LORE values.

commented

I found the problem. You're misconfiguring the lore. The lore is an array of Strings, not a single String.
Instead of Lore:"Dragon Gem", try Lore:["Dragon Gem"]

commented

Perfect!!!!

I hate it when its a syntax error on my end - but that fixed it. Thanks again!!!

-Drag0nz