![]() |
3DRadSpace
v1.0.0a
Scripting documentation
|
Class for drawing 2D Texts. More...
Public Member Functions | |
TextPrint (string name, bool active, string font, string text, Vector2 pos, Vector2 size, float rotation=0, Vector2 cof=default, Color col=default, SpriteEffects effects=SpriteEffects.None, int layer=0) | |
TextPrint constructor. More... | |
TextPrint () | |
Empty TextPrint constructor. More... | |
override void | Load (ContentManager content) |
Loads the font. More... | |
override void | Draw (SpriteBatch spriteBatch, Matrix? view, Matrix? projection) |
Draws the text to the game screen. More... | |
override void | EditorDraw (SpriteBatch spriteBatch, Matrix? view, Matrix? projection) |
Draws the text for the editor. More... | |
void | Dispose () |
Disposes the font's texture More... | |
![]() | |
GameObject () | |
Default constructor. More... | |
void | Enable () |
Enables object. More... | |
void | Disable () |
Disables object. More... | |
void | Toggle () |
Switches object on/off state. More... | |
void | Show () |
Shows the object. More... | |
void | Hide () |
Hides the object. More... | |
virtual void | Update (MouseState mouse, KeyboardState keyboard, GameTime time) |
Object update logic More... | |
virtual void | Trigger () |
This is specific to objects like ExitFade, NetServer,etc More... | |
override bool | Equals (object obj) |
Determines whether the specified object is equal to the current object. More... | |
override int | GetHashCode () |
Returns the hash code calculated from a string representing the data inside the object. More... | |
override string | ToString () |
Returns the object's name More... | |
void | RunOnce () |
Runs the object one Update loop. If used on a active object it will be stopped. More... | |
Protected Member Functions | |
virtual void | Dispose (bool disposing) |
Not really needed, MG's pipeline takes care of the SpriteFont instance. More... | |
Properties | |
string | Text [get, set] |
Text to be drawn More... | |
new Vector2 | Position [get, set] |
Position in 2D space of the text. More... | |
Vector2 | Size [get, set] |
Size of the text. More... | |
new float | Rotation [get, set] |
Text rotation. More... | |
SpriteFont | Font [get, set] |
Font used for drawing the text. More... | |
Color | Color [get, set] |
Text Color. More... | |
Vector2 | Center [get, set] |
Center of rotation. More... | |
SpriteEffects | Effects [get, set] |
Allows flipping More... | |
float | Layer [get, set] |
Depth layer. More... | |
![]() | |
string | Name [get, set] |
Object Name. Used as a string identifier. More... | |
object | Tag [get, set] |
Tag object. More... | |
bool | Enabled [get, set] |
Checks if object is enabled. More... | |
bool | Hidden [get, set] |
Checks if object is being drawn. More... | |
List< ObjectBehiavour > | Behiavours [get, set] |
Relation with other objects More... | |
Quaternion | RotationQuaternion [get] |
Rotation in a Quaterion system. More... | |
string | Resource [get, set] |
Resource file More... | |
Additional Inherited Members | |
![]() | |
static implicit | operator bool (GameObject o) |
Checks if the object exists. Same as GameObject != null. More... | |
static bool | operator== (GameObject a, GameObject b) |
Checks if two GameObjects are equal. More... | |
static bool | operator!= (GameObject a, GameObject b) |
The opposite of the equality operator. More... | |
![]() | |
Vector3 | Position |
Object position More... | |
Vector3 | Rotation |
Rotation in a Euler angles system. More... | |
List< int > | SelectedObjects |
Used for editor. More... | |
![]() | |
onDraw | OnDraw |
Called when object is being drawn on frame. More... | |
onUpdate | OnUpdate |
Called when object is being updated on the update logic loop. More... | |
onObjectDestroy | OnRemoval |
Called when object is being deleted. More... | |
onObjectLoad | OnObjectLoad |
Called when a object resource is being loaded. More... | |
Class for drawing 2D Texts.
_3DRadSpaceDll.TextPrint.TextPrint | ( | string | name, |
bool | active, | ||
string | font, | ||
string | text, | ||
Vector2 | pos, | ||
Vector2 | size, | ||
float | rotation = 0 , |
||
Vector2 | cof = default , |
||
Color | col = default , |
||
SpriteEffects | effects = SpriteEffects.None , |
||
int | layer = 0 |
||
) |
TextPrint constructor.
name | Object name |
active | Will this object draw? |
text | Text to print |
pos | Position on the screen |
size | Size |
rotation | Rotation in radians(?) |
font | Font used for drawing. |
cof | Center of rotation. |
col | Text color. |
effects | Flipping options. |
layer | Depth layer. |
_3DRadSpaceDll.TextPrint.TextPrint | ( | ) |
Empty TextPrint constructor.
void _3DRadSpaceDll.TextPrint.Dispose | ( | ) |
Disposes the font's texture
|
protectedvirtual |
Not really needed, MG's pipeline takes care of the SpriteFont instance.
disposing |
|
virtual |
Draws the text to the game screen.
spriteBatch | SpriteBatch used for drawing the text. |
view | Not used. |
projection | Not used. |
Reimplemented from _3DRadSpaceDll.GameObject.
|
virtual |
Draws the text for the editor.
spriteBatch | |
view | |
projection |
Reimplemented from _3DRadSpaceDll.GameObject.
|
virtual |
|
getset |
Center of rotation.
|
getset |
Text Color.
|
getset |
Allows flipping
|
getset |
Font used for drawing the text.
|
getset |
Depth layer.
|
getset |
Position in 2D space of the text.
|
getset |
Text rotation.
|
getset |
Size of the text.
|
getset |
Text to be drawn