Package io.papermc.paper.registry.data
Interface DamageTypeRegistryEntry.Builder
- All Superinterfaces:
DamageTypeRegistryEntry
,RegistryBuilder<DamageType>
- Enclosing interface:
DamageTypeRegistryEntry
@Experimental
@NonExtendable
public static interface DamageTypeRegistryEntry.Builder
extends DamageTypeRegistryEntry, RegistryBuilder<DamageType>
A mutable builder for the
DamageTypeRegistryEntry
plugins may change in applicable registry events.
The following values are required for each builder:
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.papermc.paper.registry.data.DamageTypeRegistryEntry
DamageTypeRegistryEntry.Builder
-
Method Summary
Modifier and TypeMethodDescriptiondamageEffect
(DamageEffect effect) Sets theDamageEffect
for this damage type.damageScaling
(DamageScaling scaling) Sets theDamageScaling
for this damage type.deathMessageType
(DeathMessageType deathMessageType) Sets theDeathMessageType
for this damage type.exhaustion
(float exhaustion) Sets the amount of hunger exhaustion caused by this damage type.Sets part of the death message translation key.Methods inherited from interface io.papermc.paper.registry.data.DamageTypeRegistryEntry
damageEffect, damageScaling, deathMessageType, exhaustion, messageId
-
Method Details
-
messageId
@Contract(value="_ -> this", mutates="this") DamageTypeRegistryEntry.Builder messageId(String messageId) Sets part of the death message translation key.- Returns:
- this builder instance.
- See Also:
-
exhaustion
@Contract(value="_ -> this", mutates="this") DamageTypeRegistryEntry.Builder exhaustion(float exhaustion) Sets the amount of hunger exhaustion caused by this damage type.- Returns:
- this builder instance.
- See Also:
-
damageScaling
@Contract(value="_ -> this", mutates="this") DamageTypeRegistryEntry.Builder damageScaling(DamageScaling scaling) Sets theDamageScaling
for this damage type.- Returns:
- this builder instance.
- See Also:
-
damageEffect
@Contract(value="_ -> this", mutates="this") DamageTypeRegistryEntry.Builder damageEffect(DamageEffect effect) Sets theDamageEffect
for this damage type.- Returns:
- this builder instance.
- See Also:
-
deathMessageType
@Contract(value="_ -> this", mutates="this") DamageTypeRegistryEntry.Builder deathMessageType(DeathMessageType deathMessageType) Sets theDeathMessageType
for this damage type.- Returns:
- this builder instance.
- See Also:
-