Record Class EndDragonFight.Data
java.lang.Object
java.lang.Record
net.minecraft.world.level.dimension.end.EndDragonFight.Data
- Enclosing class:
EndDragonFight
-
Field Summary
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<EndDragonFight.Data> static final EndDragonFight.Data
private final boolean
The field for thedragonKilled
record component.The field for thedragonUUID
record component.The field for theexitPortalLocation
record component.The field for thegateways
record component.private final boolean
The field for theisRespawning
record component.private final boolean
The field for theneedsStateScanning
record component.private final boolean
The field for thepreviouslyKilled
record component. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns the value of thedragonKilled
record component.Returns the value of thedragonUUID
record component.final boolean
Indicates whether some other object is "equal to" this one.Returns the value of theexitPortalLocation
record component.gateways()
Returns the value of thegateways
record component.final int
hashCode()
Returns a hash code value for this object.boolean
Returns the value of theisRespawning
record component.boolean
Returns the value of theneedsStateScanning
record component.boolean
Returns the value of thepreviouslyKilled
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
needsStateScanning
private final boolean needsStateScanningThe field for theneedsStateScanning
record component. -
dragonKilled
private final boolean dragonKilledThe field for thedragonKilled
record component. -
previouslyKilled
private final boolean previouslyKilledThe field for thepreviouslyKilled
record component. -
isRespawning
private final boolean isRespawningThe field for theisRespawning
record component. -
dragonUUID
The field for thedragonUUID
record component. -
exitPortalLocation
The field for theexitPortalLocation
record component. -
gateways
The field for thegateways
record component. -
CODEC
-
DEFAULT
-
-
Constructor Details
-
Data
public Data(boolean needsStateScanning, boolean dragonKilled, boolean previouslyKilled, boolean isRespawning, Optional<UUID> dragonUUID, Optional<BlockPos> exitPortalLocation, Optional<List<Integer>> gateways) Creates an instance of aData
record class.- Parameters:
needsStateScanning
- the value for theneedsStateScanning
record componentdragonKilled
- the value for thedragonKilled
record componentpreviouslyKilled
- the value for thepreviouslyKilled
record componentisRespawning
- the value for theisRespawning
record componentdragonUUID
- the value for thedragonUUID
record componentexitPortalLocation
- the value for theexitPortalLocation
record componentgateways
- the value for thegateways
record component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
needsStateScanning
public boolean needsStateScanning()Returns the value of theneedsStateScanning
record component.- Returns:
- the value of the
needsStateScanning
record component
-
dragonKilled
public boolean dragonKilled()Returns the value of thedragonKilled
record component.- Returns:
- the value of the
dragonKilled
record component
-
previouslyKilled
public boolean previouslyKilled()Returns the value of thepreviouslyKilled
record component.- Returns:
- the value of the
previouslyKilled
record component
-
isRespawning
public boolean isRespawning()Returns the value of theisRespawning
record component.- Returns:
- the value of the
isRespawning
record component
-
dragonUUID
Returns the value of thedragonUUID
record component.- Returns:
- the value of the
dragonUUID
record component
-
exitPortalLocation
Returns the value of theexitPortalLocation
record component.- Returns:
- the value of the
exitPortalLocation
record component
-
gateways
Returns the value of thegateways
record component.- Returns:
- the value of the
gateways
record component
-