|
tModLoader v2023.01
A mod to make and play Terraria mods
|
Public Member Functions | |
| ResourceOverlayDrawContext (PlayerStatsSnapshot snapshot, IPlayerResourcesDisplaySet displaySet, int resourceNumber, Asset< Texture2D > texture) | |
| Creates a context for drawing resources from a display set More... | |
| void | Draw () |
Public Attributes | |
| Color | color |
| SpriteEffects | effects |
| Vector2 | origin |
| The center for rotation and scaling within the source rectangle | |
| Vector2 | position |
| readonly int | resourceNumber |
| Which heart/star/bar/panel is being drawn NOTE: This value usually starts at 0, but it can start at other values | |
| float | rotation |
| Vector2 | scale |
| readonly PlayerStatsSnapshot | snapshot |
| A snapshot of the player's health and mana stats | |
| Rectangle? | source |
The slice of the texture to drawnull represents the entire texture | |
| Asset< Texture2D > | texture |
Properties | |
| IPlayerResourcesDisplaySet | DisplaySet [get] |
| The resource display set that this context is drawing from | |
| SpriteBatch | SpriteBatch [get] |
| Terraria.ModLoader.ResourceOverlayDrawContext.ResourceOverlayDrawContext | ( | PlayerStatsSnapshot | snapshot, |
| IPlayerResourcesDisplaySet | displaySet, | ||
| int | resourceNumber, | ||
| Asset< Texture2D > | texture | ||
| ) |
Creates a context for drawing resources from a display set
| snapshot | A snapshot of a player's life and mana stats |
| displaySet | The display set that this context is for |
| resourceNumber | The resource number within the resource set |
| texture | The texture being drawn |