Deprecated
This class has been replaced by crafttweaker.api.item.ItemGroup

An item Group (a.k.a. Creative Tab) is a grouping of items based on category.

This class was added by a mod with mod-id contenttweaker. 因此,如果要使用此功能,则需要安装此mod。

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.contenttweaker.item.MCItemGroup;

已实现的接口

Link to 已实现的接口

MCItemGroup implements the following interfaces. That means all methods defined in these interfaces are also available in MCItemGroup

结果类型是否隐藏
结果类型
ItemGroup
是否隐藏
true

Name: getPath

Deprecated
This class has been replaced by crafttweaker.api.item.ItemGroup

Gets the path of the item group. The path is what you use in the Bracket Expression after the <itemGroup: part.

Return Type: string

ZenScript
Copy
// MCItemGroup.getPath() as string

<itemgroup:misc>.getPath();

Link to g-setbackgroundimagename

Name: setBackgroundImageName

Deprecated
This class has been replaced by crafttweaker.api.item.ItemGroup

Sets the image name of the Background that is used for this tab in the creative menu

Returns: This object for chaining
Return Type: MCItemGroup

ZenScript
Copy
MCItemGroup.setBackgroundImageName(texture as string) as MCItemGroup
参数类型描述
参数
texture
类型
string
描述
The texture to be used

Name: setNoScrollbar

Deprecated
This class has been replaced by crafttweaker.api.item.ItemGroup

Removes the scrollbar of the item Group in the creative inventory

Returns: This object for chaining
Return Type: MCItemGroup

ZenScript
Copy
// MCItemGroup.setNoScrollbar() as MCItemGroup

<itemgroup:misc>.setNoScrollbar();

Name: setNoTitle

Deprecated
This class has been replaced by crafttweaker.api.item.ItemGroup

Removes the title of the item Group in the creative inventory

Returns: This object for chaining
Return Type: MCItemGroup

ZenScript
Copy
// MCItemGroup.setNoTitle() as MCItemGroup

<itemgroup:misc>.setNoTitle();
名称类型可获得可设置描述
名称
path
类型
string
可获得
true
可设置
false
描述
Gets the path of the item group. <br /> The path is what you use in the Bracket Expression after the <itemGroup: part.