Record Class CameraInstruction
java.lang.Object
java.lang.Record
net.raphimc.viabedrock.protocol.model.CameraInstruction
public record CameraInstruction(CameraInstruction.SetCamera set, Boolean clear, CameraInstruction.Fade fade, CameraInstruction.Target target, Boolean removeTarget, CameraInstruction.FieldOfView fieldOfView, CameraInstruction.Spline spline, Long attachToEntity, Boolean detachFromEntity)
extends Record
Protocol 2193 camera fields. Null means absent, including optional booleans.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final record -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.viaversion.viaversion.api.type.Type<CameraInstruction> -
Constructor Summary
ConstructorsConstructorDescriptionCameraInstruction(CameraInstruction.SetCamera set, Boolean clear, CameraInstruction.Fade fade, CameraInstruction.Target target, Boolean removeTarget, CameraInstruction.FieldOfView fieldOfView, CameraInstruction.Spline spline, Long attachToEntity, Boolean detachFromEntity) Creates an instance of aCameraInstructionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaction()Native camera actions are mutually exclusive, even when several optional fields are present.Returns the value of theattachToEntityrecord component.clear()Returns the value of theclearrecord component.Returns the value of thedetachFromEntityrecord component.final booleanIndicates whether some other object is "equal to" this one.fade()Returns the value of thefaderecord component.Returns the value of thefieldOfViewrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theremoveTargetrecord component.set()Returns the value of thesetrecord component.spline()Returns the value of thesplinerecord component.target()Returns the value of thetargetrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
TYPE
-
-
Constructor Details
-
CameraInstruction
public CameraInstruction(CameraInstruction.SetCamera set, Boolean clear, CameraInstruction.Fade fade, CameraInstruction.Target target, Boolean removeTarget, CameraInstruction.FieldOfView fieldOfView, CameraInstruction.Spline spline, Long attachToEntity, Boolean detachFromEntity) Creates an instance of aCameraInstructionrecord class.- Parameters:
set- the value for thesetrecord componentclear- the value for theclearrecord componentfade- the value for thefaderecord componenttarget- the value for thetargetrecord componentremoveTarget- the value for theremoveTargetrecord componentfieldOfView- the value for thefieldOfViewrecord componentspline- the value for thesplinerecord componentattachToEntity- the value for theattachToEntityrecord componentdetachFromEntity- the value for thedetachFromEntityrecord component
-
-
Method Details
-
action
Native camera actions are mutually exclusive, even when several optional fields are present. -
toString
-
hashCode
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
set
Returns the value of thesetrecord component.- Returns:
- the value of the
setrecord component
-
clear
Returns the value of theclearrecord component.- Returns:
- the value of the
clearrecord component
-
fade
Returns the value of thefaderecord component.- Returns:
- the value of the
faderecord component
-
target
Returns the value of thetargetrecord component.- Returns:
- the value of the
targetrecord component
-
removeTarget
Returns the value of theremoveTargetrecord component.- Returns:
- the value of the
removeTargetrecord component
-
fieldOfView
Returns the value of thefieldOfViewrecord component.- Returns:
- the value of the
fieldOfViewrecord component
-
spline
Returns the value of thesplinerecord component.- Returns:
- the value of the
splinerecord component
-
attachToEntity
Returns the value of theattachToEntityrecord component.- Returns:
- the value of the
attachToEntityrecord component
-
detachFromEntity
Returns the value of thedetachFromEntityrecord component.- Returns:
- the value of the
detachFromEntityrecord component
-