Show / Hide Table of Contents

Interface IMyTurretControlBlock

Describes Turret Control block (PB scripting interface)

Inherited Members
IMyFunctionalBlock.RequestEnable(Boolean)
IMyFunctionalBlock.Enabled
IMyTerminalBlock.HasLocalPlayerAccess()
IMyTerminalBlock.HasPlayerAccess(Int64, MyRelationsBetweenPlayerAndBlock)
IMyTerminalBlock.HasNobodyPlayerAccessToBlock()
IMyTerminalBlock.HasPlayerAccessWithNobodyCheck(Int64, Boolean)
IMyTerminalBlock.SetCustomName(String)
IMyTerminalBlock.SetCustomName(StringBuilder)
IMyTerminalBlock.GetActions(List<ITerminalAction>, Func<ITerminalAction, Boolean>)
IMyTerminalBlock.SearchActionsOfName(String, List<ITerminalAction>, Func<ITerminalAction, Boolean>)
IMyTerminalBlock.GetActionWithName(String)
IMyTerminalBlock.GetProperty(String)
IMyTerminalBlock.GetProperties(List<ITerminalProperty>, Func<ITerminalProperty, Boolean>)
IMyTerminalBlock.IsSameConstructAs(IMyTerminalBlock)
IMyTerminalBlock.CustomName
IMyTerminalBlock.CustomNameWithFaction
IMyTerminalBlock.DetailedInfo
IMyTerminalBlock.CustomInfo
IMyTerminalBlock.CustomData
IMyTerminalBlock.ShowOnHUD
IMyTerminalBlock.ShowInTerminal
IMyTerminalBlock.ShowInToolbarConfig
IMyTerminalBlock.ShowInInventory
IMyCubeBlock.GetOwnerFactionTag()
IMyCubeBlock.GetPlayerRelationToOwner()
IMyCubeBlock.GetUserRelationToOwner(Int64, MyRelationsBetweenPlayerAndBlock)
IMyCubeBlock.UpdateIsWorking()
IMyCubeBlock.UpdateVisual()
IMyCubeBlock.BlockDefinition
IMyCubeBlock.CubeGrid
IMyCubeBlock.DefinitionDisplayNameText
IMyCubeBlock.DisassembleRatio
IMyCubeBlock.DisplayNameText
IMyCubeBlock.IsBeingHacked
IMyCubeBlock.IsFunctional
IMyCubeBlock.IsWorking
IMyCubeBlock.Max
IMyCubeBlock.Mass
IMyCubeBlock.Min
IMyCubeBlock.NumberInGrid
IMyCubeBlock.Orientation
IMyCubeBlock.OwnerId
IMyCubeBlock.Position
IMyEntity.GetInventory()
IMyEntity.GetInventory(Int32)
IMyEntity.GetPosition()
IMyEntity.Components
IMyEntity.EntityId
IMyEntity.Name
IMyEntity.DisplayName
IMyEntity.HasInventory
IMyEntity.InventoryCount
IMyEntity.Closed
IMyEntity.WorldAABB
IMyEntity.WorldAABBHr
IMyEntity.WorldMatrix
IMyEntity.WorldVolume
IMyEntity.WorldVolumeHr
Namespace: SpaceEngineers.Game.ModAPI.Ingame
Assembly: Sandbox.Common.dll
Syntax
public interface IMyTurretControlBlock : IMyFunctionalBlock, IMyTerminalBlock, IMyCubeBlock, IMyEntity

Properties

AIEnabled

Gets whether this block has AI enabled for turret

Declaration
bool AIEnabled { get; set; }
Property Value
Type Description
System.Boolean

AngleDeviation

Gets or Sets angle deviation

Declaration
float AngleDeviation { get; set; }
Property Value
Type Description
System.Single

AzimuthRotor

Gets or Sets rotor for the azimuth angle

Declaration
IMyMotorStator AzimuthRotor { get; set; }
Property Value
Type Description
IMyMotorStator

Camera

Gets or Sets camera for the block

Declaration
IMyCameraBlock Camera { get; set; }
Property Value
Type Description
IMyCameraBlock

ElevationRotor

Gets or Sets rotor for the elevation angle

Declaration
IMyMotorStator ElevationRotor { get; set; }
Property Value
Type Description
IMyMotorStator

HasTarget

Gets whether the turret is locked onto a target

Declaration
bool HasTarget { get; }
Property Value
Type Description
System.Boolean

IsAimed

Gets whether this block is aimed at the target

Declaration
bool IsAimed { get; }
Property Value
Type Description
System.Boolean

IsSunTrackerEnabled

Gets or sets if turret control block should aim sun

Declaration
bool IsSunTrackerEnabled { get; set; }
Property Value
Type Description
System.Boolean

IsUnderControl

Gets whether this block is locally or remotely controlled.

Declaration
bool IsUnderControl { get; }
Property Value
Type Description
System.Boolean

MoveIndicator

Gets movement indicator

Declaration
Vector3 MoveIndicator { get; }
Property Value
Type Description
Vector3

Range

Sets or Gets shooting range of the turret

Declaration
float Range { get; set; }
Property Value
Type Description
System.Single

RollIndicator

Gets roll indicator

Declaration
float RollIndicator { get; }
Property Value
Type Description
System.Single

RotationIndicator

Gets rotation indicator

Declaration
Vector2 RotationIndicator { get; }
Property Value
Type Description
Vector2

TargetCharacters

Gets or Sets if the turret should target characters.

Declaration
bool TargetCharacters { get; set; }
Property Value
Type Description
System.Boolean

TargetFriends

Gets or Sets if the turret should target friends.

Declaration
bool TargetFriends { get; set; }
Property Value
Type Description
System.Boolean

TargetLargeGrids

Gets or Sets if the turret should target large grids.

Declaration
bool TargetLargeGrids { get; set; }
Property Value
Type Description
System.Boolean

TargetMeteors

Gets or Sets if the turret should target meteors.

Declaration
bool TargetMeteors { get; set; }
Property Value
Type Description
System.Boolean

TargetMissiles

Gets or Sets if the turret should target missiles.

Declaration
bool TargetMissiles { get; set; }
Property Value
Type Description
System.Boolean

TargetNeutrals

Gets or Sets if the turret should target neutrals.

Declaration
bool TargetNeutrals { get; set; }
Property Value
Type Description
System.Boolean

TargetSmallGrids

Gets or Sets if the turret should target small grids.

Declaration
bool TargetSmallGrids { get; set; }
Property Value
Type Description
System.Boolean

TargetStations

Gets or Sets if the turret should target stations.

Declaration
bool TargetStations { get; set; }
Property Value
Type Description
System.Boolean

VelocityMultiplierAzimuthRpm

Gets or Sets velocity multiplier for azimuth [rpm]

Declaration
float VelocityMultiplierAzimuthRpm { get; set; }
Property Value
Type Description
System.Single

VelocityMultiplierElevationRpm

Gets or Sets velocity multiplier for elevation [rpm]

Declaration
float VelocityMultiplierElevationRpm { get; set; }
Property Value
Type Description
System.Single

Methods

AddTool(IMyFunctionalBlock)

Adds the tool for the block

Declaration
void AddTool(IMyFunctionalBlock tool)
Parameters
Type Name Description
IMyFunctionalBlock tool

tool (weapons/tools blocks) which player can set in UI

AddTools(List<IMyFunctionalBlock>)

Adds tools for the block

Declaration
void AddTools(List<IMyFunctionalBlock> tools)
Parameters
Type Name Description
System.Collections.Generic.List<IMyFunctionalBlock> tools

tools collection (weapons/tools blocks) which player can set in UI

ClearTools()

Clears tools

Declaration
void ClearTools()

GetDirectionSource()

Get block that provides direction of shooting

Declaration
IMyTerminalBlock GetDirectionSource()
Returns
Type Description
IMyTerminalBlock

GetShootDirection()

Get direction of shooting.

Declaration
Vector3 GetShootDirection()
Returns
Type Description
Vector3

GetTargetedEntity()

Gets the turret's current detected entity, if any

Declaration
MyDetectedEntityInfo GetTargetedEntity()
Returns
Type Description
MyDetectedEntityInfo

empty info if target does not exist

GetTargetingGroup()

Gets current targeting group

Declaration
string GetTargetingGroup()
Returns
Type Description
System.String

current targeting group

GetTargetingGroups()

Gets all available targeting groups

Declaration
List<string> GetTargetingGroups()
Returns
Type Description
System.Collections.Generic.List<System.String>

list of names of targeting groups

GetTools(List<IMyFunctionalBlock>)

Gets tools for the block

Declaration
void GetTools(List<IMyFunctionalBlock> tools)
Parameters
Type Name Description
System.Collections.Generic.List<IMyFunctionalBlock> tools

tools collection (weapons/tools blocks) which player can set in UI

RemoveTool(IMyFunctionalBlock)

Removes the tool for the block

Declaration
void RemoveTool(IMyFunctionalBlock tool)
Parameters
Type Name Description
IMyFunctionalBlock tool

tool (weapons/tools blocks) which player can set in UI

RemoveTools(List<IMyFunctionalBlock>)

Removes tools for the block

Declaration
void RemoveTools(List<IMyFunctionalBlock> tool)
Parameters
Type Name Description
System.Collections.Generic.List<IMyFunctionalBlock> tool

tools collection (weapons/tools blocks) which player can set in UI

SetTargetingGroup(String)

Sets current targeting group

Declaration
void SetTargetingGroup(string groupSubtypeId)
Parameters
Type Name Description
System.String groupSubtypeId

group subtype id

Extension Methods

TerminalBlockExtentions.GetId(IMyTerminalBlock)
TerminalBlockExtentions.ApplyAction(IMyTerminalBlock, String)
TerminalBlockExtentions.ApplyAction(IMyTerminalBlock, String, List<TerminalActionParameter>)
TerminalBlockExtentions.HasAction(IMyTerminalBlock, String)
TerminalBlockExtentions.HasInventory(IMyTerminalBlock)
TerminalBlockExtentions.GetInventory(IMyTerminalBlock, Int32)
TerminalBlockExtentions.GetInventoryCount(IMyTerminalBlock)
TerminalBlockExtentions.GetUseConveyorSystem(IMyTerminalBlock)
TerminalBlockExtentions.SetUseConveyorSystem(IMyTerminalBlock, Boolean)
TerminalPropertyExtensions.GetValueFloat(IMyTerminalBlock, String)
TerminalPropertyExtensions.SetValueFloat(IMyTerminalBlock, String, Single)
TerminalPropertyExtensions.GetValueBool(IMyTerminalBlock, String)
TerminalPropertyExtensions.SetValueBool(IMyTerminalBlock, String, Boolean)
TerminalPropertyExtensions.GetValueColor(IMyTerminalBlock, String)
TerminalPropertyExtensions.SetValueColor(IMyTerminalBlock, String, Color)
TerminalPropertyExtensions.GetValue<T>(IMyTerminalBlock, String)
TerminalPropertyExtensions.GetDefaultValue<T>(IMyTerminalBlock, String)
TerminalPropertyExtensions.GetMininum<T>(IMyTerminalBlock, String)
TerminalPropertyExtensions.GetMinimum<T>(IMyTerminalBlock, String)
TerminalPropertyExtensions.GetMaximum<T>(IMyTerminalBlock, String)
TerminalPropertyExtensions.SetValue<T>(IMyTerminalBlock, String, T)
☀
☾
In This Article
Back to top
Generated by DocFX
☀
☾