Represents any 2D text to be drawn in a Komodo.Core.ECS.Systems.Render2DSystem
More...
|
| TextComponent (SpriteFont font, Color color, Effect shader, string text=null) |
| Creates a TextComponent with a given Microsoft.Xna.Framework.Graphics.SpriteFont. More...
|
|
| TextComponent (string fontPath, Color color, Effect shader, string text=null) |
| Creates a TextComponent with a filepath to a compiled Microsoft.Xna.Framework.Graphics.SpriteFont content file. More...
|
|
|
Color | Color [get, set] |
|
SpriteFont | Font [get, set] |
| Raw font data loaded from disk. More...
|
|
string | FontPath [get, set] |
| Path of the Microsoft.Xna.Framework.Graphics.SpriteFont if the TextComponent was provided a font filepath via TextComponent.TextComponent(string, Color, Effect, string). More...
|
|
override float | Height [get] |
| Y dimensional extremity. More...
|
|
bool | IsCentered [get, set] |
| Flags whether or not to draw the TextComponent with the center or the top-left side as origin. More...
|
|
string | Text [get, set] |
| Text message to be rendered. More...
|
|
override float | Width [get] |
| X dimensional extremity. More...
|
|
abstract Vector2 | Center [get] |
| Center point of the rendered Component. More...
|
|
abstract float | Height [get] |
| Height of the rendered Component. More...
|
|
bool | IsBillboard [get, set] |
| Flags whether or not to draw the Drawable2DComponent as a billboard in 3D space, always facing the relevant Komodo.Core.ECS.Components.CameraComponent. More...
|
|
Effect | Shader [get, set] |
| Shader to use when rendering the Component. If Shader is null, the Komodo.Core.Game.DefaultSpriteShader will be used. More...
|
|
abstract float | Width [get] |
| Width of the rendered Component. More...
|
|
Game? | Game [get] |
| Each Component maintains a reference to the Komodo.Core.Game instance. More...
|
|
Guid | ID [get] |
| Unique identifier for the Component. More...
|
|
bool | IsEnabled [get, set] |
| Enabled Components are managed by their corresponding Komodo.Core.ECS.Systems.ISystem, otherwise the Component is ignored. More...
|
|
bool | IsInitialized [get, set] |
| Uninitialized Components are initialized by their corresponding Komodo.Core.ECS.Systems.ISystem, otherwise the Component is initialized on the next Komodo.Core.ECS.Systems.ISystem.Initialize, Komodo.Core.ECS.Systems.ISystem.PreUpdate, or Komodo.Core.ECS.Systems.ISystem.PostUpdate methods. More...
|
|
Entity | Parent [get, set] |
| Each Component belongs to a Komodo.Core.ECS.Entities.Entity and maintains a reference to the parent Komodo.Core.ECS.Entities.Entity. More...
|
|
Vector3 | Position [get, set] |
| Each Component has a position relative to their Parent. More...
|
|
Vector3?? | WorldPosition [get] |
| The sum of Position and the Parent's Komodo.Core.ECS.Entities.Entity.Position, representing the Component's position in world space. More...
|
|
Vector3?? | Rotation [get, set] |
| Derived from the Parent's Komodo.Core.ECS.Entities.Entity.Rotation. More...
|
|
Matrix?? | RotationMatrix [get] |
| Derived from the Parent's Komodo.Core.ECS.Entities.Entity.RotationMatrix. More...
|
|
Quaternion?? | RotationQuaternion [get] |
| Derived from the Parent's Komodo.Core.ECS.Entities.Entity.RotationQuaternion. More...
|
|
Vector3?? | Scale [get, set] |
| Derived from the Parent's Komodo.Core.ECS.Entities.Entity.Scale. More...
|
|
|
| Drawable2DComponent (bool isEnabled=true, Entity parent=null) |
|
| Component (bool isEnabled=true, Entity parent=null) |
|
Represents any 2D text to be drawn in a Komodo.Core.ECS.Systems.Render2DSystem
◆ TextComponent() [1/2]
Komodo.Core.ECS.Components.TextComponent.TextComponent |
( |
SpriteFont |
font, |
|
|
Color |
color, |
|
|
Effect |
shader, |
|
|
string |
text = null |
|
) |
| |
Creates a TextComponent with a given Microsoft.Xna.Framework.Graphics.SpriteFont.
- Parameters
-
font | SpriteFont reference containing the raw font data. |
color | Color for each glyph to be drawn with. |
shader | Shader used for rendering in a Microsoft.Xna.Framework.Graphics.SpriteBatch. |
text | Text message to be rendered. |
◆ TextComponent() [2/2]
Komodo.Core.ECS.Components.TextComponent.TextComponent |
( |
string |
fontPath, |
|
|
Color |
color, |
|
|
Effect |
shader, |
|
|
string |
text = null |
|
) |
| |
Creates a TextComponent with a filepath to a compiled Microsoft.Xna.Framework.Graphics.SpriteFont content file.
- Parameters
-
fontPath | File path to a compiled Microsoft.Xna.Framework.Graphics.SpriteFont content file. |
color | Color for each glyph to be drawn with. |
shader | Shader used for rendering in a Microsoft.Xna.Framework.Graphics.SpriteBatch. |
text | Text message to be rendered. |
◆ Font
SpriteFont Komodo.Core.ECS.Components.TextComponent.Font |
|
getset |
Raw font data loaded from disk.
◆ FontPath
string Komodo.Core.ECS.Components.TextComponent.FontPath |
|
getset |
◆ Height
override float Komodo.Core.ECS.Components.TextComponent.Height |
|
get |
◆ IsCentered
bool Komodo.Core.ECS.Components.TextComponent.IsCentered |
|
getset |
Flags whether or not to draw the TextComponent with the center or the top-left side as origin.
◆ Text
string Komodo.Core.ECS.Components.TextComponent.Text |
|
getset |
Text message to be rendered.
◆ Width
override float Komodo.Core.ECS.Components.TextComponent.Width |
|
get |