Holds general game information. Can be accessed using the game global keyword

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.game.MCGame;

Name: localize

Returns: a localized String
Return Type: string

ZenScript
Copy
// MCGame.localize(translationKey as string) as string

game.localize("gui.up");
ParameterTypeDescription
Parameter
translationKey
Type
string
Description
No Description Provided
名称TypeHas GetterHas SetterDescription
名称
blockStates
Type
Collection<MCBlockState>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
blocks
Type
Collection<MCBlock>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
directionAxises
Type
Collection<DirectionAxis>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
effects
Type
Collection<MCPotionEffect>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
enchantments
Type
Collection<MCEnchantment>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
entityClassifications
Type
Collection<MCEntityClassification>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
entityTypes
Type
Collection<MCEntityType>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
fluids
Type
Collection<MCFluid>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
formattings
Type
Collection<TextFormatting>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
items
Type
Collection<IItemStack>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
potions
Type
Collection<MCPotion>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
recipeTypes
Type
Collection<IRecipeManager>
Has Getter
true
Has Setter
false
Description
No Description Provided
名称
villagerProfessions
Type
Collection<MCVillagerProfession>
Has Getter
true
Has Setter
false
Description
No Description Provided