FireworkRocketEntity
Link to fireworkrocketentity
导入类
Link to 导入类
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 Copyimport crafttweaker.api.entity.type.projectile.FireworkRocketEntity;
Extending Projectile
Link to extending-projectile
FireworkRocketEntity extends Projectile. That means all methods available in Projectile are also available in FireworkRocketEntity
已实现的接口
Link to 已实现的接口
FireworkRocketEntity implements the following interfaces. That means all methods defined in these interfaces are also available in FireworkRocketEntity
Constructor #构造函数
Link to constructor-构造函数
ZenScript Copynew FireworkRocketEntity(level as Level, x as double, y as double, z as double, stack as ItemStack) as FireworkRocketEntity
new FireworkRocketEntity(level, 0, 0, 0, <item:minecraft:air>);
参数 | 类型 | 描述 |
---|---|---|
参数 level | 类型 Level | 描述 The level the entity is in. |
参数 x | 类型 double | 描述 The x position of the entity. |
参数 y | 类型 double | 描述 The y position of the entity. |
参数 z | 类型 double | 描述 The z position of the entity. |
参数 堆叠 | 类型 物品应用 | 描述 The optional firework stack. |
使用方式
Link to 使用方式
Name: isShotAtAngle
Checks whether this firework rocket was shot at an angle or not.
Returns: true if shot at an angle, false otherwise.
Return Type: boolean
ZenScript Copy// FireworkRocketEntity.isShotAtAngle() as boolean
myFireworkRocketEntity.isShotAtAngle();
名称 | 类型 | 可获得 | 可设置 | 描述 |
---|---|---|---|---|
名称 isShotAtAngle | 类型 布尔值 | 可获得 true | 可设置 false | 描述 Checks whether this firework rocket was shot at an angle or not. |