Interface IMyFunctionalBlock
Describes functional block (block with Enabled/Disabled toggle) (mods interface)
Inherited Members
Namespace: Sandbox.ModAPI
Assembly: Sandbox.Common.dll
Syntax
public interface IMyFunctionalBlock : IMyFunctionalBlock, IMyTerminalBlock, IMyTerminalBlock, IMyCubeBlock, IMyCubeBlock, IMyEntity, IMyEntity
Properties
IsUpdateTimerCreated
Returns true if timer was created. If the block does not use timer, this will be false.
Declaration
bool IsUpdateTimerCreated { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsUpdateTimerEnabled
Returns true if timer is enabled and ticking.
Declaration
bool IsUpdateTimerEnabled { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
GetFramesFromLastTrigger()
Gets number of frames from the last trigger of the update timer
Declaration
uint GetFramesFromLastTrigger()
Returns
Type | Description |
---|---|
System.UInt32 | number of frames |
Events
EnabledChanged
Called when Enabled changed
Declaration
event Action<IMyTerminalBlock> EnabledChanged
Event Type
Type | Description |
---|---|
System.Action<IMyTerminalBlock> |
UpdateTimerTriggered
Triggered when update timer ticks, event is fired after the block does all gameplay stuff
Declaration
event Action<IMyFunctionalBlock> UpdateTimerTriggered
Event Type
Type | Description |
---|---|
System.Action<IMyFunctionalBlock> |