UnknownTagManager

Link to unknowntagmanager

Importing the class

Link to importing-the-class

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 crafttweaker.api.tag.manager.type.UnknownTagManager;

Implemented Interfaces

Link to implemented-interfaces

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

Name: addId

Return Type: void

ZenScript
Copy
UnknownTagManager.addId(to as UnknownTag, values as ResourceLocation[]) as void
ParameterTypeDescription
Parameter
to
Type
UnknownTag
Description
No Description Provided
Parameter
values
Type
ResourceLocation[]
Description
No Description Provided

Name: exists

Checks if a tag with the given id exists and is registered.

Returns: true if it exists, false otherwise.
Return Type: boolean

ZenScript
Copy
// UnknownTagManager.exists(id as ResourceLocation) as boolean

myUnknownTagManager.exists(<resource:minecraft:wool>);
ParameterTypeDescription
Parameter
id
Type
ResourceLocation
Description
The id of the tag to check.

Name: exists

Checks if a tag with the given id exists and is registered.

Returns: true if it exists, false otherwise.
Return Type: boolean

ZenScript
Copy
// UnknownTagManager.exists(id as string) as boolean

myUnknownTagManager.exists("minecraft:wool");
ParameterTypeDescription
Parameter
id
Type
string
Description
The id of the tag to check.

Name: exists

Checks if the given tag exists and is registered.

Returns: true if it exists, false otherwise.
Return Type: boolean

ZenScript
Copy
// UnknownTagManager.exists(tag as T) as boolean

myUnknownTagManager.exists(<tag:items:minecraft:wool>);
ParameterTypeDescription
Parameter
tag
Type
T
Description
The tag to check.

Name: getTagsFor

Ges the tags that contain the given element.

Returns: The tags that contain the given elements.
Return Type: stdlib.List<T>

ZenScript
Copy
UnknownTagManager.getTagsFor(element as ResourceLocation) as stdlib.List<T>
ParameterTypeDescription
Parameter
element
Type
ResourceLocation
Description
No Description Provided

Name: idElements

Gets the ResourceLocation ids of the elements in the given tag.

Returns: A List of ResourceLocation ids of the elements in the given tag.
Return Type: stdlib.List<ResourceLocation>

ZenScript
Copy
// UnknownTagManager.idElements(of as T) as stdlib.List<ResourceLocation>

myUnknownTagManager.idElements(<tag:items:minecraft:wool>);
ParameterTypeDescription
Parameter
of
Type
T
Description
The tag to get the elements of.

Name: removeId

Return Type: void

ZenScript
Copy
UnknownTagManager.removeId(from as UnknownTag, values as ResourceLocation[]) as void
ParameterTypeDescription
Parameter
from
Type
UnknownTag
Description
No Description Provided
Parameter
values
Type
ResourceLocation[]
Description
No Description Provided

Name: tag

Return Type: UnknownTag

ZenScript
Copy
UnknownTagManager.tag(id as ResourceLocation) as UnknownTag
ParameterTypeDescription
Parameter
id
Type
ResourceLocation
Description
No Description Provided

Name: tag

Return Type: UnknownTag

ZenScript
Copy
UnknownTagManager.tag(id as string) as UnknownTag
ParameterTypeDescription
Parameter
id
Type
string
Description
No Description Provided

Name: tagFolder

Gets the tagFolder of this manager.

The tag folder is usually the folder on disk without the tags/ prefix.

Examples:

  • `tags/items` turns into `items`
  • `tags/potion` turns into `potion`
  • `tags/worldgen/biome` turns into `worldgen/biome`

Returns: The tag folder of this manager.
Return Type: string

ZenScript
Copy
// UnknownTagManager.tagFolder() as string

myUnknownTagManager.tagFolder();

Name: tagMap

Return Type: UnknownTag[ResourceLocation]

ZenScript
Copy
// UnknownTagManager.tagMap() as UnknownTag[ResourceLocation]

myUnknownTagManager.tagMap();

Name: tags

Ges the tags that this manager knows about.

Returns: The tags that this manager knows about.
Return Type: stdlib.List<T>

ZenScript
Copy
// UnknownTagManager.tags() as stdlib.List<T>

myUnknownTagManager.tags();

Name: CONTAINS

Checks if a tag with the given id exists and is registered.

ZenScript
Copy
id as string in myUnknownTagManager
"minecraft:wool" in myUnknownTagManager
NameTypeHas GetterHas SetterDescription
Name
tagFolder
Type
string
Has Getter
true
Has Setter
false
Description
Gets the tagFolder of this manager.

The tag folder is usually the folder on disk without the tags/ prefix.

Examples:

  • tags/items turns into items

  • tags/potion turns into potion

  • tags/worldgen/biome turns into worldgen/biome

Name
tagMap
Type
UnknownTag[ResourceLocation]
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
tags
Type
stdlib.List<T>
Has Getter
true
Has Setter
false
Description
Ges the tags that this manager knows about.