Factory Connection

Parent

A actor component that is a connection point to which a conveyor or pipe can get attached to.

Properties

allowedItem : Class<ItemType>

This item type defines which items are the only ones this connector can transfer. Null allows all items to be transfered.

Details
Flags RuntimeSync RuntimeParallel

Display Name

Allowed Item

blocked : Bool

True if this connector doesn’t transfer any items except the 'Unblocked Transfers'.

Details
Flags RuntimeSync RuntimeParallel

Display Name

Blocked

direction : Int

The direction in which the items/fluids flow. 0 = Input, 1 = Output, 2 = Any, 3 = Used just as snap point

Details
Flags ReadOnly RuntimeSync RuntimeParallel

Display Name

Direction

isConnected : Bool

True if something is connected to this connection.

Details
Flags ReadOnly RuntimeSync RuntimeParallel

Display Name

Is Connected

type : Int

Returns the type of the connection. 0 = Conveyor, 1 = Pipe

Details
Flags ReadOnly RuntimeSync RuntimeParallel

Display Name

Type

unblockedTransfers : Int

The count of transfers that can still happen even if the connector is blocked. Use the 'AddUnblockedTransfers' function to change this. The count decreases by one when an item gets transfered.

Details
Flags ReadOnly RuntimeSync RuntimeParallel

Display Name

Unblocked Transfers

Functions

addUnblockedTransfers (unblockedTransfers : Int) → newUnblockedTransfers : Int

Adds the given count to the unblocked transfers counter. The resulting value gets clamped to >= 0. Negative values allow to decrease the counter manually. The returning int is the now set count.

Details

Flags

RuntimeSync RuntimeParallel MemberFunc

Display Name

Add Unblocked Transfers

Parameters
Name Type Description

Unblocked Transfers unblockedTransfers

Int

The count of unblocked transfers to add.

Return Values
Name Type Description

New Unblocked Transfers newUnblockedTransfers

Int

The new count of unblocked transfers.

getConnected () → connected : Trace<FactoryConnection>

Returns the connected factory connection component.

Details

Flags

RuntimeSync RuntimeParallel MemberFunc

Display Name

Get Connected

Return Values
Name Type Description

Connected connected

Trace<FactoryConnection>

The connected factory connection component.

getInventory () → inventory : Trace<Inventory>

Returns the internal inventory of the connection component.

Details

Flags

RuntimeSync RuntimeParallel MemberFunc

Display Name

Get Inventory

Return Values
Name Type Description

Inventory inventory

Trace<Inventory>

The internal inventory of the connection component.

Signals

ItemTransfer (Struct<Item> Item item)

Triggers when the factory connection component transfers an item.

Details
Parameters
Name Type Description

Item item

Struct<Item>

The transfered item