Record Class DepositFoundEvent
java.lang.Object
java.lang.Record
idlab.colonyops.model.DepositFoundEvent
- Record Components:
turnNumber- the turn on which the discovery was madelocation- the coordinates where the large deposit spawnedresourceType- the type of resource contained in the deposit
public record DepositFoundEvent(int turnNumber, Location location, ResourceType resourceType)
extends Record
Notifies the player's logic service that the colony's orbital scan has discovered a new large
resource deposit, via
POST /missions/{missionId}/scan-completed.
Large deposits contain substantially more resources than normal deposits found during planet generation. Discovery intel may be intercepted by rival colonies, letting them race to the site as well.
-
Constructor Summary
ConstructorsConstructorDescriptionDepositFoundEvent(int turnNumber, Location location, ResourceType resourceType) Creates an instance of aDepositFoundEventrecord 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.location()Returns the value of thelocationrecord component.Returns the value of theresourceTyperecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of theturnNumberrecord component.
-
Constructor Details
-
DepositFoundEvent
Creates an instance of aDepositFoundEventrecord class.- Parameters:
turnNumber- the value for theturnNumberrecord componentlocation- the value for thelocationrecord componentresourceType- the value for theresourceTyperecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
turnNumber
public int turnNumber()Returns the value of theturnNumberrecord component.- Returns:
- the value of the
turnNumberrecord component
-
location
-
resourceType
Returns the value of theresourceTyperecord component.- Returns:
- the value of the
resourceTyperecord component
-