Show / Hide Table of Contents

Class MyTSSCommon

Inheritance
System.Object
MyTextSurfaceScriptBase
MyTSSCommon
MyTSSAnalogClock
MyTSSArtificialHorizon
MyTSSDigitalClock
MyTSSEnergyHydrogen
MyTSSFactionIcon
MyTSSGravity
MyTSSVelocity
MyTSSVendingMachine
Implements
IMyTextSurfaceScript
Inherited Members
MyTextSurfaceScriptBase.DEFAULT_BACKGROUND_COLOR
MyTextSurfaceScriptBase.DEFAULT_FONT_COLOR
MyTextSurfaceScriptBase.m_surface
MyTextSurfaceScriptBase.m_block
MyTextSurfaceScriptBase.m_size
MyTextSurfaceScriptBase.m_halfSize
MyTextSurfaceScriptBase.m_scale
MyTextSurfaceScriptBase.m_backgroundColor
MyTextSurfaceScriptBase.m_foregroundColor
MyTextSurfaceScriptBase.Dispose()
MyTextSurfaceScriptBase.FitRect(Vector2, Vector2)
MyTextSurfaceScriptBase.Surface
MyTextSurfaceScriptBase.Block
MyTextSurfaceScriptBase.ForegroundColor
MyTextSurfaceScriptBase.BackgroundColor
MyTextSurfaceScriptBase.NeedsUpdate
Namespace: Sandbox.Game.GameSystems.TextSurfaceScripts
Assembly: Sandbox.Game.dll
Syntax
public abstract class MyTSSCommon : MyTextSurfaceScriptBase, IMyTextSurfaceScript, IDisposable

Constructors

MyTSSCommon(IMyTextSurface, IMyCubeBlock, Vector2)

Declaration
protected MyTSSCommon(IMyTextSurface surface, IMyCubeBlock block, Vector2 size)
Parameters
Type Name Description
IMyTextSurface surface
IMyCubeBlock block
Vector2 size

Fields

m_fontId

Declaration
protected string m_fontId
Field Value
Type Description
System.String

m_fontScale

Declaration
protected float m_fontScale
Field Value
Type Description
System.Single

Methods

AddBackground(MySpriteDrawFrame, Nullable<Color>)

Declaration
protected MySpriteDrawFrame AddBackground(MySpriteDrawFrame frame, Nullable<Color> color = null)
Parameters
Type Name Description
MySpriteDrawFrame frame
System.Nullable<Color> color
Returns
Type Description
MySpriteDrawFrame

AddBrackets(MySpriteDrawFrame, Vector2, Single, Single)

Declaration
protected MySpriteDrawFrame AddBrackets(MySpriteDrawFrame frame, Vector2 size, float scale, float offsetX = 0F)
Parameters
Type Name Description
MySpriteDrawFrame frame
Vector2 size
System.Single scale
System.Single offsetX
Returns
Type Description
MySpriteDrawFrame

AddLine(MySpriteDrawFrame, Vector2, Vector2, Color, Single)

Declaration
protected MySpriteDrawFrame AddLine(MySpriteDrawFrame frame, Vector2 startPos, Vector2 endPos, Color color, float thicknessPx)
Parameters
Type Name Description
MySpriteDrawFrame frame
Vector2 startPos
Vector2 endPos
Color color
System.Single thicknessPx
Returns
Type Description
MySpriteDrawFrame

AddProgressBar(MySpriteDrawFrame, Vector2, Vector2, Single, Color, Color, String, String)

Declaration
protected MySpriteDrawFrame AddProgressBar(MySpriteDrawFrame frame, Vector2 position, Vector2 size, float ratio, Color barBgColor, Color barFgColor, string barBgSprite = null, string barFgSprite = null)
Parameters
Type Name Description
MySpriteDrawFrame frame
Vector2 position
Vector2 size
System.Single ratio
Color barBgColor
Color barFgColor
System.String barBgSprite
System.String barFgSprite
Returns
Type Description
MySpriteDrawFrame

AddTextBox(MySpriteDrawFrame, Vector2, Vector2, String, String, Single, Color, Color, String, Single)

Declaration
protected MySpriteDrawFrame AddTextBox(MySpriteDrawFrame frame, Vector2 position, Vector2 size, string text, string font, float scale, Color bgColor, Color textColor, string bgSprite = null, float textOffset = 0F)
Parameters
Type Name Description
MySpriteDrawFrame frame
Vector2 position
Vector2 size
System.String text
System.String font
System.Single scale
Color bgColor
Color textColor
System.String bgSprite
System.Single textOffset
Returns
Type Description
MySpriteDrawFrame

Run()

Declaration
public override void Run()
Overrides
MyTextSurfaceScriptBase.Run()

Implements

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