/obj/machinery/mineral
Mineral processing unit console
Vars | |
input_dir | The current direction of input_turf , in relation to the machine. |
---|---|
input_turf | The turf the machines listens to for items to pick up. Calls the pickup_item() proc. |
needs_item_input | Determines if this machine needs to pick up items. Used to avoid registering signals to /mineral machines that don't pickup items. |
output_dir | The current direction, in relation to the machine, that items will be output to. |
Procs | |
pickup_item | Base proc for all /mineral subtype machines to use. Place your item pickup behavior in this proc when you override it for your specific machine. |
register_input_turf | Gets the turf in the input_dir direction adjacent to the machine, and registers signals for ATOM_ENTERED and ATOM_CREATED. Calls the pickup_item() proc when it receives these signals. |
unload_mineral | Generic unloading proc. Takes an atom as an argument and forceMove's it to the turf adjacent to this machine in the output_dir direction. |
unregister_input_turf | Unregisters signals that are registered the machine's input turf, if it has one. |
Var Details
input_dir
The current direction of input_turf
, in relation to the machine.
input_turf
The turf the machines listens to for items to pick up. Calls the pickup_item()
proc.
needs_item_input
Determines if this machine needs to pick up items. Used to avoid registering signals to /mineral
machines that don't pickup items.
output_dir
The current direction, in relation to the machine, that items will be output to.
Proc Details
pickup_item
Base proc for all /mineral
subtype machines to use. Place your item pickup behavior in this proc when you override it for your specific machine.
Called when the COMSIG_ATOM_ENTERED and COMSIG_ATOM_CREATED signals are sent.
Arguments:
- source - the turf that is listening for the signals.
- target - the atom that just moved onto the
source
turf. - oldLoc - the old location that
target
was at before moving ontosource
.
register_input_turf
Gets the turf in the input_dir
direction adjacent to the machine, and registers signals for ATOM_ENTERED and ATOM_CREATED. Calls the pickup_item()
proc when it receives these signals.
unload_mineral
Generic unloading proc. Takes an atom as an argument and forceMove's it to the turf adjacent to this machine in the output_dir
direction.
unregister_input_turf
Unregisters signals that are registered the machine's input turf, if it has one.