Invalid leaf directive! `since`

Identifies a fully free-form JEI category, which allows custom background, drawable, and slot placement.

This class was added by a mod with mod-id jeitweaker. Так что если вы хотите использовать эту функцию, вам нужно установить этот мод.

Импорт класса

Link to импорт-класса

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

ZenScript
Copy
import mods.jei.category.Custom;

Extending SimpleJeiCategory

Link to extending-simplejeicategory

Custom extends SimpleJeiCategory. That means all methods available in SimpleJeiCategory are also available in Custom

Name: addDrawable

Places a new JeiDrawable at the given coordinates.

Return Type: void

ZenScript
Copy
Custom.addDrawable(x as int, y as int, drawable as JeiDrawable) as void
ПараметрТипОписание
Параметр
x
Тип
int
Описание
The x coordinate where the drawable should be placed.
Параметр
y
Тип
int
Описание
The y coordinate where the drawable should be placed.
Параметр
drawable
Тип
JeiDrawable
Описание
The drawable to add.

Name: addSlot

Places a new slot to this recipe with the given index at the specified coordinates.

Return Type: void

ZenScript
Copy
Custom.addSlot(index as int, x as int, y as int, isInput as boolean) as void
ПараметрТипОписание
Параметр
index
Тип
int
Описание
The slot index. Must be unique.
Параметр
x
Тип
int
Описание
The x coordinate where the slot should be placed.
Параметр
y
Тип
int
Описание
The y coordinate where the slot should be placed.
Параметр
isInput
Тип
boolean
Описание
Whether the slot is an input (true) or an output (false) slot.

Name: addText

Adds a new text area that appears at the given coordinates.

The added text area is global, meaning it appears in all recipes the same way.

Return Type: void

ZenScript
Copy
Custom.addText(x as int, y as int, text as MCTextComponent) as void
ПараметрТипОписание
Параметр
x
Тип
int
Описание
The x coordinate where the text should appear.
Параметр
y
Тип
int
Описание
The y coordinate where the text should appear.
Параметр
текст
Тип
Компонент MCTextcomponent
Описание
The text that should appear.

Name: addTooltip

Adds a new tooltip that appears when the mouse is in a rectangle active area of width w and height h at the specified coordinates with the given text.

The tooltip is global, meaning it appears in all recipes with the same text.

Return Type: void

ZenScript
Copy
Custom.addTooltip(x as int, y as int, w as int, h as int, text as MCTextComponent[]) as void
ПараметрТипОписание
Параметр
x
Тип
int
Описание
The x coordinate of the top-left corner of the active area.
Параметр
y
Тип
int
Описание
The y coordinate of the top-left corner of the active area.
Параметр
w
Тип
int
Описание
The width of the rectangle that determines the active area.
Параметр
h
Тип
int
Описание
The height of the rectangle that determines the active area.
Параметр
текст
Тип
MCTextComponent[]
Описание
A list of MCTextComponents indicating the text that should be present in the tooltip.

Свойства

Link to свойства

НазваниеТипИмеет GetterИмеет SetterОписание
Название
background
Тип
void
Имеет Getter
false
Имеет Setter
true
Описание
Sets the JeiDrawable which acts as the background of this category.
Название
canHaveShapelessMarker
Тип
void
Имеет Getter
false
Имеет Setter
true
Описание
Sets whether recipes in this category can be marked as shapeless.