DamageSource
Link to damagesource
Importare la Classe
Link to importare-la-classe
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.world.DamageSource;
Metodi
Link to metodi
Name: getDirectEntity
Return Type: Entity
ZenScript Copy// DamageSource.getDirectEntity() as Entity
myDamageSource.getDirectEntity();
Name: getEntity
Return Type: Entity
ZenScript Copy// DamageSource.getEntity() as Entity
myDamageSource.getEntity();
Name: getFoodExhaustion
Return Type: float
ZenScript Copy// DamageSource.getFoodExhaustion() as float
myDamageSource.getFoodExhaustion();
Name: getLocalizedDeathMessage
Return Type: Component
ZenScript CopyDamageSource.getLocalizedDeathMessage(entity as LivingEntity) as Component
Parametro | Tipo | Descrizione |
---|---|---|
Parametro entity | Tipo LivingEntity | Descrizione No Description Provided |
Name: getMsgId
Return Type: string
ZenScript Copy// DamageSource.getMsgId() as string
myDamageSource.getMsgId();
Name: getSourcePosition
Return Type: Vec3
ZenScript Copy// DamageSource.getSourcePosition() as Vec3
myDamageSource.getSourcePosition();
Name: isBypassArmor
Return Type: boolean
ZenScript Copy// DamageSource.isBypassArmor() as boolean
myDamageSource.isBypassArmor();
Name: isBypassInvul
Return Type: boolean
ZenScript Copy// DamageSource.isBypassInvul() as boolean
myDamageSource.isBypassInvul();
Name: isBypassMagic
Return Type: boolean
ZenScript Copy// DamageSource.isBypassMagic() as boolean
myDamageSource.isBypassMagic();
Name: isCreativePlayer
Return Type: boolean
ZenScript Copy// DamageSource.isCreativePlayer() as boolean
myDamageSource.isCreativePlayer();
Name: isDamageHelmet
Return Type: boolean
ZenScript Copy// DamageSource.isDamageHelmet() as boolean
myDamageSource.isDamageHelmet();
Name: isExplosion
Return Type: boolean
ZenScript Copy// DamageSource.isExplosion() as boolean
myDamageSource.isExplosion();
Name: isFall
Return Type: boolean
ZenScript Copy// DamageSource.isFall() as boolean
myDamageSource.isFall();
Name: isFire
Return Type: boolean
ZenScript Copy// DamageSource.isFire() as boolean
myDamageSource.isFire();
Name: isMagic
Return Type: boolean
ZenScript Copy// DamageSource.isMagic() as boolean
myDamageSource.isMagic();
Name: isNoAggro
Return Type: boolean
ZenScript Copy// DamageSource.isNoAggro() as boolean
myDamageSource.isNoAggro();
Name: isProjectile
Return Type: boolean
ZenScript Copy// DamageSource.isProjectile() as boolean
myDamageSource.isProjectile();
Name: scalesWithDifficulty
Return Type: boolean
ZenScript Copy// DamageSource.scalesWithDifficulty() as boolean
myDamageSource.scalesWithDifficulty();
Name: setExplosion
Return Type: DamageSource
ZenScript Copy// DamageSource.setExplosion() as DamageSource
myDamageSource.setExplosion();
Name: setIsFall
Return Type: DamageSource
ZenScript Copy// DamageSource.setIsFall() as DamageSource
myDamageSource.setIsFall();
Name: setMagic
Return Type: DamageSource
ZenScript Copy// DamageSource.setMagic() as DamageSource
myDamageSource.setMagic();
Name: setNoAggro
Return Type: DamageSource
ZenScript Copy// DamageSource.setNoAggro() as DamageSource
myDamageSource.setNoAggro();
Name: setProjectile
Return Type: DamageSource
ZenScript Copy// DamageSource.setProjectile() as DamageSource
myDamageSource.setProjectile();
Name: setScalesWithDifficulty
Return Type: DamageSource
ZenScript Copy// DamageSource.setScalesWithDifficulty() as DamageSource
myDamageSource.setScalesWithDifficulty();
Proprietà
Link to proprietà
Nome | Tipo | Ha Getter | Ha Setter | Descrizione |
---|---|---|---|---|
Nome directEntity | Tipo Entity | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome doesBypassArmor | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome doesBypassInvul | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome doesBypassMagic | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome doesDamageHelmet | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome entity | Tipo Entity | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome foodExhaustion | Tipo float | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isCreativePlayer | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isExplosion | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isFall | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isFire | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isMagic | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isNoAggro | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome isProjectile | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome msgId | Tipo string | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome scalesWithDifficulty | Tipo boolean | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |
Nome sorgente | Tipo Vec3 | Ha Getter sì | Ha Setter no | Descrizione No Description Provided |