remote_materials
Vars | |
allow_standalone | Should we create a local storage if we can't connect to silo |
---|---|
local_size | Local size of container when silo = null |
mat_container | Material container. the value is either the silo or local |
mat_container_flags | Flags used for the local material container(exceptions for item insert & intent flags) |
mat_container_signals | List of signals to hook onto the local container |
silo | The silo machine this container is connected to |
Procs | |
_PrepareStorage | Internal proc. prepares local storage if onnect_to_silo = FALSE |
can_use_resource | Check if this connection can use any materials from the silo Returns true only if |
check_z_level | Checks if the param silo is in the same level as this components parent i.e. connected machine, rcd, etc |
disconnect_from | Disconnect this component from the remote silo |
eject_sheets | Ejects the given material ref and logs it |
insert_item | Insert an item into the mat container, helper proc to insert items with the correct context |
on_hold | returns TRUE if this connection put on hold by the silo |
on_item_insert | Insert mats into silo |
set_local_size | Sets the storage size for local materials when not linked with silo Arguments |
toggle_holding | Adds/Removes this connection from the silo |
use_materials | Use materials from either the silo(if connected) or from the local storage. If silo then this action is logged else not e.g. action="build" & name="matter bin" means you are trying to build an matter bin |
Var Details
allow_standalone
Should we create a local storage if we can't connect to silo
local_size
Local size of container when silo = null
mat_container
Material container. the value is either the silo or local
mat_container_flags
Flags used for the local material container(exceptions for item insert & intent flags)
mat_container_signals
List of signals to hook onto the local container
silo
The silo machine this container is connected to
Proc Details
_PrepareStorage
Internal proc. prepares local storage if onnect_to_silo = FALSE
Arguments connect_to_silo- if true connect to global silo. If not successfull then go to local storage only if allow_standalone = TRUE, else you a null mat_container
can_use_resource
Check if this connection can use any materials from the silo Returns true only if
- The parent is of type movable atom
- A mat container is actually present
- The silo in not on hold Arguments
- check_hold - should we check if the silo is on hold
check_z_level
Checks if the param silo is in the same level as this components parent i.e. connected machine, rcd, etc
Arguments silo_to_check- Is this components parent in the same Z level as this param silo. If null then check this components connected silo
Returns true if both are on the station or same z level
disconnect_from
Disconnect this component from the remote silo
Arguments old_silo- The silo we are trying to disconnect from
eject_sheets
Ejects the given material ref and logs it
Arguments material_ref- The material type you are trying to eject eject_amount- how many sheets to eject drop_target- optional where to drop the sheets. null means it is dropped at this components parent location
insert_item
Insert an item into the mat container, helper proc to insert items with the correct context
Arguments
- obj/item/weapon - the item you are trying to insert
- multiplier - the multiplier applied on the materials consumed
on_hold
returns TRUE if this connection put on hold by the silo
on_item_insert
Insert mats into silo
set_local_size
Sets the storage size for local materials when not linked with silo Arguments
- size - the new size for local storage. measured in SHEET_MATERIAL_SIZE units
toggle_holding
Adds/Removes this connection from the silo
use_materials
Use materials from either the silo(if connected) or from the local storage. If silo then this action is logged else not e.g. action="build" & name="matter bin" means you are trying to build an matter bin
Arguments [mats][list]- list of materials to use coefficient- each mat unit is scaled by this value then rounded. This value if usually your machine efficiency e.g. upgraded protolathe has reduced costs multiplier- each mat unit is scaled by this value then rounded after it is scaled by coefficient. This value is your print quatity e.g. printing multiple items action- For logging only. e.g. build, create, i.e. the action you are trying to perform name- For logging only. the design you are trying to build e.g. matter bin, etc.