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.loot.LootContext;
名称TypeHas GetterHas Setter
名称
blockEntity
Type
BlockEntity?
Has Getter
true
Has Setter
false
名称
blockState
Type
BlockState?
Has Getter
true
Has Setter
false
名称
damageSource
Type
DamageSource?
Has Getter
true
Has Setter
false
名称
directKillerEntity
Type
Entity?
Has Getter
true
Has Setter
false
名称
explosionRadius
Type
float
Has Getter
true
Has Setter
false
名称
killerEntity
Type
Entity?
Has Getter
true
Has Setter
false
名称
lastDamagePlayer
Type
Player?
Has Getter
true
Has Setter
false
名称
level
Type
ServerLevel
Has Getter
true
Has Setter
false
名称
luck
Type
float
Has Getter
true
Has Setter
false
名称
origin
Type
Vec3?
Has Getter
true
Has Setter
false
名称
random
Type
RandomSource
Has Getter
true
Has Setter
false
名称
thisEntity
Type
Entity?
Has Getter
true
Has Setter
false
名称
tool
Type
IItemStack
Has Getter
true
Has Setter
false