Show / Hide Table of Contents

Interface IMyTargetingCapableBlock

Describes block that can target (cockpits and turrets) (mods interface)

Namespace: Sandbox.ModAPI
Assembly: Sandbox.Common.dll
Syntax
public interface IMyTargetingCapableBlock

Methods

CanActiveToolShoot()

Get whether toolbar selected tool can shoot

Declaration
bool CanActiveToolShoot()
Returns
Type Description
System.Boolean

Whether can shoot

Remarks

Should be called only for IMyShipController. Other implementations has mock logic inside

GetActiveToolPosition()

Gets average position

Declaration
Vector3D GetActiveToolPosition()
Returns
Type Description
Vector3D
Remarks

Should be called only for IMyShipController. Other implementations has mock logic inside

GetWorldMatrix()

Gets barrel or block world matrix

Declaration
MatrixD GetWorldMatrix()
Returns
Type Description
MatrixD

Barrel or block world matrix

IsShipToolSelected()

Get whether toolbar selected item is ship tool (drill, grinder, welder)

Declaration
bool IsShipToolSelected()
Returns
Type Description
System.Boolean

Whether tool is selected

Remarks

Should be called only for IMyShipController. Other implementations has mock logic inside

IsTargetLockingEnabled()

Gets if target locking is enabled

Declaration
bool IsTargetLockingEnabled()
Returns
Type Description
System.Boolean

True if enabled

SetLockedTarget(IMyCharacter)

Sets locked target grid

Declaration
void SetLockedTarget(IMyCharacter target)
Parameters
Type Name Description
IMyCharacter target

Target grid

Remarks

Should be called only for IMyShipController. Other implementations has mock logic inside

SetLockedTarget(IMyCubeGrid)

Sets locked target grid

Declaration
void SetLockedTarget(IMyCubeGrid target)
Parameters
Type Name Description
IMyCubeGrid target

Target grid

Remarks

Should be called only for IMyShipController. Other implementations has mock logic inside

☀
☾
In This Article
Back to top
Generated by DocFX
☀
☾