Global ZenCode Keywords
Link to global-zencode-keywords
This file contains a list of Global keywords you can use in CraftTweaker. These are used in order to do some menial tasks.
グローバル関数
Link to グローバル関数
print(argument as string)
Prints a string to thecrafttweaker.log
fileprintln(argument as string)
Prints a string, on a new line, to thecrafttweaker.log
file.
Global Getters
Link to global-getters
Global Getters get a value for you. They are mostly used for adding recipes.
blastFurnace
gets you the BlastFurnaceRecipeManager Instance.campfire
gets you the CampFireRecipeManager Instance.cauldron
gets you the Cauldron Interaction Manager.composter
gets you the Composter handler.craftingTable
gets you the CraftingTableRecipeManager Instance.furnace
gets you the FurnaceRecipeManager Instance.game
gets you the Game object for you to use.loadedMods
gets you the list of Mods.loot
gets you the LootManager Instance.recipes
gets you the GenericRecipesManager Instance.smithing
gets you the SmithingRecipeManager Instance.smoker
gets you the SmokerRecipeManager Instance.stonecutter
gets you the StoneCutterManager Instance.tags
gets you the global CraftTweakerTagRegistry.villagerTrades
gets you the VillagerTrades handler.
The CraftTweakerTagRegistry
Link to the-crafttweakertagregistry
The CraftTweakerTagRegistry is a class with a single method, used to do dynamic string manipulations with tags.
Since the following isn't doable with tags:
ZenScript Copyvar colour = "white" + "_";
<tag:items:minecraft:${colour}wool>...
This exists to amend that, so you can do:
ZenScript Copyvar colour = "white" + "_";
tags.tagManager(<resource:minecraft:items>).tag(<resource:minecraft:${colour}wool>)
Forge Only
Link to forge-only
brewing
gets you the Brewing manager from which you can use the methods inside of the class