Interface IMyProductionBlock
Describes production blocks : refinery block, assembler block, survival kit block. (mods interface)
Inherited Members
Namespace: Sandbox.ModAPI
Assembly: Sandbox.Common.dll
Syntax
public interface IMyProductionBlock : IMyFunctionalBlock, IMyTerminalBlock, IMyCubeBlock, IMyEntity, IMyProductionBlock, IMyFunctionalBlock, IMyTerminalBlock, IMyCubeBlock, IMyEntity
Properties
InputInventory
Gets inventory responsible for source items
Declaration
IMyInventory InputInventory { get; }
Property Value
Type | Description |
---|---|
IMyInventory |
OutputInventory
Gets inventory responsible for produced items
Declaration
IMyInventory OutputInventory { get; }
Property Value
Type | Description |
---|---|
IMyInventory |
Methods
AddQueueItem(MyDefinitionBase, MyFixedPoint)
Adds a blueprint to the production queue
Declaration
void AddQueueItem(MyDefinitionBase blueprint, MyFixedPoint amount)
Parameters
Type | Name | Description |
---|---|---|
MyDefinitionBase | blueprint | A MyBlueprintDefinition that defines the blueprint |
VRage.MyFixedPoint | amount | Amount of items |
CanUseBlueprint(MyDefinitionBase)
Can this production block produce this blueprint?
Declaration
bool CanUseBlueprint(MyDefinitionBase blueprint)
Parameters
Type | Name | Description |
---|---|---|
MyDefinitionBase | blueprint | A MyBlueprintDefinition that defines the blueprint |
Returns
Type | Description |
---|---|
System.Boolean |
GetQueue()
Gets the current production queue (copy)
Declaration
List<MyProductionQueueItem> GetQueue()
Returns
Type | Description |
---|---|
System.Collections.Generic.List<MyProductionQueueItem> | List of MyProductionQueueItems |
InsertQueueItem(Int32, MyDefinitionBase, MyFixedPoint)
Inserts a blueprint into the production queue
Declaration
void InsertQueueItem(int idx, MyDefinitionBase blueprint, MyFixedPoint amount)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | idx | Index of the item |
MyDefinitionBase | blueprint | A MyBlueprintDefinition that defines the blueprint |
VRage.MyFixedPoint | amount | Amount of items |
Events
StartedProducing
Called when production block has started producing items
Declaration
event Action StartedProducing
Event Type
Type | Description |
---|---|
System.Action |
StoppedProducing
Called when production block has stopped producing items (ex: no power, no resources, inventory full)
Declaration
event Action StoppedProducing
Event Type
Type | Description |
---|---|
System.Action |