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

◆ DrawSelf()

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

Reimplemented from Terraria.UI.UIElement.

Definition at line 38 of file UIItemSlot.cs.

39 {
42 Vector2 position = GetDimensions().Center() + new Vector2(52f, 52f) * -0.5f * Main.inventoryScale;
43 ItemSlot.Draw(spriteBatch, ref inv, _itemSlotContext, position);
44 }
static void Draw(SpriteBatch spriteBatch, ref Item inv, int context, Vector2 position, Color lightColor=default(Color))
Definition ItemSlot.cs:1777
CalculatedStyle GetDimensions()
Definition UIElement.cs:382

References Terraria.GameContent.UI.Elements.UIItemSlot._itemArray, Terraria.GameContent.UI.Elements.UIItemSlot._itemIndex, Terraria.GameContent.UI.Elements.UIItemSlot._itemSlotContext, Terraria.UI.CalculatedStyle.Center(), Terraria.UI.ItemSlot.Draw(), Terraria.UI.UIElement.GetDimensions(), Terraria.GameContent.UI.Elements.UIItemSlot.HandleItemSlotLogic(), Terraria.Main.inventoryScale, and Microsoft.Xna.Framework.Graphics.Vector2.