Home Getting Started With Scripts Using this wiki Commands CTGUI Global functions Bracket Handlers
ContentTweaker Commands WalkThrough

Hand

A Hand is an enumeration of the player’s two possible hands: main and off

Importing the package

It might be required for you to import the package if you encounter any issues, so better be safe than sorry and add the import.
import mods.contenttweaker.Hand;

Enumerations

Hand can be of those two values:

  • main
  • off
script.zs
import mods.contenttweaker.Hand;
Hand.off();
Hand.main();
Hand.fromString("off");
Hand.fromString("main");

Uses

A Hand’s main use is in a IItemUse Function.

Comparing two Hand objects

You can compare two Hand objects using the == getter.

script.zs
Hand.main() == Hand.main()