Closed Llama-Lordie closed 1 year ago
Hello. Thank you for using CR. This error occurs when it tries to parse a number - but it isn't a number. Are you using default-generated files?
To fix this there is a line in each recipe file that says 'Item-Damage:'. You will want to make sure that it is set to 'none' or a valid integer.
Example:
Enabled: true
Shapeless: true
Item: 'DIAMOND_SWORD'
Item-Damage: 'none' <-----
Amount: 1
Ignore-Data: false
Ignore-Model-Data: false
Custom-Tagged: true
Identifier: 'CURSED_SWORD'
Permission: 'crecipe.recipe.cursedsword'
Name: '&eCursed Sword'
Lore:
- '&fThe Cursed Sword'
Effects:
- 'POISON:20:2'
Hide-Enchants: true
Enchantments:
- 'DURABILITY:300'
ItemCrafting:
- 'DDD'
- 'XPX'
- 'XPX'
Ingredients:
D:
Material: DIAMOND
Identifier: none
Amount: 1
Name: 'Diamond Shrine'
P:
Material: OAK_PLANKS
Identifier: none
Amount: 1
Name: 'Wooden Board'
Attribute: []
Custom-Model-Data: none```
That is probably the issue, I am using this plugin to add custom recipes for vanilla items that arent in vanilla minecraft, so I simplified the file as much as I could, and the github says that Item damage is not necessary so I deleted it, however since I am using 1.15.2 it could be neccessary
I am using 3 custom recipes atm Saddle: Enabled: true Shapeless: false Item: SADDLE Amount: 1 Identifier: SADDLE Hide-Enchants: false ItemCrafting:
Honey_Piston: Enabled: true Shapeless: false Item: STICKY_PISTON Amount: 1 Identifier: HONEY_PISTON Hide-Enchants: false ItemCrafting:
LEATHER: Enabled: true Shapeless: true Item: LEATHER Amount: 1 Identifier: LEATHER Hide-Enchants: false ItemCrafting:
Go ahead and add Item-Damage: 'none' back in, it is causing the error. My apologies.
Now that the plugin works on the server whenever i type "/crecipe list" it comes back with "Invalid page number" no matter which number I put after the command
That means that none of the recipes got loaded in. Are there any errors or any warnings in console when you load in the plugin? Can you pastebin.com your recipe files or ZIP them and let me download them so I can assist and fix it for you?
Okay, one second.
Just gonna send a message to check in on how its going, this isnt a super important bug, just sending a follow-up to make sure you didnt forget
Hello, sorry about that! I got super busy. I just tested it, and yes stupid I know, but the reason why your recipes are not working is because in your Leather.yml, the very top portion needs to match the file name. So you should be changing "LEATHER:" to "Leather:" in the recipe file. This is case-sensitive.
Again, I don't think this small issue should break the entire plugin, but it did, and I will make some adjustments and provide a future update so this no longer happens. Doing this should solve your issue.
Let me know if you need any additional assistance, and sorry again for this! Thank you!
[23:22:57] [Server thread/ERROR]: Error occurred while enabling CustomRecipes v1.7.4 (Is it up to date?)
140 | java.lang.NumberFormatException: null 141 | at java.lang.Integer.parseInt(Integer.java:542) ~[?:1.8.0_372] 142 | at java.lang.Short.parseShort(Short.java:118) ~[?:1.8.0_372] 143 | at java.lang.Short.valueOf(Short.java:174) ~[?:1.8.0_372] 144 | at java.lang.Short.valueOf(Short.java:200) ~[?:1.8.0_372] 145 | at me.mehboss.recipe.RecipeManager.handleItemDamage(RecipeManager.java:51) ~[?:?] 146 | at me.mehboss.recipe.RecipeManager.addItems(RecipeManager.java:229) ~[?:?] 147 | at me.mehboss.recipe.Main.onEnable(Main.java:320) ~[?:?] 148 | at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 149 | at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:351) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 150 | at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:480) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 151 | at org.bukkit.craftbukkit.v1_15_R1.CraftServer.enablePlugin(CraftServer.java:464) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 152 | at org.bukkit.craftbukkit.v1_15_R1.CraftServer.enablePlugins(CraftServer.java:378) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 153 | at net.minecraft.server.v1_15_R1.MinecraftServer.a(MinecraftServer.java:457) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 154 | at net.minecraft.server.v1_15_R1.DedicatedServer.init(DedicatedServer.java:274) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 155 | at net.minecraft.server.v1_15_R1.MinecraftServer.run(MinecraftServer.java:784) [minecraft_server.jar:git-Spigot-a99063f-be6aaf0] 156 | at java.lang.Thread.run(Thread.java:750) [?:1.8.0_372]
I am using the newest version (1.7.4)