AbstractHurtingProjectile
Link to abstracthurtingprojectile
导入类
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.AbstractHurtingProjectile;
Extending Projectile
Link to extending-projectile
AbstractHurtingProjectile extends Projectile. That means all methods available in Projectile are also available in AbstractHurtingProjectile
使用方式
Link to 使用方式
Name: getXPower
Gets the x power of this projectile.
Returns: The x power of this projectile.
Return Type: double
ZenScript Copy// AbstractHurtingProjectile.getXPower() as double
myAbstractHurtingProjectile.getXPower();
Name: getYPower
Gets the y power of this projectile.
Returns: The y power of this projectile.
Return Type: double
ZenScript Copy// AbstractHurtingProjectile.getYPower() as double
myAbstractHurtingProjectile.getYPower();
Name: getZPower
Gets the z power of this projectile.
Returns: The z power of this projectile.
Return Type: double
ZenScript Copy// AbstractHurtingProjectile.getZPower() as double
myAbstractHurtingProjectile.getZPower();
Name: setXPower
Sets the x power of this projectile.
ZenScript Copy// AbstractHurtingProjectile.setXPower(xPower as double)
myAbstractHurtingProjectile.setXPower(4);
参数 | 类型 | 描述 |
---|---|---|
参数 xPower | 类型 double | 描述 The x power of this projectile. |
Name: setYPower
Sets the y power of this projectile.
ZenScript Copy// AbstractHurtingProjectile.setYPower(yPower as double)
myAbstractHurtingProjectile.setYPower(4);
参数 | 类型 | 描述 |
---|---|---|
参数 yPower | 类型 double | 描述 The y power of this projectile. |
Name: setZPower
Sets the z power of this projectile.
ZenScript Copy// AbstractHurtingProjectile.setZPower(zPower as double)
myAbstractHurtingProjectile.setZPower(4);
参数 | 类型 | 描述 |
---|---|---|
参数 zPower | 类型 double | 描述 The z power of this projectile. |
名称 | 类型 | 可获得 | 可设置 | 描述 |
---|---|---|---|---|
名称 xPower | 类型 double | 可获得 true | 可设置 true | 描述 Gets the x power of this projectile. |
名称 yPower | 类型 double | 可获得 true | 可设置 true | 描述 Gets the y power of this projectile. |
名称 zPower | 类型 double | 可获得 true | 可设置 true | 描述 Gets the z power of this projectile. |