Record Class ProjectileState
java.lang.Object
java.lang.Record
dev.zwazel.internal.game.state.ProjectileState
- Record Components:
projectileId- The ID of the projectile.ownerId- The ID of the client that owns the projectile (client that fired it).transform- The transform of the projectile.
Represents the state of a projectile.
-
Constructor Summary
ConstructorsConstructorDescriptionProjectileState(Long projectileId, Long ownerId, Transform transform) Creates an instance of aProjectileStaterecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.ownerId()Returns the value of theownerIdrecord component.Returns the value of theprojectileIdrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetransformrecord component.
-
Constructor Details
-
ProjectileState
Creates an instance of aProjectileStaterecord class.- Parameters:
projectileId- the value for theprojectileIdrecord componentownerId- the value for theownerIdrecord componenttransform- the value for thetransformrecord component
-
-
Method Details
-
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). -
projectileId
Returns the value of theprojectileIdrecord component.- Returns:
- the value of the
projectileIdrecord component
-
ownerId
-
transform
-