DamageContainer
Importing the class
If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.
import crafttweaker.neoforge.api.world.damage.DamageContainer;Members
addModifier(type as Reduction, reductionFunction as IReductionFunction)
// DamageContainer.addModifier(type as DamageContainerReduction, reductionFunction as IReductionFunction);myDamageContainer.addModifier(myReduction, myIReductionFunction);Parameters:
type: DamageContainerReduction Type: DamageContainerReduction reductionFunction: IReductionFunction Type: IReductionFunction Getter
// DamageContainer.blockedDamage as floatmyDamageContainer.blockedDamage
Return Type:
float
getReduction(type as Reduction) as float
myDamageContainer.getReduction(myReduction);Parameters:
type: DamageContainerReduction Type: DamageContainerReduction
Return Type:
float
Getter
// DamageContainer.newDamage as floatmyDamageContainer.newDamage
Return Type:
float
Setter
// DamageContainer.newDamage = (damage as float);myDamageContainer.newDamage = myFloat;Parameters:
damage: float Type: float static of(source as DamageSource, originalDamage as float) as DamageContainer
DamageContainer.of(myDamageSource, myFloat);Parameters:
source: DamageSource Type: DamageSource originalDamage: float Type: float
Return Type:
DamageContainer
Getter
// DamageContainer.originalDamage as floatmyDamageContainer.originalDamage
Return Type:
float
Getter
// DamageContainer.postAttackInvulnerabilityTicks as intmyDamageContainer.postAttackInvulnerabilityTicks
Return Type:
int
Setter
// DamageContainer.postAttackInvulnerabilityTicks = (ticks as int);myDamageContainer.postAttackInvulnerabilityTicks = myInt;Parameters:
ticks: int Type: int Getter
// DamageContainer.shieldDamage as floatmyDamageContainer.shieldDamage
Return Type:
float
Getter
// DamageContainer.source as DamageSourcemyDamageContainer.source
Return Type:
DamageSource