Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ DrawSelf()

override void Terraria.GameContent.UI.Elements.UIResourcePack.DrawSelf ( SpriteBatch spriteBatch)
inlineprotectedvirtual

Reimplemented from Terraria.GameContent.UI.Elements.UIPanel.

Definition at line 98 of file UIResourcePack.cs.

99 {
100 base.DrawSelf(spriteBatch);
101 DrawIcon(spriteBatch);
102 if (ResourcePack.Branding == ResourcePack.BrandingType.SteamWorkshop)
103 {
104 Asset<Texture2D> val = TextureAssets.Extra[243];
105 spriteBatch.Draw(val.Value, new Vector2(GetDimensions().X + GetDimensions().Width - (float)val.Width() - 3f, GetDimensions().Y + 2f), val.Frame(), Color.White);
106 }
107 }
void Draw(Texture2D texture, Vector2 position, Color color)
readonly BrandingType Branding
StyleDimension Width
Definition UIElement.cs:27
CalculatedStyle GetDimensions()
Definition UIElement.cs:382

References Terraria.IO.ResourcePack.Branding, Microsoft.Xna.Framework.Graphics.SpriteBatch.Draw(), Terraria.GameContent.UI.Elements.UIResourcePack.DrawIcon(), Terraria.GameContent.TextureAssets.Extra, Terraria.UI.UIElement.GetDimensions(), ReLogic.Content.Asset< T >.Value, Microsoft.Xna.Framework.Color.White, and Terraria.UI.UIElement.Width.