mirror of
https://gitlab.com/phoenix-dvpmt/mmoitems.git
synced 2024-12-22 04:37:42 +01:00
Fixed startup error with furnace/campfire recipes
This commit is contained in:
parent
79ec79b4c5
commit
56359e0b61
@ -36,9 +36,13 @@ import org.jetbrains.annotations.NotNull;
|
||||
@Deprecated
|
||||
public class RMGRR_LegacyBurning implements RecipeRegistry {
|
||||
private final CraftingType craftingType;
|
||||
@SuppressWarnings("NotNullFieldNotInitialized")
|
||||
@NotNull
|
||||
private final ItemStack displayListItem;
|
||||
|
||||
public RMGRR_LegacyBurning(CraftingType craftingType) {
|
||||
this.craftingType = craftingType;
|
||||
displayListItem = RecipeEditorGUI.rename(craftingType.getItem(), FFPMMOItems.get().getExampleFormat() + capitalizeFirst(getRecipeConfigPath()) + " Recipe");
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@ -48,14 +52,10 @@ public class RMGRR_LegacyBurning implements RecipeRegistry {
|
||||
|
||||
@NotNull public static String capitalizeFirst(@NotNull String str) { return str.substring(0, 1).toUpperCase() + str.substring(1); }
|
||||
|
||||
@NotNull @Override public String getRecipeConfigPath() { return getLegacyBurningType().name().toLowerCase(); }
|
||||
@NotNull @Override public String getRecipeConfigPath() { return craftingType.name().toLowerCase(); }
|
||||
|
||||
@NotNull @Override public String getRecipeTypeName() { return "§8{§4§oL§8} " + capitalizeFirst(getRecipeConfigPath()); }
|
||||
|
||||
@SuppressWarnings("NotNullFieldNotInitialized")
|
||||
@NotNull
|
||||
private final ItemStack displayListItem = RecipeEditorGUI.rename(getLegacyBurningType().getItem(), FFPMMOItems.get().getExampleFormat() + capitalizeFirst(getRecipeConfigPath()) + " Recipe");
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public ItemStack getDisplayListItem() {
|
||||
@ -93,7 +93,7 @@ public class RMGRR_LegacyBurning implements RecipeRegistry {
|
||||
|
||||
// Yes
|
||||
MMOItems.plugin.getRecipes().registerBurningRecipe(
|
||||
getLegacyBurningType().getBurningType(),
|
||||
craftingType.getBurningType(),
|
||||
template.newBuilder(0, null).build(),
|
||||
info, outputAmount, namespace.getValue(), hideBook);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user