Show / Hide Table of Contents

Class MyTextSurfaceScriptBase

Inheritance
System.Object
MyTextSurfaceScriptBase
MyTSSCommon
Implements
IMyTextSurfaceScript
Namespace: Sandbox.Game.GameSystems.TextSurfaceScripts
Assembly: Sandbox.Game.dll
Syntax
public abstract class MyTextSurfaceScriptBase : Object, IMyTextSurfaceScript, IDisposable

Constructors

MyTextSurfaceScriptBase(IMyTextSurface, IMyCubeBlock, Vector2)

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

Fields

DEFAULT_BACKGROUND_COLOR

Declaration
public static readonly Color DEFAULT_BACKGROUND_COLOR
Field Value
Type Description
Color

DEFAULT_FONT_COLOR

Declaration
public static readonly Color DEFAULT_FONT_COLOR
Field Value
Type Description
Color

m_backgroundColor

Declaration
protected Color m_backgroundColor
Field Value
Type Description
Color

m_block

Declaration
protected IMyCubeBlock m_block
Field Value
Type Description
IMyCubeBlock

m_foregroundColor

Declaration
protected Color m_foregroundColor
Field Value
Type Description
Color

m_halfSize

Declaration
protected Vector2 m_halfSize
Field Value
Type Description
Vector2

m_scale

Scale in both direction compared to what we would expect as default (512px)

Declaration
protected Vector2 m_scale
Field Value
Type Description
Vector2

m_size

Size of the available texture surface

Declaration
protected Vector2 m_size
Field Value
Type Description
Vector2

m_surface

Declaration
protected IMyTextSurface m_surface
Field Value
Type Description
IMyTextSurface

Properties

BackgroundColor

Declaration
public Color BackgroundColor { get; }
Property Value
Type Description
Color

Block

Declaration
public IMyCubeBlock Block { get; }
Property Value
Type Description
IMyCubeBlock

ForegroundColor

Declaration
public Color ForegroundColor { get; }
Property Value
Type Description
Color

NeedsUpdate

Declaration
public abstract ScriptUpdate NeedsUpdate { get; }
Property Value
Type Description
ScriptUpdate

Surface

Declaration
public IMyTextSurface Surface { get; }
Property Value
Type Description
IMyTextSurface

Methods

Dispose()

Declaration
public virtual void Dispose()

FitRect(Vector2, ref Vector2)

Rescales rectangle to fit within desired texture space.

Declaration
public static void FitRect(Vector2 texture, ref Vector2 rect)
Parameters
Type Name Description
Vector2 texture
Vector2 rect

Run()

Declaration
public virtual void Run()

Implements

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