forked from Pathoschild/StardewMods
-
Notifications
You must be signed in to change notification settings - Fork 0
/
IMachine.cs
28 lines (24 loc) · 1.15 KB
/
IMachine.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
namespace Pathoschild.Stardew.Automate
{
/// <summary>A machine that accepts input and provides output.</summary>
public interface IMachine : IAutomatable
{
/*********
** Accessors
*********/
/// <summary>A unique ID for the machine type.</summary>
/// <remarks>This value should be identical for two machines if they have the exact same behavior and input logic. For example, if one machine in a group can't process input due to missing items, Automate will skip any other empty machines of that type in the same group since it assumes they need the same inputs.</remarks>
string MachineTypeID { get; }
/*********
** Public methods
*********/
/// <summary>Get the machine's processing state.</summary>
MachineState GetState();
/// <summary>Get the output item.</summary>
ITrackedStack GetOutput();
/// <summary>Provide input to the machine.</summary>
/// <param name="input">The available items.</param>
/// <returns>Returns whether the machine started processing an item.</returns>
bool SetInput(IStorage input);
}
}