기술 문서는 영어로 제공됩니다. 코드 및 필드 이름은 현재 Mod API를 따릅니다.
문서 수정
Java reference
Search the types, functions and callbacks available to a Java mod. This reference is generated from the SDK Javadocs; each entry links to its full Java documentation.
Find a type or member
60 공개 유형 · 468 회원 · Content API 15
528 일치하는 항목
crafting.infinite()방법Returns whether continuous production is enabled.
ColonyWork.Crafting · 재고 및 작업
서명
public boolean infinite()Returns whether continuous production is enabled.
통화 예시
crafting.infinite();ColonyWork.Crafting crafting is an instance of this supported API type.
- Returns
- whether continuous production is enabled
crafting.minimumStock()방법Returns minimum finished output units.
ColonyWork.Crafting · 재고 및 작업
서명
public int minimumStock()Returns minimum finished output units.
통화 예시
crafting.minimumStock();ColonyWork.Crafting crafting is an instance of this supported API type.
- Returns
- minimum finished output units
crafting.recipeId()방법Returns registered recipe identity.
ColonyWork.Crafting · 재고 및 작업
서명
public String recipeId()Returns registered recipe identity.
통화 예시
crafting.recipeId();ColonyWork.Crafting crafting is an instance of this supported API type.
- Returns
- registered recipe identity
crafting.toString()방법Returns a string representation of this record class.
ColonyWork.Crafting · 재고 및 작업
서명
public final String 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.
통화 예시
crafting.toString();ColonyWork.Crafting crafting is an instance of this supported API type.
- Specified by
- toString in class Record
- Returns
- a string representation of this object
ColonyWork.Facing유형Logical placeable facings, independent of sprite-sheet cell order.
ColonyWork.Facing · 재고 및 작업
서명
public static enum ColonyWork.Facing extends Enum<ColonyWork.Facing>Logical placeable facings, independent of sprite-sheet cell order.
- All Implemented Interfaces
- Serializable, Comparable<ColonyWork.Facing>, Constable
ColonyWork.Facing.EAST상수East-facing placement.
ColonyWork.Facing · 재고 및 작업
서명
public static final ColonyWork.Facing EASTEast-facing placement.
통화 예시
ColonyWork.Facing.EASTUse the public API type shown; import forgottentowns.mod.api.*.
ColonyWork.Facing.NORTH상수North-facing placement.
ColonyWork.Facing · 재고 및 작업
서명
public static final ColonyWork.Facing NORTHNorth-facing placement.
통화 예시
ColonyWork.Facing.NORTHUse the public API type shown; import forgottentowns.mod.api.*.
ColonyWork.Facing.SOUTH상수South-facing placement.
ColonyWork.Facing · 재고 및 작업
서명
public static final ColonyWork.Facing SOUTHSouth-facing placement.
통화 예시
ColonyWork.Facing.SOUTHUse the public API type shown; import forgottentowns.mod.api.*.
ColonyWork.Facing.WEST상수West-facing placement.
ColonyWork.Facing · 재고 및 작업
서명
public static final ColonyWork.Facing WESTWest-facing placement.
통화 예시
ColonyWork.Facing.WESTUse the public API type shown; import forgottentowns.mod.api.*.
ColonyWork.Facing.valueOf(name)방법Returns the enum constant of this class with the specified name.
ColonyWork.Facing · 재고 및 작업
서명
public static ColonyWork.Facing valueOf(String name)Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
통화 예시
ColonyWork.Facing.valueOf(name);Use the public API type shown; import forgottentowns.mod.api.*.
- Parameters
- name - the name of the enum constant to be returned.
- Returns
- the enum constant with the specified name
- Throws
- IllegalArgumentException - if this enum class has no constant with the specified name
- Throws
- NullPointerException - if the argument is null
ColonyWork.Facing.values()방법Returns an array containing the constants of this enum class, in the order they are declared.
ColonyWork.Facing · 재고 및 작업
서명
public static ColonyWork.Facing[] values()Returns an array containing the constants of this enum class, in the order they are declared.
통화 예시
ColonyWork.Facing.values();Use the public API type shown; import forgottentowns.mod.api.*.
- Returns
- an array containing the constants of this enum class, in the order they are declared
ColonyWork.Job유형Detached job metadata.
ColonyWork.Job · 재고 및 작업
서명
public static record ColonyWork.Job(ColonyWork.Queue queue, long id, String kind, String status, ColonyContext.Position position, int priority, Integer citizenId, String definitionId) extends RecordDetached job metadata. Kind and definition are identifiers, never player-facing labels. Completed/cancelled snapshots arrive through ColonyExtension.onWorkFinished(forgottentowns.mod.api.ColonyContext, forgottentowns.mod.api.ColonyWork.Job).
- Record Components
- queue - identity domain
- Record Components
- id - persistent native identity
- Record Components
- kind - native work or blueprint type name; tolerate future values
- Record Components
- status - PENDING, CLAIMED, COMPLETED or CANCELLED
- Record Components
- position - anchor coordinates
- Record Components
- priority - normalized scheduling tier
- Record Components
- citizenId - assigned citizen, or null
- Record Components
- definitionId - recipe, placeable, block or zone identity; empty when inapplicable
new ColonyWork.Job생성자Creates an instance of a Job record class.
ColonyWork.Job · 재고 및 작업
서명
public Job(ColonyWork.Queue queue, long id, String kind, String status, ColonyContext.Position position, int priority, Integer citizenId, String definitionId)Creates an instance of a Job record class.
통화 예시
new ColonyWork.Job(queue, id, kind, status, position, priority, citizenId, definitionId);Use the public API type shown; import forgottentowns.mod.api.*.
- Parameters
- queue - identity domain
- Parameters
- id - persistent native identity
- Parameters
- kind - native work or blueprint type name; tolerate future values
- Parameters
- status - PENDING, CLAIMED, COMPLETED or CANCELLED
- Parameters
- position - anchor coordinates
- Parameters
- priority - normalized scheduling tier
- Parameters
- citizenId - assigned citizen, or null
- Parameters
- definitionId - recipe, placeable, block or zone identity; empty when inapplicable
job.citizenId()방법Returns assigned citizen, or null.
ColonyWork.Job · 재고 및 작업
서명
public Integer citizenId()Returns assigned citizen, or null.
통화 예시
job.citizenId();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- assigned citizen, or null
job.definitionId()방법Returns recipe, placeable, block or zone identity; empty when inapplicable.
ColonyWork.Job · 재고 및 작업
서명
public String definitionId()Returns recipe, placeable, block or zone identity; empty when inapplicable.
통화 예시
job.definitionId();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- recipe, placeable, block or zone identity; empty when inapplicable
job.equals(o)방법Indicates whether some other object is "equal to" this one.
ColonyWork.Job · 재고 및 작업
서명
public final boolean equals(Object o)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 with Objects::equals(Object,Object); primitive components are compared with '=='.
통화 예시
job.equals(o);ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Specified by
- equals in class Record
- Parameters
- o - the object with which to compare
- Returns
- true if this object is the same as the o argument; false otherwise.
job.hashCode()방법Returns a hash code value for this object.
ColonyWork.Job · 재고 및 작업
서명
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.
통화 예시
job.hashCode();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Specified by
- hashCode in class Record
- Returns
- a hash code value for this object
job.id()방법Returns persistent native identity.
ColonyWork.Job · 재고 및 작업
서명
public long id()Returns persistent native identity.
통화 예시
job.id();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- persistent native identity
job.kind()방법Returns native work or blueprint type name; tolerate future values.
ColonyWork.Job · 재고 및 작업
서명
public String kind()Returns native work or blueprint type name; tolerate future values.
통화 예시
job.kind();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- native work or blueprint type name; tolerate future values
job.position()방법Returns anchor coordinates.
ColonyWork.Job · 재고 및 작업
서명
public ColonyContext.Position position()Returns anchor coordinates.
통화 예시
job.position();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- anchor coordinates
job.priority()방법Returns normalized scheduling tier.
ColonyWork.Job · 재고 및 작업
서명
public int priority()Returns normalized scheduling tier.
통화 예시
job.priority();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- normalized scheduling tier
job.queue()방법Returns identity domain.
ColonyWork.Job · 재고 및 작업
서명
public ColonyWork.Queue queue()Returns identity domain.
통화 예시
job.queue();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- identity domain
job.status()방법Returns PENDING, CLAIMED, COMPLETED or CANCELLED.
ColonyWork.Job · 재고 및 작업
서명
public String status()Returns PENDING, CLAIMED, COMPLETED or CANCELLED.
통화 예시
job.status();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Returns
- PENDING, CLAIMED, COMPLETED or CANCELLED
job.toString()방법Returns a string representation of this record class.
ColonyWork.Job · 재고 및 작업
서명
public final String 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.
통화 예시
job.toString();ColonyWork.Job job = context.work().get(queue, id); check for null before reading its values.
- Specified by
- toString in class Record
- Returns
- a string representation of this object
ColonyWork.Queue유형Independent persistent identity domains.
ColonyWork.Queue · 재고 및 작업
서명
public static enum ColonyWork.Queue extends Enum<ColonyWork.Queue>Independent persistent identity domains.
- All Implemented Interfaces
- Serializable, Comparable<ColonyWork.Queue>, Constable
Read an entry
- Method: a function your mod calls on the supplied service or value.
- Hook: a callback the game calls on your registered implementation.
- Constructor: creates an API value.
- Constant: a fixed value, such as a facing or work queue.
Expand an entry for its signature, parameters, return value, exceptions and call shape. Call shapes show the real parameter names as placeholders; supply values of the declared types. Read the lifetime and ownership rules before retaining an object or issuing a command.
Java setup · Registration and lifecycle · Task guides · Full generated Javadocs
