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.item.UseOnContext;

Link to g-

Name: getClickLocation

Return Type: Vec3

ZenScript
Copy
// UseOnContext.getClickLocation() as Vec3

myUseOnContext.getClickLocation();

Link to g--1

Name: getClickedFace

Return Type: Direction

ZenScript
Copy
// UseOnContext.getClickedFace() as Direction

myUseOnContext.getClickedFace();

Link to g--2

Name: getClickedPos

Return Type: BlockPos

ZenScript
Copy
// UseOnContext.getClickedPos() as BlockPos

myUseOnContext.getClickedPos();

Name: getHand

Return Type: InteractionHand

ZenScript
Copy
// UseOnContext.getHand() as InteractionHand

myUseOnContext.getHand();

Link to g--4

Name: getHorizontalDirection

Return Type: Direction

ZenScript
Copy
// UseOnContext.getHorizontalDirection() as Direction

myUseOnContext.getHorizontalDirection();

Link to g--5

Name: getItemInHand

Return Type: ItemStack

ZenScript
Copy
// UseOnContext.getItemInHand() as ItemStack

myUseOnContext.getItemInHand();

Link to g--6

Name: getLevel

Return Type: Level

ZenScript
Copy
// UseOnContext.getLevel() as Level

myUseOnContext.getLevel();

Link to g--7

Name: getPlayer

Return Type: Player

ZenScript
Copy
// UseOnContext.getPlayer() as Player

myUseOnContext.getPlayer();

Link to g--8

Name: getRotation

Return Type: float

ZenScript
Copy
// UseOnContext.getRotation() as float

myUseOnContext.getRotation();

Link to g--9

Name: isInside

Return Type: boolean

ZenScript
Copy
// UseOnContext.isInside() as boolean

myUseOnContext.isInside();

Link to g--10

Name: isSecondaryUseActive

Return Type: boolean

ZenScript
Copy
// UseOnContext.isSecondaryUseActive() as boolean

myUseOnContext.isSecondaryUseActive();
NameTypeHas GetterHas SetterDescription
Name
clickLocation
Type
Vec3
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
clickedFace
Type
Direction
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
clickedPos
Type
BlockPos
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
hand
Type
InteractionHand
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
horizontalDirection
Type
Direction
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
isInside
Type
boolean
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
isSecondaryUseActive
Type
boolean
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
itemInHand
Type
ItemStack
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
level
Type
Level
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
player
Type
Player
Has Getter
true
Has Setter
false
Description
No Description Provided
Name
rotation
Type
float
Has Getter
true
Has Setter
false
Description
No Description Provided