Class: ItemComponentHitEntityEvent
event entity componentBeta
包含使用物品击中实体时的相关信息。
Contains information regarding when an item is used to hit an entity.
Properties
attackingEntity
readonlyattackingEntity:Entity
Beta
Remarks
发起攻击的实体。
The attacking entity.
hadEffect
readonlyhadEffect:boolean
Beta
Remarks
此次击打是否命中或产生了任何效果。
Whether the hit landed or had any effect.
hitEntity
readonlyhitEntity:Entity
Beta
Remarks
被击中的实体。
The entity being hit.
itemStack?
readonlyoptionalitemStack?:ItemStack
Beta
Remarks
用于击中实体的物品堆。
The item stack used to hit the entity.
